esp8266/network_wlan: Make WLAN.config('channel') use wifi_get_channel.
Prior to this fix, `WLAN.config('channel')` would return an incorrect
channel for AP_IF if STA has connected to an external AP running on a
different channel.
The esp8266 now has the same behaviour as for esp32 per commit
98d1c50159.
Fixes issue #11463.
Signed-off-by: Glenn Moloney <glenn.moloney@gmail.com>
This commit is contained in:
parent
3699cf5f38
commit
4bed77cc23
1 changed files with 1 additions and 2 deletions
|
|
@ -641,8 +641,7 @@ static mp_obj_t esp_config(size_t n_args, const mp_obj_t *args, mp_map_t *kwargs
|
|||
val = MP_OBJ_NEW_SMALL_INT(cfg.ap.authmode);
|
||||
break;
|
||||
case MP_QSTR_channel:
|
||||
req_if = SOFTAP_IF;
|
||||
val = MP_OBJ_NEW_SMALL_INT(cfg.ap.channel);
|
||||
val = MP_OBJ_NEW_SMALL_INT(wifi_get_channel());
|
||||
break;
|
||||
case MP_QSTR_hostname:
|
||||
case MP_QSTR_dhcp_hostname: {
|
||||
|
|
|
|||
Loading…
Reference in a new issue