fix(wifi): fix some macro definition not correct

This commit is contained in:
yinqingzhao
2024-09-30 15:34:37 +08:00
parent af017d143a
commit 6e4d3104b2
2 changed files with 3 additions and 3 deletions

View File

@@ -40,7 +40,7 @@ menu "Example Configuration"
choice EXAMPLE_WIFI_BAND_MODE
prompt "wifi band"
default EXAMPLE_WIFI_BAND_MODE_2G
depends on SOC_WIFI_HE_SUPPORT_5G
depends on SOC_WIFI_SUPPORT_5G
help
WiFi band for the example to use.

View File

@@ -36,7 +36,7 @@
#define DEFAULT_PS_MODE WIFI_PS_NONE
#endif /*CONFIG_POWER_SAVE_MODEM*/
#if SOC_WIFI_HE_SUPPORT_5G
#if CONFIG_SOC_WIFI_SUPPORT_5G
#if CONFIG_EXAMPLE_WIFI_BAND_MODE_2G
#define DEFAULT_WIFI_BAND_MODE WIFI_BAND_MODE_2G_ONLY
#elif CONFIG_EXAMPLE_WIFI_BAND_MODE_5G
@@ -89,7 +89,7 @@ static void wifi_power_save(void)
ESP_ERROR_CHECK(esp_wifi_set_mode(WIFI_MODE_STA));
ESP_ERROR_CHECK(esp_wifi_set_config(WIFI_IF_STA, &wifi_config));
ESP_ERROR_CHECK(esp_wifi_start());
#if SOC_WIFI_HE_SUPPORT_5G
#if CONFIG_SOC_WIFI_SUPPORT_5G
ESP_ERROR_CHECK(esp_wifi_set_band_mode(DEFAULT_WIFI_BAND_MODE));
#endif
ESP_ERROR_CHECK(esp_wifi_set_inactive_time(WIFI_IF_STA, DEFAULT_BEACON_TIMEOUT));