From fce13679a05c879812422f836cc9f9b0edbd82b1 Mon Sep 17 00:00:00 2001 From: muhaidong Date: Tue, 19 May 2026 21:01:37 +0800 Subject: [PATCH] fix(doc): gate 5 GHz min-channel note on SOC_WIFI_SUPPORT_5G --- docs/en/api-guides/wifi.rst | 8 +++++++- docs/zh_CN/api-guides/wifi.rst | 8 +++++++- 2 files changed, 14 insertions(+), 2 deletions(-) diff --git a/docs/en/api-guides/wifi.rst b/docs/en/api-guides/wifi.rst index bbde0ea0708..a6c93f9d9f2 100644 --- a/docs/en/api-guides/wifi.rst +++ b/docs/en/api-guides/wifi.rst @@ -1439,7 +1439,13 @@ API :cpp:func:`esp_wifi_set_config()` can be used to configure the AP. And the c * - ssid_len - Length of SSID; if ssid_len is 0, check the SSID until there is a termination character. If ssid_len > 32, change it to 32; otherwise, set the SSID length according to ssid_len. * - channel - - Channel of AP; set to 0 for auto selection (min channel: typically 1 for 2.4G, 36 for 5G). Other invalid values return ``ESP_ERR_INVALID_ARG``. So, please make sure the channel is within the required range. For more details, refer to `Wi-Fi Country Code`_. + - .. only:: SOC_WIFI_SUPPORT_5G + + Channel of AP; set to 0 for auto selection (min channel: typically 1 for 2.4G, 36 for 5G). Other invalid values return ``ESP_ERR_INVALID_ARG``. So, please make sure the channel is within the required range. For more details, refer to `Wi-Fi Country Code`_. + + .. only:: not SOC_WIFI_SUPPORT_5G + + Channel of AP; set to 0 for auto selection (min channel: typically 1 for 2.4G). Other invalid values return ``ESP_ERR_INVALID_ARG``. So, please make sure the channel is within the required range. For more details, refer to `Wi-Fi Country Code`_. * - authmode - Auth mode of ESP AP; currently, ESP AP does not support AUTH_WEP. If the authmode is an invalid value, AP defaults the value to ``WIFI_AUTH_OPEN``. * - ssid_hidden diff --git a/docs/zh_CN/api-guides/wifi.rst b/docs/zh_CN/api-guides/wifi.rst index d97de65279d..d70f81f41b5 100644 --- a/docs/zh_CN/api-guides/wifi.rst +++ b/docs/zh_CN/api-guides/wifi.rst @@ -1441,7 +1441,13 @@ API :cpp:func:`esp_wifi_set_config()` 可用于配置 AP。配置的参数信息 * - ssid_len - SSID 的长度。如果 ssid_len 为 0,则检查 SSID 直至出现终止字符。如果 ssid_len 大于 32,请更改为 32,或者根据 ssid_len 设置 SSID 长度。 * - channel - - AP 的信道。设为 0 表示自动选择(最小信道:2.4 GHz 通常为 1,5 GHz 通常为 36)。其它非法值将返回 ``ESP_ERR_INVALID_ARG``。请确保信道在允许范围内。更多说明请参阅 `Wi-Fi 国家/地区代码`_。 + - .. only:: SOC_WIFI_SUPPORT_5G + + AP 的信道。设为 0 表示自动选择(最小信道:2.4 GHz 通常为 1,5 GHz 通常为 36)。其它非法值将返回 ``ESP_ERR_INVALID_ARG``。请确保信道在允许范围内。更多说明请参阅 `Wi-Fi 国家/地区代码`_。 + + .. only:: not SOC_WIFI_SUPPORT_5G + + AP 的信道。设为 0 表示自动选择(最小信道:2.4 GHz 通常为 1)。其它非法值将返回 ``ESP_ERR_INVALID_ARG``。请确保信道在允许范围内。更多说明请参阅 `Wi-Fi 国家/地区代码`_。 * - authmode - ESP AP 的身份验证模式。目前,ESP AP 不支持 AUTH_WEP。如果 authmode 是一个无效值,AP 默认该值为 ``WIFI_AUTH_OPEN``。 * - ssid_hidden