如何快速切换路由
Re: 如何快速切换路由
如果知道路由的信道,可以通过esp_err_t esp_wifi_set_channel(uint8_t primary, wifi_second_chan_t second);加快接入速度吗,需要在什么时候设置
Re: 如何快速切换路由
esp_wifi_set_channel 有使用限制,不能在扫描或者已连接AP时使用,且即使设置了连接时候对于从未连接过的 AP 扫描仍是从 信道 1开始。
可以通过设置 wifi_config.sta.channel 配置要连接的 AP 信道,连接扫描时从该信道开始扫描。
如果知道 AP 的 bssid, 还可以设置 wifi_config.sta.bssid,wifi_config.sta.bssid_set = 1.
另外如果想了解 漫游功能,可以参考示例 example/wifi/roaming ,支持 802.11 kv 的漫游协议。
可以通过设置 wifi_config.sta.channel 配置要连接的 AP 信道,连接扫描时从该信道开始扫描。
如果知道 AP 的 bssid, 还可以设置 wifi_config.sta.bssid,wifi_config.sta.bssid_set = 1.
另外如果想了解 漫游功能,可以参考示例 example/wifi/roaming ,支持 802.11 kv 的漫游协议。
Re: 如何快速切换路由
802.11 kv 需要路由器的支持吧,并且需要做复杂的配置,我想在普通路由器上实现尽量快的切换
按上面的设置测试后
我发现如果之前连接的A路由器,断开后在连接A路由器,非常的快, 如果断开后连接到B路由器还是慢,这是什么原因?
按上面的设置测试后
我发现如果之前连接的A路由器,断开后在连接A路由器,非常的快, 如果断开后连接到B路由器还是慢,这是什么原因?
Re: 如何快速切换路由
是的,802.11kv 需要路由器支持。
第一次连接后保存了密钥信息,后面重连时候省略了计算时间,所以连接快。
连接新的 路由器,需要重新计算密钥,所以连接时间又变长了。
第一次连接后保存了密钥信息,后面重连时候省略了计算时间,所以连接快。
连接新的 路由器,需要重新计算密钥,所以连接时间又变长了。
Re: 如何快速切换路由
On ESP device side, is there any API to check if the access point has 802.11kv support?
Re: 如何快速切换路由
I haven't found API to check 802.11kv currently. But you can add output log to check 802.11k and 802.11v after the [line][https://github.com/espressif/esp-idf/bl ... mon.c#L205]
Code: Select all
printf("802.11k rrm_used = %d, 802.11v BSSTrans %d\n\r", g_wpa_supp.rrm.rrm_used, g_wpa_supp.extend_caps[2]&BIT3);
The log will print after ESP station connected to an AP.
If the AP supported 802.111kv, the log is “802.11k rrm_used = 1, 802.11v BSSTrans 8”.
Re: 如何快速切换路由
Hi LJY,
I want to know if the access point has 802.11kv support after the device joined an AP.
i.e. in case if access point does not support 802.11kv, I can know that and clarify the issue.
Otherwise, it's difficult to debug this issue when people reported issue like roaming does not happen.
(Some users are not technical people, they do not have access right to check the access point's settings).
ps. The printf does not help, my device has no console output in release build.
It would be helpful if there is a API to know if current connected access point have 802.11kv enabled or not.
(e.g. If esp_wifi_sta_get_ap_info() can get 802.11kv information in wifi_ap_record_t, it would be helpful).
I want to know if the access point has 802.11kv support after the device joined an AP.
i.e. in case if access point does not support 802.11kv, I can know that and clarify the issue.
Otherwise, it's difficult to debug this issue when people reported issue like roaming does not happen.
(Some users are not technical people, they do not have access right to check the access point's settings).
ps. The printf does not help, my device has no console output in release build.
It would be helpful if there is a API to know if current connected access point have 802.11kv enabled or not.
(e.g. If esp_wifi_sta_get_ap_info() can get 802.11kv information in wifi_ap_record_t, it would be helpful).
Re: 如何快速切换路由
Our wifi team has been working on it and will apply the API soon.axellin wrote: ↑Fri May 13, 2022 2:26 amHi LJY,
I want to know if the access point has 802.11kv support after the device joined an AP.
i.e. in case if access point does not support 802.11kv, I can know that and clarify the issue.
Otherwise, it's difficult to debug this issue when people reported issue like roaming does not happen.
(Some users are not technical people, they do not have access right to check the access point's settings).
ps. The printf does not help, my device has no console output in release build.
It would be helpful if there is a API to know if current connected access point have 802.11kv enabled or not.
(e.g. If esp_wifi_sta_get_ap_info() can get 802.11kv information in wifi_ap_record_t, it would be helpful).
Who is online
Users browsing this forum: No registered users and 27 guests