diff --git a/docs/en/api-guides/wifi.rst b/docs/en/api-guides/wifi.rst index 62ca8d160e..6728dad472 100644 --- a/docs/en/api-guides/wifi.rst +++ b/docs/en/api-guides/wifi.rst @@ -1083,7 +1083,7 @@ The table below shows the reason-code defined in {IDF_TARGET_NAME}. The first co * - Reserved - 40 ~ 45 - 40 ~ 45 - - + - * - PEER_INITIATED - 46 - 46 @@ -2172,10 +2172,11 @@ Generally, following steps can be taken to configure the multiple antennas: - Configure which GPIOs are connected to the antenna_selects. For example, if four antennas are supported and GPIO20/GPIO21 are connected to antenna_select[0]/antenna_select[1], the configurations look like:: - wifi_ant_gpio_config_t config = { - { .gpio_select = 1, .gpio_num = 20 }, - { .gpio_select = 1, .gpio_num = 21 } + wifi_ant_gpio_config_t ant_gpio_config = { + .gpio_cfg[0] = { .gpio_select = 1, .gpio_num = 20 }, + .gpio_cfg[1] = { .gpio_select = 1, .gpio_num = 21 } }; + - Configure which antennas are enabled and how RX/TX use the enabled antennas. For example, if antenna1 and antenna3 are enabled, the RX needs to select the better antenna automatically and uses antenna1 as its default antenna, the TX always selects the antenna3. The configuration looks like:: wifi_ant_config_t config = { diff --git a/docs/zh_CN/api-guides/wifi.rst b/docs/zh_CN/api-guides/wifi.rst index f01cd08ef7..56b813813b 100644 --- a/docs/zh_CN/api-guides/wifi.rst +++ b/docs/zh_CN/api-guides/wifi.rst @@ -2172,9 +2172,9 @@ Wi-Fi 多根天线配置 - 配置 antenna_selects 连接哪些 GPIOs,例如,如果支持四根天线,且 GPIO20/GPIO21 连接到 antenna_select[0]/antenna_select[1],配置如下所示:: - wifi_ant_gpio_config_t config = { - { .gpio_select = 1, .gpio_num = 20 }, - { .gpio_select = 1, .gpio_num = 21 } + wifi_ant_gpio_config_t ant_gpio_config = { + .gpio_cfg[0] = { .gpio_select = 1, .gpio_num = 20 }, + .gpio_cfg[1] = { .gpio_select = 1, .gpio_num = 21 } }; - 配置使能哪些天线、以及接收/发送数据如何使用使能的天线,例如,如果使能了天线 1 和天线 3,接收数据需要自动选择较好的天线,并将天线 1 作为默认天线,发送数据始终选择天线 3。配置如下所示::