Package: android.hardware.wifi.supplicant@1.0

ISupplicantStaIface

interface ISupplicantStaIface extends ISupplicantIface

Interface exposed by the supplicant for each station mode network interface(e.g wlan0)it controls.

Properties

AnqpInfoId

enum AnqpInfoId: uint16_t

Access Network Query Protocol info ID elements for IEEE Std 802.11u-2011.

Details
Members
VENUE_NAME = 258
ROAMING_CONSORTIUM = 261
IP_ADDR_TYPE_AVAILABILITY = 262
NAI_REALM = 263
ANQP_3GPP_CELLULAR_NETWORK = 264
DOMAIN_NAME = 268

Hs20AnqpSubtypes

enum Hs20AnqpSubtypes: uint32_t

Access Network Query Protocol subtype elements for Hotspot 2.0.

Details
Members
OPERATOR_FRIENDLY_NAME = 3
WAN_METRICS = 4
CONNECTION_CAPABILITY = 5
OSU_PROVIDERS_LIST = 8

RxFilterType

enum RxFilterType: uint8_t

Enum describing the types of RX filter supported via driver commands.

Details
Members
V4_MULTICAST = 0
V6_MULTICAST = 1

BtCoexistenceMode

enum BtCoexistenceMode: uint8_t

Enum describing the modes of BT coexistence supported via driver commands.

Details
Members
ENABLED = 0
DISABLED = 1
SENSE = 2

ExtRadioWorkDefaults

enum ExtRadioWorkDefaults: uint32_t
Details
Members
TIMEOUT_IN_SECS = 10

Methods

registerCallback

registerCallback (ISupplicantStaIfaceCallback callback)
generates (SupplicantStatus status)

Register for callbacks from this interface.

These callbacks are invoked for events that are specific to this interface.Registration of multiple callback objects is supported.These objects must be automatically deleted when the corresponding client process is dead or if this interface is removed.

Details
Parameters
callback
An instance of the |ISupplicantStaIfaceCallback| HIDL interface object.
Generates
status
Status of the operation.Possible status codes:|SupplicantStatusCode.SUCCESS|, |SupplicantStatusCode.FAILURE_UNKNOWN|, |SupplicantStatusCode.FAILURE_IFACE_INVALID|

reassociate

reassociate ()
generates (SupplicantStatus status)

Reconnect to the currently active network, even if we are already connected.

Details
Generates
status
Status of the operation.Possible status codes:|SupplicantStatusCode.SUCCESS|, |SupplicantStatusCode.FAILURE_UNKNOWN|, |SupplicantStatusCode.FAILURE_IFACE_INVALID|, |SupplicantStatusCode.FAILURE_IFACE_DISABLED|

reconnect

reconnect ()
generates (SupplicantStatus status)

Reconnect to the currently active network, if we are currently disconnected.

Details
Generates
status
Status of the operation.Possible status codes:|SupplicantStatusCode.SUCCESS|, |SupplicantStatusCode.FAILURE_UNKNOWN|, |SupplicantStatusCode.FAILURE_IFACE_INVALID|, |SupplicantStatusCode.FAILURE_IFACE_DISABLED|, |SupplicantStatusCode.FAILURE_IFACE_NOT_DISCONNECTED|

disconnect

disconnect ()
generates (SupplicantStatus status)

Disconnect from the current active network.

Details
Generates
status
Status of the operation.Possible status codes:|SupplicantStatusCode.SUCCESS|, |SupplicantStatusCode.FAILURE_UNKNOWN|, |SupplicantStatusCode.FAILURE_IFACE_INVALID|, |SupplicantStatusCode.FAILURE_IFACE_DISABLED|

setPowerSave

setPowerSave (bool enable)
generates (SupplicantStatus status)

Turn on/off power save mode for the interface.

Details
Parameters
enable
Indicate if power save is to be turned on/off.
Generates
status
Status of the operation.Possible status codes:|SupplicantStatusCode.SUCCESS|, |SupplicantStatusCode.FAILURE_UNKNOWN|, |SupplicantStatusCode.FAILURE_IFACE_INVALID|, |SupplicantStatusCode.FAILURE_IFACE_DISABLED|

initiateTdlsDiscover

initiateTdlsDiscover (MacAddress macAddress)
generates (SupplicantStatus status)

Initiate TDLS discover with the provided peer MAC address.

Details
Parameters
macAddress
MAC address of the peer.
Generates
status
Status of the operation.Possible status codes:|SupplicantStatusCode.SUCCESS|, |SupplicantStatusCode.FAILURE_UNKNOWN|, |SupplicantStatusCode.FAILURE_IFACE_INVALID|

initiateTdlsSetup

initiateTdlsSetup (MacAddress macAddress)
generates (SupplicantStatus status)

Initiate TDLS setup with the provided peer MAC address.

Details
Parameters
macAddress
MAC address of the peer.
Generates
status
Status of the operation.Possible status codes:|SupplicantStatusCode.SUCCESS|, |SupplicantStatusCode.FAILURE_UNKNOWN|, |SupplicantStatusCode.FAILURE_IFACE_INVALID|

initiateTdlsTeardown

initiateTdlsTeardown (MacAddress macAddress)
generates (SupplicantStatus status)

Initiate TDLS teardown with the provided peer MAC address.

Details
Parameters
macAddress
MAC address of the peer.
Generates
status
Status of the operation.Possible status codes:|SupplicantStatusCode.SUCCESS|, |SupplicantStatusCode.FAILURE_UNKNOWN|, |SupplicantStatusCode.FAILURE_IFACE_INVALID|

initiateAnqpQuery

initiateAnqpQuery (MacAddress macAddress, vec<AnqpInfoId> infoElements, vec<Hs20AnqpSubtypes> subTypes)
generates (SupplicantStatus status)

Initiate ANQP(for IEEE 802.11u Interworking/Hotspot 2.0)queries with the specified access point.The ANQP data fetched must be returned in the |ISupplicantStaIfaceCallback.onAnqpQueryDone| callback.

Details
Parameters
macAddress
MAC address of the access point.
infoElements
List of information elements to query for.
subTypes
List of HS20 subtypes to query for.
Generates
status
Status of the operation.Possible status codes:|SupplicantStatusCode.SUCCESS|, |SupplicantStatusCode.FAILURE_UNKNOWN|, |SupplicantStatusCode.FAILURE_IFACE_INVALID|

initiateHs20IconQuery

initiateHs20IconQuery (MacAddress macAddress, string fileName)
generates (SupplicantStatus status)

Initiate the Hotspot 2.0 icon query with the specified accesss point.The icon data fetched must be returned in the |ISupplicantStaIfaceCallback.onHs20IconQueryDone| callback.

Details
Parameters
macAddress
MAC address of the access point.
fileName
Name of the file to request from the access point.
Generates
status
Status of the operation.Possible status codes:|SupplicantStatusCode.SUCCESS|, |SupplicantStatusCode.FAILURE_UNKNOWN|, |SupplicantStatusCode.FAILURE_IFACE_INVALID|

getMacAddress

getMacAddress ()
generates (SupplicantStatus status, MacAddress macAddr)

Send driver command to get MAC address of the device.

Details
Generates
status
Status of the operation.Possible status codes:|SupplicantStatusCode.SUCCESS|, |SupplicantStatusCode.FAILURE_UNKNOWN|, |SupplicantStatusCode.FAILURE_IFACE_INVALID|
macAddr
MAC address of the device.

startRxFilter

startRxFilter ()
generates (SupplicantStatus status)

Send driver command to start RX filter.

Details
Generates
status
Status of the operation.Possible status codes:|SupplicantStatusCode.SUCCESS|, |SupplicantStatusCode.FAILURE_UNKNOWN|, |SupplicantStatusCode.FAILURE_IFACE_INVALID|

stopRxFilter

stopRxFilter ()
generates (SupplicantStatus status)

Send driver command to stop RX filter.

Details
Generates
status
Status of the operation.Possible status codes:|SupplicantStatusCode.SUCCESS|, |SupplicantStatusCode.FAILURE_UNKNOWN|, |SupplicantStatusCode.FAILURE_IFACE_INVALID|

addRxFilter

addRxFilter (RxFilterType type)
generates (SupplicantStatus status)

Send driver command to add the specified RX filter.

Details
Parameters
type
Type of filter.
Generates
status
Status of the operation.Possible status codes:|SupplicantStatusCode.SUCCESS|, |SupplicantStatusCode.FAILURE_UNKNOWN|, |SupplicantStatusCode.FAILURE_IFACE_INVALID|

removeRxFilter

removeRxFilter (RxFilterType type)
generates (SupplicantStatus status)

Send driver command to remove the specified RX filter.

Details
Parameters
type
Type of filter.
Generates
status
Status of the operation.Possible status codes:|SupplicantStatusCode.SUCCESS|, |SupplicantStatusCode.FAILURE_UNKNOWN|, |SupplicantStatusCode.FAILURE_IFACE_INVALID|

setBtCoexistenceMode

setBtCoexistenceMode (BtCoexistenceMode mode)
generates (SupplicantStatus status)

Send driver command to set Bluetooth coexistence mode.

Details
Parameters
mode
Mode of Bluetooth coexistence.
Generates
status
Status of the operation.Possible status codes:|SupplicantStatusCode.SUCCESS|, |SupplicantStatusCode.FAILURE_UNKNOWN|, |SupplicantStatusCode.FAILURE_IFACE_INVALID|

setBtCoexistenceScanModeEnabled

setBtCoexistenceScanModeEnabled (bool enable)
generates (SupplicantStatus status)

Send driver command to set Bluetooth coexistence scan mode.When this mode is on, some of the low-level scan parameters used by the driver are changed to reduce interference with A2DP streaming.

Details
Parameters
enable
true to enable, false to disable.
Generates
status
Status of the operation.Possible status codes:|SupplicantStatusCode.SUCCESS|, |SupplicantStatusCode.FAILURE_UNKNOWN|, |SupplicantStatusCode.FAILURE_IFACE_INVALID|

setSuspendModeEnabled

setSuspendModeEnabled (bool enable)
generates (SupplicantStatus status)

Send driver command to set suspend optimizations for power save.

Details
Parameters
enable
true to enable, false to disable.
Generates
status
Status of the operation.Possible status codes:|SupplicantStatusCode.SUCCESS|, |SupplicantStatusCode.FAILURE_UNKNOWN|, |SupplicantStatusCode.FAILURE_IFACE_INVALID|

setCountryCode

setCountryCode (int8_t[2] code)
generates (SupplicantStatus status)

Send driver command to set country code.

Details
Parameters
code
2 byte country code(as defined in ISO 3166)to set.
Generates
status
Status of the operation.Possible status codes:|SupplicantStatusCode.SUCCESS|, |SupplicantStatusCode.FAILURE_UNKNOWN|, |SupplicantStatusCode.FAILURE_IFACE_INVALID|

startWpsRegistrar

startWpsRegistrar (Bssid bssid, string pin)
generates (SupplicantStatus status)

Initiate WPS setup in registrar role to learn the current AP configuration.

Details
Parameters
bssid
BSSID of the AP.
pin
Pin of the AP.
Generates
status
Status of the operation.Possible status codes:|SupplicantStatusCode.SUCCESS|, |SupplicantStatusCode.FAILURE_UNKNOWN|, |SupplicantStatusCode.FAILURE_IFACE_INVALID|

startWpsPbc

startWpsPbc (Bssid bssid)
generates (SupplicantStatus status)

Initiate WPS Push Button setup.The PBC operation requires that a button is also pressed at the AP/Registrar at about the same time(2 minute window).

Details
Parameters
bssid
BSSID of the AP.Use zero'ed bssid to indicate wildcard.
Generates
status
Status of the operation.Possible status codes:|SupplicantStatusCode.SUCCESS|, |SupplicantStatusCode.FAILURE_UNKNOWN|, |SupplicantStatusCode.FAILURE_IFACE_INVALID|

startWpsPinKeypad

startWpsPinKeypad (string pin)
generates (SupplicantStatus status)

Initiate WPS Pin Keypad setup.

Details
Parameters
pin
8 digit pin to be used.
Generates
status
Status of the operation.Possible status codes:|SupplicantStatusCode.SUCCESS|, |SupplicantStatusCode.FAILURE_UNKNOWN|, |SupplicantStatusCode.FAILURE_IFACE_INVALID|

startWpsPinDisplay

startWpsPinDisplay (Bssid bssid)
generates (SupplicantStatus status, string generatedPin)

Initiate WPS Pin Display setup.

Details
Parameters
bssid
BSSID of the AP.Use zero'ed bssid to indicate wildcard.
Generates
status
Status of the operation.Possible status codes:|SupplicantStatusCode.SUCCESS|, |SupplicantStatusCode.FAILURE_UNKNOWN|, |SupplicantStatusCode.FAILURE_IFACE_INVALID|
generatedPin
8 digit pin generated.

cancelWps

cancelWps ()
generates (SupplicantStatus status)

Cancel any ongoing WPS operations.

Details
Generates
status
Status of the operation.Possible status codes:|SupplicantStatusCode.SUCCESS|, |SupplicantStatusCode.FAILURE_UNKNOWN|, |SupplicantStatusCode.FAILURE_IFACE_INVALID|

setExternalSim

setExternalSim (bool useExternalSim)
generates (SupplicantStatus status)

Use external processing for SIM/USIM operations

Details
Parameters
useExternalSim
true to use external, false otherwise.
Generates
status
Status of the operation.Possible status codes:|SupplicantStatusCode.SUCCESS|, |SupplicantStatusCode.FAILURE_UNKNOWN|, |SupplicantStatusCode.FAILURE_IFACE_INVALID|

addExtRadioWork

addExtRadioWork (string name, uint32_t freqInMhz, uint32_t timeoutInSec)
generates (SupplicantStatus status, uint32_t id)

External programs can request supplicant to not start offchannel operations during other tasks that may need exclusive control of the radio.

This method can be used to reserve a slot for radio access.If freq is specified, other radio work items on the same channel can be completed in parallel.Otherwise, all other radio work items are blocked during execution.Timeout must be set to |ExtRadioWorkDefaults.TIMEOUT_IN_SECS| seconds by default to avoid blocking supplicant operations on the iface for excessive time.If a longer(or shorter)safety timeout is needed, that may be specified with the optional timeout parameter.This command returns an identifier for the radio work item.

Once the radio work item has been started, |ISupplicant.onExtRadioWorkStart| callback is indicated that the external processing can start.

Details
Parameters
name
Name for the radio work being added.
freqInMhz
Frequency to specify.Set to 0 for all channels.
timeoutInSec
Timeout tospecify.Set to 0 for default timeout.
Generates
status
Status of the operation.Possible status codes:|SupplicantStatusCode.SUCCESS|, |SupplicantStatusCode.FAILURE_UNKNOWN|
id
Identifier for this radio work.

removeExtRadioWork

removeExtRadioWork (uint32_t id)
generates (SupplicantStatus status)

Indicates to supplicant that the external radio work has completed.This allows other radio works to be performed.If this method is not invoked(e.g ., due to the external program terminating), supplicant must time out the radio work item on the iface and send |ISupplicantCallback.onExtRadioWorkTimeout| event to indicate that this has happened.

This method may also be used to cancel items that have been scheduled via |addExtRadioWork|, but have not yet been started(notified via |ISupplicantCallback.onExtRadioWorkStart|).

Details
Parameters
id
Identifier generated for the radio work addition(using |addExtRadioWork|).
Generates
status
Status of the operation.Possible status codes:|SupplicantStatusCode.SUCCESS|, |SupplicantStatusCode.FAILURE_UNKNOWN|

enableAutoReconnect

enableAutoReconnect (bool enable)
generates (SupplicantStatus status)

Enable/Disable auto reconnect to networks.Use this to prevent wpa_supplicant from trying to connect to networks on its own.

Details
Parameters
enable
true to enable, false to disable.
Generates
status
Status of the operation.Possible status codes:|SupplicantStatusCode.SUCCESS|, |SupplicantStatusCode.FAILURE_UNKNOWN|, |SupplicantStatusCode.FAILURE_IFACE_INVALID|, |SupplicantStatusCode.FAILURE_IFACE_DISABLED|