Commit 4fa1731b authored by Paul Sokolovsky's avatar Paul Sokolovsky
Browse files

esp8266/modnetwork: .config(): Add "hidden ESSID" param.

parent cc1ef76f
......@@ -259,6 +259,11 @@ STATIC mp_obj_t esp_config(size_t n_args, const mp_obj_t *args, mp_map_t *kwargs
cfg.ap.ssid_len = len;
break;
}
case QS(MP_QSTR_hidden): {
req_if = SOFTAP_IF;
cfg.ap.ssid_hidden = mp_obj_is_true(kwargs->table[i].value);
break;
}
case QS(MP_QSTR_authmode): {
req_if = SOFTAP_IF;
cfg.ap.authmode = mp_obj_get_int(kwargs->table[i].value);
......@@ -314,6 +319,10 @@ STATIC mp_obj_t esp_config(size_t n_args, const mp_obj_t *args, mp_map_t *kwargs
req_if = SOFTAP_IF;
val = mp_obj_new_str((char*)cfg.ap.ssid, cfg.ap.ssid_len, false);
break;
case QS(MP_QSTR_hidden):
req_if = SOFTAP_IF;
val = mp_obj_new_bool(cfg.ap.ssid_hidden);
break;
case QS(MP_QSTR_authmode):
req_if = SOFTAP_IF;
val = MP_OBJ_NEW_SMALL_INT(cfg.ap.authmode);
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment