Infineon AIROC CYW43012 Manual page 14

Low-power system design wi-fi & bluetooth combo chip and psoc 6 mcu
Table of Contents

Advertisement

Low-power system design with AIROC™ Wi-Fi & Bluetooth® combo
chip and PSoC™ 6 MCU
WLAN power optimization techniques
WHD API
whd_wifi_enable_powersave_with_t
hroughput()
whd_wifi_disable_powersave()
whd_wifi_set_listen_interval()
whd_wifi_get_listen_interval()
It should be noted that power save with throughput is enabled in the WLAN device by default. The
enable/disable power save APIs can be called to change or disable power save option in the WLAN. The WLAN
automatically manages the entry and exit of DS0 after the power save is enabled. The
lowpower
code example demonstrates the use of WHD power save APIs.
An example implementation of a power save handler using WHD APIs in ModusToolbox™ is as follows:
Code Listing 1
Example: Power save handler using WHD APIs in ModusToolbox™
cy_rslt_t wlan_powersave_handler(struct netif *wifi, enum wlan_powersave_mode_t
mode)
{
cy_rslt_t result = CY_RSLT_SUCCESS;
whd_interface_t ifp;
whd_security_t security_param;
whd_bss_info_t ap_info;
if (wifi->flags & NETIF_FLAG_UP)
{
/* Get the instance of the WLAN interface.*/
ifp = (whd_interface_t)wifi->state;
/* Obtain network parameters configured in the AP.*/
result = whd_wifi_get_ap_info(ifp, &ap_info, &security_param);
if (CY_RSLT_SUCCESS == result)
{
APP_INFO(("Beacon period = %d, DTIM period = %d\n",
}
else
Application note
Description
Enables 802.11 PS-non-poll mode in the device (see
power save without
maintain throughput.
Disables power save mode in the device; by default, power save
is enabled in the WLAN device.
Sets the number of beacons to be skipped while the Wi-Fi chip is
sleeping. Only works when Wi-Fi power save is enabled and the
DTIM interval broadcasted by the AP is zero (i.e., no DTIM in the
network).
Gets the current value of all beacon listen interval variables
ap_info.beacon_period, ap_info.dtim_period));
poll). Use this mode when it is important to
14
802.11
mtb-example-wifi-wlan-
002-27910 Rev. *C
2023-05-29

Advertisement

Table of Contents
loading

Table of Contents