Mistake on this page?
Report an issue in GitHub or email us
Functions
WHD Wi-Fi Utility API

Allows WHD to perform utility operations. More...

Functions

uint32_t whd_wifi_set_channel (whd_interface_t ifp, uint32_t channel)
 Set the current channel on the WLAN radio. More...
 
uint32_t whd_wifi_get_channel (whd_interface_t ifp, uint32_t *channel)
 Get the current channel on the WLAN radio. More...
 
uint32_t whd_wifi_set_passphrase (whd_interface_t ifp, const uint8_t *security_key, uint8_t key_length)
 Set the passphrase. More...
 
uint32_t whd_wifi_sae_password (whd_interface_t ifp, const uint8_t *security_key, uint8_t key_length)
 Set the SAE password. More...
 
uint32_t whd_wifi_enable_sup_set_passphrase (whd_interface_t ifp, const uint8_t *security_key_psk, uint8_t psk_length, whd_security_t auth_type)
 Enable WHD internal supplicant and set WPA2 passphrase in case of WPA3/WPA2 transition mode. More...
 
uint32_t whd_wifi_enable_supplicant (whd_interface_t ifp, whd_security_t auth_type)
 Enable WHD internal supplicant. More...
 
uint32_t whd_wifi_get_rssi (whd_interface_t ifp, int32_t *rssi)
 Retrieve the latest RSSI value. More...
 
uint32_t whd_wifi_get_ap_client_rssi (whd_interface_t ifp, int32_t *rssi, const whd_mac_t *client_mac)
 Retrieve the associated STA's RSSI value. More...
 
uint32_t whd_wifi_get_mac_address (whd_interface_t ifp, whd_mac_t *mac)
 Retrieves the current Media Access Control (MAC) address (or Ethernet hardware address) of the 802.11 device. More...
 
uint32_t whd_wifi_get_bssid (whd_interface_t ifp, whd_mac_t *bssid)
 Get the BSSID of the interface. More...
 
uint32_t whd_wifi_register_multicast_address (whd_interface_t ifp, const whd_mac_t *mac)
 Registers interest in a multicast address. More...
 
uint32_t whd_wifi_unregister_multicast_address (whd_interface_t ifp, const whd_mac_t *mac)
 Unregisters interest in a multicast address. More...
 
uint32_t whd_wifi_set_listen_interval (whd_interface_t ifp, uint8_t listen_interval, whd_listen_interval_time_unit_t time_unit)
 Sets the 802.11 powersave listen interval for a Wi-Fi client, and communicates the listen interval to the Access Point. More...
 
uint32_t whd_wifi_get_listen_interval (whd_interface_t ifp, whd_listen_interval_t *li)
 Gets the current value of all beacon listen interval variables. More...
 
uint32_t whd_wifi_is_ready_to_transceive (whd_interface_t ifp)
 Determines if a particular interface is ready to transceive ethernet packets. More...
 
uint32_t whd_wifi_get_acparams (whd_interface_t ifp, whd_edcf_ac_param_t *acp)
 Retrieve the latest STA EDCF AC parameters. More...
 
uint32_t whd_wifi_manage_custom_ie (whd_interface_t ifp, whd_custom_ie_action_t action, const uint8_t *oui, uint8_t subtype, const void *data, uint16_t length, uint16_t which_packets)
 Manage the addition and removal of custom IEs. More...
 
uint32_t whd_wifi_send_action_frame (whd_interface_t ifp, whd_af_params_t *af_params)
 Send a pre-prepared action frame. More...
 
uint32_t whd_wifi_set_coex_config (whd_interface_t ifp, whd_coex_config_t *coex_config)
 Set coex configuration. More...
 
whd_result_t whd_arp_version (whd_interface_t ifp, uint32_t *version)
 Get version of Device (WLAN) Firmware. More...
 
whd_result_t whd_arp_peerage_get (whd_interface_t ifp, uint32_t *seconds)
 Get ARP Offload Peer Age from Device (WLAN) Length of time in seconds before aging out an entry in the WLAN processor ARP table. More...
 
whd_result_t whd_arp_peerage_set (whd_interface_t ifp, uint32_t seconds)
 Set ARP Offload Peer Age in Device (WLAN) Length of time in seconds before aging out an entry in the WLAN processor ARP table. More...
 
whd_result_t whd_arp_arpoe_get (whd_interface_t ifp, uint32_t *agent_enable)
 Get ARP Offload Agent Enable from Device (WLAN) More...
 
whd_result_t whd_arp_arpoe_set (whd_interface_t ifp, uint32_t agent_enable)
 Set ARP Offload Agent Enable in Device (WLAN) Set Enable/Disable of ARP Offload Agent. More...
 
whd_result_t whd_arp_cache_clear (whd_interface_t ifp)
 Clear ARP Offload cache in Device (WLAN) More...
 
whd_result_t whd_arp_features_get (whd_interface_t ifp, uint32_t *features)
 Get ARP Offload Feature Flags from Device (WLAN) More...
 
whd_result_t whd_arp_features_set (whd_interface_t ifp, uint32_t features)
 Set ARP Offload Feature Flags in Device (WLAN) More...
 
whd_result_t whd_arp_features_print (uint32_t features, const char *title)
 Print ARP Offload Feature Flags in Human readable form to console. More...
 
whd_result_t whd_arp_hostip_list_add (whd_interface_t ifp, uint32_t *host_ipv4_list, uint32_t count)
 Add ARP Offload Host IP Identifier(s) to HostIP List to Device (WLAN) More...
 
whd_result_t whd_arp_hostip_list_add_string (whd_interface_t ifp, const char *ip_addr)
 Add One ARP Offload Host IP Identifier to HostIP List (mbed-style IP string) to Device (WLAN) More...
 
whd_result_t whd_arp_hostip_list_clear_id (whd_interface_t ifp, uint32_t ipv4_addr)
 Clear One ARP Offload Host IP Identifier from Host IP List in Device (WLAN) More...
 
whd_result_t whd_arp_hostip_list_clear_id_string (whd_interface_t ifp, const char *ip_addr)
 Clear One ARP Offload Host IP Identifier from Host IP List (mbed-style IP string) in Device (WLAN) More...
 
whd_result_t whd_arp_hostip_list_clear (whd_interface_t ifp)
 Clear all ARP Offload Host IP Identifier List. More...
 
whd_result_t whd_arp_hostip_list_get (whd_interface_t ifp, uint32_t count, uint32_t *host_ipv4_list, uint32_t *filled)
 Get ARP Offload Host IP Identifiers from Device (WLAN) More...
 
whd_result_t whd_arp_stats_clear (whd_interface_t ifp)
 Clear ARP Offload statistics in Device (WLAN) More...
 
whd_result_t whd_arp_stats_get (whd_interface_t ifp, whd_arp_stats_t *stats)
 Get ARP Offload statistics from Device (WLAN) More...
 
whd_result_t whd_arp_stats_print (whd_arp_stats_t *arp_stats, const char *title)
 Print ARP Offload statistics NOTE: call whd_arp_stats_get(), then print them using this function. More...
 
whd_result_t whd_pf_add_packet_filter (whd_interface_t ifp, const whd_packet_filter_t *settings)
 A filter must be added (e.g. More...
 
whd_result_t whd_pf_remove_packet_filter (whd_interface_t ifp, uint8_t filter_id)
 Remove a previously added filter. More...
 
whd_result_t whd_pf_enable_packet_filter (whd_interface_t ifp, uint8_t filter_id)
 After a filter has been added it can be enabled or disabled as needed. More...
 
whd_result_t whd_pf_disable_packet_filter (whd_interface_t ifp, uint8_t filter_id)
 After a filter has been added it can be enabled or disabled as needed. More...
 
whd_result_t whd_wifi_toggle_packet_filter (whd_interface_t ifp, uint8_t filter_id, whd_bool_t enable)
 After a filter has been added it can be enabled or disabled as needed. More...
 
whd_result_t whd_pf_get_packet_filter_mask_and_pattern (whd_interface_t ifp, uint8_t filter_id, uint32_t max_size, uint8_t *mask, uint8_t *pattern, uint32_t *size_out)
 Filters are implemented in WLAN subsystem as a bit pattern and matching bit mask that are applied to incoming packets. More...
 
whd_result_t whd_wifi_clear_packet_filter_stats (whd_interface_t ifp, uint32_t filter_id)
 Clear the packet filter stats associated with a filter id. More...
 
whd_result_t whd_pf_get_packet_filter_stats (whd_interface_t ifp, uint8_t filter_id, whd_pkt_filter_stats_t *stats)
 Return the stats associated with a filter. More...
 
whd_result_t whd_tko_param (whd_interface_t ifp, whd_tko_retry_t *whd_tko_retry, int set)
 Set/Get TKO retry & interval parameters. More...
 
whd_result_t whd_tko_get_status (whd_interface_t ifp, whd_tko_status_t *tko_status)
 Return the tko status for all indexes. More...
 
whd_result_t whd_tko_max_assoc (whd_interface_t ifp, uint8_t *max)
 Return the stats associated with a filter. More...
 
whd_result_t whd_tko_get_FW_connect (whd_interface_t ifp, uint8_t index, whd_tko_connect_t *whd_connect, uint16_t buflen)
 Return the stats associated with a filter. More...
 
whd_result_t whd_tko_toggle (whd_interface_t ifp, whd_bool_t enable)
 Return the stats associated with a filter. More...
 

Detailed Description

Allows WHD to perform utility operations.

Function Documentation

whd_result_t whd_arp_arpoe_get ( whd_interface_t  ifp,
uint32_t *  agent_enable 
)

Get ARP Offload Agent Enable from Device (WLAN)

Parameters
[in]ifp: pointer to handle instance of whd interface
[out]agent_enable: pointer to store value
Returns
whd_result_t
whd_result_t whd_arp_arpoe_set ( whd_interface_t  ifp,
uint32_t  agent_enable 
)

Set ARP Offload Agent Enable in Device (WLAN) Set Enable/Disable of ARP Offload Agent.

Parameters
[in]ifp: pointer to handle instance of whd interface
[in]agent_enable: Enable=1 / Disable=0
Returns
whd_result_t
whd_result_t whd_arp_cache_clear ( whd_interface_t  ifp)

Clear ARP Offload cache in Device (WLAN)

Parameters
[in]ifp: pointer to handle instance of whd interface
Returns
whd_result_t
whd_result_t whd_arp_features_get ( whd_interface_t  ifp,
uint32_t *  features 
)

Get ARP Offload Feature Flags from Device (WLAN)

Parameters
[in]ifp: pointer to handle instance of whd interface
[out]features: ptr to store currently set features - bit flags CY_ARP_OL_AGENT_ENABLE, etc. ARL_OL_AGENT | ARL_OL_SNOOP | ARP_OL_HOST_AUTO_REPLY | ARP_OL_PEER_AUTO_REPLY
Returns
whd_result_t
whd_result_t whd_arp_features_print ( uint32_t  features,
const char *  title 
)

Print ARP Offload Feature Flags in Human readable form to console.

Parameters
[in]features: feature flags to set (you can OR '|' multiple flags) CY_ARP_OL_AGENT_ENABLE, etc. ARL_OL_AGENT | ARL_OL_SNOOP | ARP_OL_HOST_AUTO_REPLY | ARP_OL_PEER_AUTO_REPLY
[in]title: Optional: Title for output (NULL == no title)
Returns
whd_result_t
whd_result_t whd_arp_features_set ( whd_interface_t  ifp,
uint32_t  features 
)

Set ARP Offload Feature Flags in Device (WLAN)

Parameters
[in]ifp: pointer to handle instance of whd interface
[in]features: features to set value (you can OR ('|') multiple flags) CY_ARP_OL_AGENT_ENABLE, etc. ARL_OL_AGENT | ARL_OL_SNOOP | ARP_OL_HOST_AUTO_REPLY | ARP_OL_PEER_AUTO_REPLY
Returns
whd_result_t
whd_result_t whd_arp_hostip_list_add ( whd_interface_t  ifp,
uint32_t *  host_ipv4_list,
uint32_t  count 
)

Add ARP Offload Host IP Identifier(s) to HostIP List to Device (WLAN)

Parameters
[in]ifp: pointer to handle instance of whd interface
[in]host_ipv4_list: pointer to host_ip data (IPv4, 1 uint32_t per ip addr)
[in]count: Number of array elements in host_ip
Returns
whd_result_t
whd_result_t whd_arp_hostip_list_add_string ( whd_interface_t  ifp,
const char *  ip_addr 
)

Add One ARP Offload Host IP Identifier to HostIP List (mbed-style IP string) to Device (WLAN)

Parameters
[in]ifp: pointer to handle instance of whd interface
[in]ip_addr: pointer to ip string (as returned from mbedos calls)
Returns
whd_result_t
whd_result_t whd_arp_hostip_list_clear ( whd_interface_t  ifp)

Clear all ARP Offload Host IP Identifier List.

Parameters
[in]ifp: pointer to handle instance of whd interface
Returns
whd_result_t
whd_result_t whd_arp_hostip_list_clear_id ( whd_interface_t  ifp,
uint32_t  ipv4_addr 
)

Clear One ARP Offload Host IP Identifier from Host IP List in Device (WLAN)

Parameters
[in]ifp: pointer to handle instance of whd interface
[in]ipv4_addr: ip addr expressed as a uint32_t
Returns
whd_result_t
whd_result_t whd_arp_hostip_list_clear_id_string ( whd_interface_t  ifp,
const char *  ip_addr 
)

Clear One ARP Offload Host IP Identifier from Host IP List (mbed-style IP string) in Device (WLAN)

Parameters
[in]ifp: pointer to handle instance of whd interface
[in]ip_addr: pointer to ip string (as returned from mbedos calls)
Returns
whd_result_t
whd_result_t whd_arp_hostip_list_get ( whd_interface_t  ifp,
uint32_t  count,
uint32_t *  host_ipv4_list,
uint32_t *  filled 
)

Get ARP Offload Host IP Identifiers from Device (WLAN)

Parameters
[in]ifp: pointer to handle instance of whd interface
[in]count: Number of array elements in host_ip
[out]host_ipv4_list: Pointer to structure array to store host_ip data
[out]filled: Number of array elements filled by this routine
Returns
whd_result_t
whd_result_t whd_arp_peerage_get ( whd_interface_t  ifp,
uint32_t *  seconds 
)

Get ARP Offload Peer Age from Device (WLAN) Length of time in seconds before aging out an entry in the WLAN processor ARP table.

Parameters
[in]ifp: pointer to handle instance of whd interface
[out]seconds: pointer to store value
Returns
whd_result_t
whd_result_t whd_arp_peerage_set ( whd_interface_t  ifp,
uint32_t  seconds 
)

Set ARP Offload Peer Age in Device (WLAN) Length of time in seconds before aging out an entry in the WLAN processor ARP table.

Parameters
[in]ifp: pointer to handle instance of whd interface
[in]seconds: Seconds to age out IP
Returns
whd_result_t
whd_result_t whd_arp_stats_clear ( whd_interface_t  ifp)

Clear ARP Offload statistics in Device (WLAN)

Parameters
[in]ifp: pointer to handle instance of whd interface
Returns
whd_result_t
whd_result_t whd_arp_stats_get ( whd_interface_t  ifp,
whd_arp_stats_t *  stats 
)

Get ARP Offload statistics from Device (WLAN)

Parameters
[in]ifp: pointer to handle instance of whd interface
[out]stats: Ptr to store statistics whd_arp_stats_t
Returns
whd_result_t
whd_result_t whd_arp_stats_print ( whd_arp_stats_t *  arp_stats,
const char *  title 
)

Print ARP Offload statistics NOTE: call whd_arp_stats_get(), then print them using this function.

Parameters
[in]arp_stats: Ptr to ARP statistics structure
[in]title: Optional: Title for output (NULL == no title)
Returns
whd_result_t
whd_result_t whd_arp_version ( whd_interface_t  ifp,
uint32_t *  version 
)

Get version of Device (WLAN) Firmware.

Parameters
[in]ifp: pointer to handle instance of whd interface
[out]version: pointer to store version #
Returns
whd_result_t
whd_result_t whd_pf_add_packet_filter ( whd_interface_t  ifp,
const whd_packet_filter_t settings 
)

A filter must be added (e.g.

created) before it can be enabled.

Parameters
[in]ifp: pointer to handle instance of whd interface
[in]settings: Ptr to filter settings whd_packet_filter_t
Returns
whd_result_t
whd_result_t whd_pf_disable_packet_filter ( whd_interface_t  ifp,
uint8_t  filter_id 
)

After a filter has been added it can be enabled or disabled as needed.

Parameters
[in]ifp: pointer to handle instance of whd interface
[in]filter_id: filter to disable
Returns
whd_result_t
whd_result_t whd_pf_enable_packet_filter ( whd_interface_t  ifp,
uint8_t  filter_id 
)

After a filter has been added it can be enabled or disabled as needed.

Parameters
[in]ifp: pointer to handle instance of whd interface
[in]filter_id: filter to enable
Returns
whd_result_t
whd_result_t whd_pf_get_packet_filter_mask_and_pattern ( whd_interface_t  ifp,
uint8_t  filter_id,
uint32_t  max_size,
uint8_t *  mask,
uint8_t *  pattern,
uint32_t *  size_out 
)

Filters are implemented in WLAN subsystem as a bit pattern and matching bit mask that are applied to incoming packets.

This API retrieves the pattern and mask.

Parameters
[in]ifp: pointer to handle instance of whd interface
[in]filter_id: which filter to retrieve
[in]max_size: size of both mask and pattern buffers
[out]mask: mask for this filter
[out]pattern: pattern for this filter
[out]size_out: length of both mask and pattern
Returns
whd_result_t
whd_result_t whd_pf_get_packet_filter_stats ( whd_interface_t  ifp,
uint8_t  filter_id,
whd_pkt_filter_stats_t *  stats 
)

Return the stats associated with a filter.

Parameters
[in]ifp: pointer to handle instance of whd interface
[in]filter_id: which filter
[out]stats: Ptr to store statistics wl_pkt_filter_stats_t
Returns
whd_result_t
whd_result_t whd_pf_remove_packet_filter ( whd_interface_t  ifp,
uint8_t  filter_id 
)

Remove a previously added filter.

Parameters
[in]ifp: pointer to handle instance of whd interface
[in]filter_id: filter to remove
Returns
whd_result_t
whd_result_t whd_tko_get_FW_connect ( whd_interface_t  ifp,
uint8_t  index,
whd_tko_connect_t *  whd_connect,
uint16_t  buflen 
)

Return the stats associated with a filter.

Parameters
[in]ifp: Pointer to handle instance of whd interface
[in]index: index for TCP offload connection
[out]whd_connect: tko_connect structure buffer from Firmware
[in]buflen: Buffer given for tko_connect
Returns
whd_result_t
whd_result_t whd_tko_get_status ( whd_interface_t  ifp,
whd_tko_status_t *  tko_status 
)

Return the tko status for all indexes.

Parameters
[in]ifp: Pointer to handle instance of whd interface
[out]tko_status: Ptr to store tko_status
Returns
whd_result_t
whd_result_t whd_tko_max_assoc ( whd_interface_t  ifp,
uint8_t *  max 
)

Return the stats associated with a filter.

Parameters
[in]ifp: Pointer to handle instance of whd interface
[out]max: returns Max TCP connections supported by WLAN Firmware
Returns
whd_result_t
whd_result_t whd_tko_param ( whd_interface_t  ifp,
whd_tko_retry_t *  whd_tko_retry,
int  set 
)

Set/Get TKO retry & interval parameters.

Parameters
[in]ifp: Pointer to handle instance of whd interface
[in]whd_tko_retry: whd retry & interval parameters structure
[in]set: Set/Get Flag
Returns
whd_result_t
whd_result_t whd_tko_toggle ( whd_interface_t  ifp,
whd_bool_t  enable 
)

Return the stats associated with a filter.

Parameters
[in]ifp: Pointer to handle instance of whd interface
[in]enable: Enable/Disable TCP Keepalive offload
Returns
whd_result_t
whd_result_t whd_wifi_clear_packet_filter_stats ( whd_interface_t  ifp,
uint32_t  filter_id 
)

Clear the packet filter stats associated with a filter id.

Parameters
[in]ifp: pointer to handle instance of whd interface
[in]filter_id: which filter
Returns
whd_result_t
uint32_t whd_wifi_enable_sup_set_passphrase ( whd_interface_t  ifp,
const uint8_t *  security_key_psk,
uint8_t  psk_length,
whd_security_t  auth_type 
)

Enable WHD internal supplicant and set WPA2 passphrase in case of WPA3/WPA2 transition mode.

Parameters
ifpPointer to handle instance of whd interface
security_key_pskThe security key (passphrase) which is to be set
psk_lengthlength of the key
auth_typeAuthentication type: WHD_SECURITY_WPA3_WPA2_PSK
Returns
WHD_SUCCESS when the supplicant variable and wpa2 passphrase is set Error code if an error occurred
uint32_t whd_wifi_enable_supplicant ( whd_interface_t  ifp,
whd_security_t  auth_type 
)

Enable WHD internal supplicant.

Parameters
ifpPointer to handle instance of whd interface
auth_typeAuthentication type
Returns
WHD_SUCCESS when the supplicant variable is set Error code if an error occurred
uint32_t whd_wifi_get_acparams ( whd_interface_t  ifp,
whd_edcf_ac_param_t *  acp 
)

Retrieve the latest STA EDCF AC parameters.

Retrieve the latest Station (STA) interface EDCF (Enhanced Distributed Coordination Function) Access Category parameters

Parameters
ifpPointer to handle instance of whd interface
acpThe location where the array of AC parameters will be stored
Returns
WHD_SUCCESS if the AC Parameters were successfully retrieved Error code if the AC Parameters were not retrieved
uint32_t whd_wifi_get_ap_client_rssi ( whd_interface_t  ifp,
int32_t *  rssi,
const whd_mac_t client_mac 
)

Retrieve the associated STA's RSSI value.

Parameters
ifp: Pointer to handle instance of whd interface
rssi: The location where the RSSI value will be stored
client_mac: Pointer to associated client's MAC address
Returns
WHD_SUCCESS : if the RSSI was successfully retrieved Error code : if the RSSI was not retrieved
uint32_t whd_wifi_get_bssid ( whd_interface_t  ifp,
whd_mac_t bssid 
)

Get the BSSID of the interface.

Parameters
ifpPointer to the whd_interface_t
bssidReturns the BSSID address (mac address) if associated
Returns
WHD_SUCCESS or Error code
uint32_t whd_wifi_get_channel ( whd_interface_t  ifp,
uint32_t *  channel 
)

Get the current channel on the WLAN radio.

Note
On most WLAN devices this will get the channel for both AP AND STA (since there is only one radio - it cannot be on two channels simulaneously)
Parameters
ifpPointer to handle instance of whd interface
channelPointer to receive the current channel
Returns
WHD_SUCCESS if the channel was successfully retrieved Error code if the channel was not successfully retrieved
uint32_t whd_wifi_get_listen_interval ( whd_interface_t  ifp,
whd_listen_interval_t li 
)

Gets the current value of all beacon listen interval variables.

Parameters
ifpPointer to handle instance of whd interface
liPowersave listen interval values
  • listen_interval_beacon : The current value of the listen interval set as a multiple of the beacon period
  • listen_interval_dtim : The current value of the listen interval set as a multiple of the DTIM period
  • listen_interval_assoc : The current value of the listen interval sent to access points in an association request frame
Returns
WHD_SUCCESS If all listen interval values are read successfully Error code If at least one of the listen interval values are NOT read successfully
uint32_t whd_wifi_get_mac_address ( whd_interface_t  ifp,
whd_mac_t mac 
)

Retrieves the current Media Access Control (MAC) address (or Ethernet hardware address) of the 802.11 device.

Parameters
ifpPointer to handle instance of whd interface
macPointer to a variable that the current MAC address will be written to
Returns
WHD_SUCCESS or Error code
uint32_t whd_wifi_get_rssi ( whd_interface_t  ifp,
int32_t *  rssi 
)

Retrieve the latest RSSI value.

Parameters
ifpPointer to handle instance of whd interface
rssiThe location where the RSSI value will be stored
Returns
WHD_SUCCESS if the RSSI was successfully retrieved Error code if the RSSI was not retrieved
uint32_t whd_wifi_is_ready_to_transceive ( whd_interface_t  ifp)

Determines if a particular interface is ready to transceive ethernet packets.

Parameters
ifpPointer to handle instance of whd interface
Returns
WHD_SUCCESS if the interface is ready to transceive ethernet packets WHD_NOTFOUND no AP with a matching SSID was found WHD_NOT_AUTHENTICATED Matching AP was found but it won't let you authenticate. This can occur if this device is in the block list on the AP. WHD_NOT_KEYED Device has authenticated and associated but has not completed the key exchange. This can occur if the passphrase is incorrect. Error code if the interface is not ready to transceive ethernet packets
uint32_t whd_wifi_manage_custom_ie ( whd_interface_t  ifp,
whd_custom_ie_action_t  action,
const uint8_t *  oui,
uint8_t  subtype,
const void *  data,
uint16_t  length,
uint16_t  which_packets 
)

Manage the addition and removal of custom IEs.

Parameters
ifpPointer to handle instance of whd interface
actionthe action to take (add or remove IE)
ouithe oui of the custom IE
subtypethe IE sub-type
dataa pointer to the buffer that hold the custom IE
lengththe length of the buffer pointed to by 'data'
which_packetsA mask to indicate in which all packets this IE should be included. See whd_ie_packet_flag_t.
Returns
WHD_SUCCESS if the custom IE action was successful Error code if the custom IE action failed
uint32_t whd_wifi_register_multicast_address ( whd_interface_t  ifp,
const whd_mac_t mac 
)

Registers interest in a multicast address.

Once a multicast address has been registered, all packets detected on the medium destined for that address are forwarded to the host. Otherwise they are ignored.

Parameters
ifpPointer to handle instance of whd interface
macEthernet MAC address
Returns
WHD_SUCCESS if the address was registered successfully Error code if the address was not registered
uint32_t whd_wifi_sae_password ( whd_interface_t  ifp,
const uint8_t *  security_key,
uint8_t  key_length 
)

Set the SAE password.

Parameters
ifpPointer to handle instance of whd interface
security_keyThe security key (password) which is to be set
key_lengthlength of the key
Returns
WHD_SUCCESS when the key is set Error code if an error occurred
uint32_t whd_wifi_send_action_frame ( whd_interface_t  ifp,
whd_af_params_t *  af_params 
)

Send a pre-prepared action frame.

Parameters
ifpPointer to handle instance of whd interface
af_paramsA pointer to a pre-prepared action frame structure
Returns
WHD_SUCCESS or Error code
uint32_t whd_wifi_set_channel ( whd_interface_t  ifp,
uint32_t  channel 
)

Set the current channel on the WLAN radio.

Note
On most WLAN devices this will set the channel for both AP AND STA (since there is only one radio - it cannot be on two channels simulaneously)
Parameters
ifpPointer to handle instance of whd interface
channelThe desired channel
Returns
WHD_SUCCESS if the channel was successfully set Error code if the channel was not successfully set
uint32_t whd_wifi_set_coex_config ( whd_interface_t  ifp,
whd_coex_config_t coex_config 
)

Set coex configuration.

Parameters
ifpPointer to handle instance of whd interface
coex_configPointer to the structure whd_coex_config_t
Returns
WHD_SUCCESS or Error code
uint32_t whd_wifi_set_listen_interval ( whd_interface_t  ifp,
uint8_t  listen_interval,
whd_listen_interval_time_unit_t  time_unit 
)

Sets the 802.11 powersave listen interval for a Wi-Fi client, and communicates the listen interval to the Access Point.

The listen interval will be set to (listen_interval x time_unit) seconds.

The default value for the listen interval is 0. With the default value of 0 set, the Wi-Fi device wakes to listen for AP beacons every DTIM period.

If the DTIM listen interval is non-zero, the DTIM listen interval will over ride the beacon listen interval value.

Parameters
ifpPointer to handle instance of whd interface
listen_intervalThe desired beacon listen interval
time_unitThe listen interval time unit; options are beacon period or DTIM period.
Returns
WHD_SUCCESS If the listen interval was successfully set. Error code If the listen interval was not successfully set.
uint32_t whd_wifi_set_passphrase ( whd_interface_t  ifp,
const uint8_t *  security_key,
uint8_t  key_length 
)

Set the passphrase.

Parameters
ifpPointer to handle instance of whd interface
security_keyThe security key (passphrase) which is to be set
key_lengthlength of the key
Returns
WHD_SUCCESS when the key is set Error code if an error occurred
whd_result_t whd_wifi_toggle_packet_filter ( whd_interface_t  ifp,
uint8_t  filter_id,
whd_bool_t  enable 
)

After a filter has been added it can be enabled or disabled as needed.

Parameters
[in]ifp: pointer to handle instance of whd interface
[in]filter_id: filter to disable/enable
[in]enable: Enable/Disable Flag
Returns
whd_result_t
uint32_t whd_wifi_unregister_multicast_address ( whd_interface_t  ifp,
const whd_mac_t mac 
)

Unregisters interest in a multicast address.

Once a multicast address has been unregistered, all packets detected on the medium destined for that address are ignored.

Parameters
ifpPointer to handle instance of whd interface
macEthernet MAC address
Returns
WHD_SUCCESS if the address was unregistered successfully Error code if the address was not unregistered
Important Information for this Arm website

This site uses cookies to store information on your computer. By continuing to use our site, you consent to our cookies. If you are not happy with the use of these cookies, please review our Cookie Policy to learn how they can be disabled. By disabling cookies, some features of the site will not work.