esp_wifi_set_country returns ESP_ERR_WIFI_ARG
Posted: Mon Oct 30, 2017 8:05 am
Hello,
I wanted to limit the possible channels the station is scanning when trying to connect using the esp_wifi_set_country API:
But esp_wifi_set_country seems to return ESP_ERR_WIFI_ARG for anything that specifies schan other than 1. Also the nchan does not seem to be respected, as the ESP32 still connects to APs outside of the channel range [schan, schan + nchan).
Could somebody please give an update on how this API is supposed to work?
Hope it is not a problem to ask questions about APIs in master branch!
Thanks for all the good stuff thats coming into the ESP-IDF!
I wanted to limit the possible channels the station is scanning when trying to connect using the esp_wifi_set_country API:
Code: Select all
wifi_country_t country = {
.cc = "EU",
.schan = 3,
.nchan = 1,
.policy = WIFI_COUNTRY_POLICY_AUTO,
};
int ret = esp_wifi_set_country(&country); // returns ESP_ERR_WIFI_ARG
Could somebody please give an update on how this API is supposed to work?
Hope it is not a problem to ask questions about APIs in master branch!
Thanks for all the good stuff thats coming into the ESP-IDF!