Morse Micro IoT SDK  2.9.7
mmwlan_sta_args Struct Reference

Detailed Description

Arguments data structure for mmwlan_sta_enable().

This structure should be initialized using MMWLAN_STA_ARGS_INIT for sensible default values, particularly for forward compatibility with new releases that may add new fields to the struct. For example:

enum mmwlan_status status;
// HERE: initialize arguments
status = mmwlan_sta_enable(&sta_args);
enum mmwlan_status mmwlan_sta_enable(const struct mmwlan_sta_args *args, mmwlan_sta_status_cb_t sta_status_cb)
Enable station mode.
#define MMWLAN_STA_ARGS_INIT
Initializer for mmwlan_sta_args.
Definition: mmwlan.h:1016
mmwlan_status
Enumeration of status return codes.
Definition: mmwlan.h:50
Arguments data structure for mmwlan_sta_enable().
Definition: mmwlan.h:900

Definition at line 899 of file mmwlan.h.

#include <mmwlan.h>

Data Fields

uint8_t ssid [MMWLAN_SSID_MAXLEN]
 SSID of the AP to connect to. More...
 
uint16_t ssid_len
 Length of the SSID. More...
 
uint8_t bssid [MMWLAN_MAC_ADDR_LEN]
 BSSID of the AP to connect to. More...
 
enum mmwlan_security_type security_type
 Type of security to use. More...
 
char passphrase [MMWLAN_PASSPHRASE_MAXLEN+1]
 Passphrase (only used if security_type is MMWLAN_SAE, otherwise ignored. More...
 
uint16_t passphrase_len
 Length of passphrase. More...
 
enum mmwlan_pmf_mode pmf_mode
 Protected Management Frame mode to use (802.11w) More...
 
int16_t raw_sta_priority
 Priority used by the AP to assign a STA to a Restricted Access Window (RAW) group. More...
 
enum mmwlan_station_type sta_type
 S1G non-AP STA type. More...
 
int sae_owe_ec_groups [MMWLAN_MAX_EC_GROUPS]
 Preference list of enabled elliptic curve groups for SAE and OWE. More...
 
enum mmwlan_cac_mode cac_mode
 Whether Centralized Authentication Controlled is enabled on the STA. More...
 
uint16_t bgscan_short_interval_s
 Background scan short interval, measured in seconds. More...
 
int bgscan_signal_threshold_dbm
 Background scan signal strength threshold that switches between short and long intervals. More...
 
uint16_t bgscan_long_interval_s
 Background scan long interval, measured in seconds. More...
 
mmwlan_scan_rx_cb_t scan_rx_cb
 Optional callback for scan results which are received during the connection process. More...
 
void * scan_rx_cb_arg
 Opaque argument to be passed to scan_rx_cb. More...
 
uint16_t scan_interval_base_s
 The base scan interval (in seconds) to use when (re)connecting. More...
 
uint16_t scan_interval_limit_s
 The maximum interval between scan attempts when (re)connecting. More...
 
uint8_t * extra_assoc_ies
 Extra Information Elements to include in association request frames. More...
 
size_t extra_assoc_ies_len
 Length of extra_assoc_ies. More...
 
mmwlan_sta_event_cb_t sta_evt_cb
 STA event callback with a user-defined opaque parameter. More...
 
void * sta_evt_cb_arg
 STA event callback argument to be passed to sta_evt_cb. More...
 
enum mmwlan_4addr_mode use_4addr
 Whether the station should use Linux 4-address mode. More...
 

Field Documentation

◆ bgscan_long_interval_s

uint16_t mmwlan_sta_args::bgscan_long_interval_s

Background scan long interval, measured in seconds.

When the signal strength is above bgscan_signal_threshold_dbm, this interval will be used between iterations of background scan. If the signal threshold falls below bgscan_signal_threshold_dbm, background scan will use the short interval.

Note
Setting this to zero will disable background scanning.

Definition at line 957 of file mmwlan.h.

◆ bgscan_short_interval_s

uint16_t mmwlan_sta_args::bgscan_short_interval_s

Background scan short interval, measured in seconds.

When the signal strength falls below bgscan_signal_threshold_dbm, this interval will be used between iterations of background scan. After several iterations, or if the signal threshold increases above bgscan_signal_threshold_dbm background scan will return to using the long interval.

Note
Setting this to zero will disable background scanning.

Definition at line 942 of file mmwlan.h.

◆ bgscan_signal_threshold_dbm

int mmwlan_sta_args::bgscan_signal_threshold_dbm

Background scan signal strength threshold that switches between short and long intervals.

Definition at line 946 of file mmwlan.h.

◆ bssid

uint8_t mmwlan_sta_args::bssid[MMWLAN_MAC_ADDR_LEN]

BSSID of the AP to connect to.

If non-zero, the STA will only connect to an AP that matches this value.

Definition at line 909 of file mmwlan.h.

◆ cac_mode

enum mmwlan_cac_mode mmwlan_sta_args::cac_mode

Whether Centralized Authentication Controlled is enabled on the STA.

Definition at line 931 of file mmwlan.h.

◆ extra_assoc_ies

uint8_t* mmwlan_sta_args::extra_assoc_ies

Extra Information Elements to include in association request frames.

Should be NULL if extra_assoc_ies_len is zero. It is the caller's responsibility to handle potentially duplicate IEs. It is the caller's responsibility to free this buffer after calling mmwlan_sta_enable().

Definition at line 986 of file mmwlan.h.

◆ extra_assoc_ies_len

size_t mmwlan_sta_args::extra_assoc_ies_len

Length of extra_assoc_ies.

Definition at line 988 of file mmwlan.h.

◆ passphrase

char mmwlan_sta_args::passphrase[MMWLAN_PASSPHRASE_MAXLEN+1]

Passphrase (only used if security_type is MMWLAN_SAE, otherwise ignored.

Definition at line 913 of file mmwlan.h.

◆ passphrase_len

uint16_t mmwlan_sta_args::passphrase_len

Length of passphrase.

May be zero if passphrase is null-terminated.

Definition at line 915 of file mmwlan.h.

◆ pmf_mode

enum mmwlan_pmf_mode mmwlan_sta_args::pmf_mode

Protected Management Frame mode to use (802.11w)

Definition at line 917 of file mmwlan.h.

◆ raw_sta_priority

int16_t mmwlan_sta_args::raw_sta_priority

Priority used by the AP to assign a STA to a Restricted Access Window (RAW) group.

Valid range is 0 - MMWLAN_RAW_MAX_PRIORITY, or -1 to disable RAW.

Definition at line 922 of file mmwlan.h.

◆ sae_owe_ec_groups

int mmwlan_sta_args::sae_owe_ec_groups[MMWLAN_MAX_EC_GROUPS]

Preference list of enabled elliptic curve groups for SAE and OWE.

By default (if this parameter is not set), the mandatory group 19 is preferred.

Definition at line 929 of file mmwlan.h.

◆ scan_interval_base_s

uint16_t mmwlan_sta_args::scan_interval_base_s

The base scan interval (in seconds) to use when (re)connecting.

An exponential back off is applied such that if the AP is not found during the first scan, we will wait for scan_interval_base_s seconds before attempting the second scan, then scan_interval_base_s squared seconds before attempting for the next scan, and so on until scan_interval_limit_s is reached.

If this is 0 then the MMWLAN_DEFAULT_SCAN_INTERVAL_BASE_S will be used.

Definition at line 971 of file mmwlan.h.

◆ scan_interval_limit_s

uint16_t mmwlan_sta_args::scan_interval_limit_s

The maximum interval between scan attempts when (re)connecting.

The scan algorithm will begin with an interval of scan_interval_base_s between scans and increase the interval exponentially until this limit is reached.

If this is 0 then the MMWLAN_DEFAULT_SCAN_INTERVAL_LIMIT_S will be used.

Definition at line 979 of file mmwlan.h.

◆ scan_rx_cb

mmwlan_scan_rx_cb_t mmwlan_sta_args::scan_rx_cb

Optional callback for scan results which are received during the connection process.

Definition at line 959 of file mmwlan.h.

◆ scan_rx_cb_arg

void* mmwlan_sta_args::scan_rx_cb_arg

Opaque argument to be passed to scan_rx_cb.

Definition at line 961 of file mmwlan.h.

◆ security_type

enum mmwlan_security_type mmwlan_sta_args::security_type

Type of security to use.

If MMWLAN_SAE then a passphrase must be specified.

Definition at line 911 of file mmwlan.h.

◆ ssid

uint8_t mmwlan_sta_args::ssid[MMWLAN_SSID_MAXLEN]

SSID of the AP to connect to.

Definition at line 902 of file mmwlan.h.

◆ ssid_len

uint16_t mmwlan_sta_args::ssid_len

Length of the SSID.

Definition at line 904 of file mmwlan.h.

◆ sta_evt_cb

mmwlan_sta_event_cb_t mmwlan_sta_args::sta_evt_cb

STA event callback with a user-defined opaque parameter.

May be NULL.

Warning
BETA NOTICE: This is beta API that is under development; breaking changes may be introduced in future releases.

Definition at line 995 of file mmwlan.h.

◆ sta_evt_cb_arg

void* mmwlan_sta_args::sta_evt_cb_arg

STA event callback argument to be passed to sta_evt_cb.

May optionally be NULL. The value of this parameter must remain valid during the lifetime of the connection.

Warning
BETA NOTICE: This is beta API that is under development; breaking changes may be introduced in future releases.

Definition at line 1003 of file mmwlan.h.

◆ sta_type

enum mmwlan_station_type mmwlan_sta_args::sta_type

S1G non-AP STA type.

For valid STA types, mmwlan_station_type

Definition at line 924 of file mmwlan.h.

◆ use_4addr

enum mmwlan_4addr_mode mmwlan_sta_args::use_4addr

Whether the station should use Linux 4-address mode.

When connected to a Linux AP in 4-address mode, this will trigger the AP to move the STA to a separate virtual interface.

Definition at line 1008 of file mmwlan.h.


The documentation for this struct was generated from the following file: