Module sta

Source
Expand description

WiFi Station (network client) runtime and types

Structs§

NetworkResult
A known WiFi network.
RequestClient
Request client wraps the request events, awaiting oneshot channels when appropriate
ScanResult
The result from scanning for networks.
WifiSetupGeneric
The generic WifiSetup struct which has generic constant parameters for adjusting queue size. WiFiSetup type is provided for convenience.
WifiStation
Instance that runs the Wifi process

Enums§

Broadcast
Broadcast events are unexpected, such as losing connection to the host network.
KeyMgmt
Key management types for WiFi networks (eg: WPA-PSK, WPA-EAP, etc). In theory, more than one may be configured, but I believe wpa_supplicant defaults to all of them if omitted. Therefore, in practice, this is mostly important for setting key_mgmt to None for an open network.
SelectResult
Result from selecting a network, including a success or a specific failure (eg: incorect psk). Timeout does not necessarily mean failure; it only means that we did not received a parseable response. It could be that some valid message isn’t being parsed by the library.

Type Aliases§

BroadcastReceiver
Channel for broadcasting events. Subscribing to this channel is equivalent to “wpa_ctrl_attach”. Can be temporarily silenced using broadcast::Receiver’s unsubscribe
ScanResults
A vector of ScanResult, wrapped in an Arc. If more than one client is awaiting the result of a scan, the result will be shared between them.
Status
A HashMap of what is returned when running wpa_cli status.
WifiSetup
A convenient default type for setting up the WiFi Station process.