mirror of
https://github.com/espressif/ESP8266_RTOS_SDK.git
synced 2025-07-15 08:32:42 +08:00
Merge branch 'feature/add_softap_power_management' into 'master'
feat(wifi): add softap power management See merge request sdk/ESP8266_RTOS_SDK!1488
This commit is contained in:
@ -200,6 +200,21 @@ typedef enum {
|
||||
Attention: Using this option may cause ping failures. Not recommended */
|
||||
} wifi_ps_type_t;
|
||||
|
||||
/**
|
||||
* @brief Wi-Fi Power management config for ESP8266
|
||||
*
|
||||
* Pass a pointer to this structure as an argument to esp_wifi_set_pm_config function.
|
||||
*/
|
||||
typedef struct {
|
||||
uint8_t max_bcn_early_ms; /**< max beacon early time(2~15ms), default 4ms. */
|
||||
uint8_t max_bcn_timeout_ms; /**< max beacon timeout time(12~32ms), default 24ms. */
|
||||
uint8_t wait_time; /**< wait time before close RF (10~100ms), default 20ms. */
|
||||
uint8_t wait_tx_cnt; /**< wait cnt after tx packet done(1~20), default 2, real time = wait_tx_cnt * wait_time. */
|
||||
uint8_t wait_rx_bdata_cnt; /**< wait cnt after rx broadcast packet(1~100), default 2, real time = wait_tx_cnt * wait_time. */
|
||||
uint8_t wait_rx_udata_cnt; /**< wait cnt after rx unicast packet(1~100), default 4, real time = wait_tx_cnt * wait_time. */
|
||||
bool recv_bdata; /**< Receive broadcast/multicast packet or not when WiFi in power save. default true(receive broadcast/multicast packet)*/
|
||||
} esp_pm_config_t;
|
||||
|
||||
/**
|
||||
* @brief Power management config for ESP8266
|
||||
*
|
||||
|
@ -176,56 +176,18 @@ esp_err_t esp_wifi_internal_set_log_mod(uint32_t submodule);
|
||||
esp_err_t esp_wifi_internal_get_log(wifi_log_level_t *log_level, uint32_t *log_mod);
|
||||
|
||||
/**
|
||||
* @brief Receive broadcast/multicast packet or not when WiFi in power save.
|
||||
*
|
||||
* @param enable receive broadcast/multicast packet when set to true.
|
||||
* @brief get wifi power management config.
|
||||
*
|
||||
* @param ps_config power management config
|
||||
*/
|
||||
void esp_wifi_set_pm_recv_multi_data(bool enable);
|
||||
void esp_wifi_set_pm_config(esp_pm_config_t *pm_config);
|
||||
|
||||
/**
|
||||
* @brief Receive broadcast/multicast packet or not when WiFi in power save
|
||||
*
|
||||
* @return
|
||||
* - true: receive broadcast/multicast packet or not when WiFi in power save
|
||||
* - false: drop broadcast/multicast packet or not when WiFi in power save
|
||||
* @brief set wifi power management config.
|
||||
*
|
||||
* @param ps_config power management config
|
||||
*/
|
||||
bool esp_wifi_get_pm_recv_multi_data(void);
|
||||
|
||||
/**
|
||||
* @brief Set max beacon early time.
|
||||
*
|
||||
* @param max_bcn_early_ms max beacon early time(2~15ms), default 4ms.
|
||||
*/
|
||||
void esp_wifi_set_pm_max_bcn_early(uint8_t max_bcn_early_ms);
|
||||
|
||||
/**
|
||||
* @brief get max beacon early time.
|
||||
*/
|
||||
uint8_t esp_wifi_get_pm_max_bcn_early(void);
|
||||
|
||||
/**
|
||||
* @brief Set max beacon timeout time.
|
||||
*
|
||||
* @param max_bcn_early_ms max beacon timeout time(12~32ms), default 24ms.
|
||||
*/
|
||||
void esp_wifi_set_pm_max_bcn_timeout(uint8_t max_bcn_timeout_ms);
|
||||
|
||||
/**
|
||||
* @brief get max beacon timeout time.
|
||||
*/
|
||||
uint8_t esp_wifi_get_pm_max_bcn_timeout(void);
|
||||
|
||||
/**
|
||||
* @brief Set max wait tx rx time.
|
||||
*
|
||||
* @param max_bcn_early_ms max wait tx rx time(10~2000ms), default 20ms.
|
||||
*/
|
||||
void esp_wifi_set_pm_wait_tx_rx_time(uint32_t wait_tx_rx_time_ms);
|
||||
|
||||
/**
|
||||
* @brief get max wait tx rx time.
|
||||
*/
|
||||
uint32_t esp_wifi_get_pm_wait_tx_rx_time();
|
||||
void esp_wifi_get_pm_config(esp_pm_config_t *pm_config);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
|
@ -1,10 +1,10 @@
|
||||
gwen:
|
||||
core: 3c69aa1
|
||||
net80211: a2886c1
|
||||
pp: a2886c1
|
||||
espnow: 3c69aa1
|
||||
wps: 3c69aa1
|
||||
wpa2: 3c69aa1
|
||||
core: eecf230
|
||||
net80211: eecf230
|
||||
pp: eecf230
|
||||
espnow: eecf230
|
||||
wps: eecf230
|
||||
wpa2: eecf230
|
||||
|
||||
smartconfig: 2.8.2
|
||||
phy: 1163.0
|
||||
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Reference in New Issue
Block a user