|
|
@ -640,6 +640,17 @@ int ICACHE_FLASH_ATTR cgiApSettingsChange(HttpdConnData *connData) { |
|
|
|
apconf.ssid_hidden = 0; |
|
|
|
apconf.ssid_hidden = 0; |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
// Set channel to be hidden or not
|
|
|
|
|
|
|
|
len=httpdFindArg(connData->getArgs, "ap_channel", buff, sizeof(buff)); |
|
|
|
|
|
|
|
if(len>0){ |
|
|
|
|
|
|
|
int value = atoi(buff); |
|
|
|
|
|
|
|
if(value >= 1 || value <= 13){ |
|
|
|
|
|
|
|
apconf.channel = value; |
|
|
|
|
|
|
|
}else{ |
|
|
|
|
|
|
|
// If out of range, set by default
|
|
|
|
|
|
|
|
apconf.channel = 1; |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
// Store new configuration
|
|
|
|
// Store new configuration
|
|
|
|
wifi_softap_set_config(&apconf); |
|
|
|
wifi_softap_set_config(&apconf); |
|
|
|
|
|
|
|
|
|
|
@ -659,6 +670,7 @@ int ICACHE_FLASH_ATTR cgiApSettingsInfo(HttpdConnData *connData) { |
|
|
|
"\"ap_authmode\": %d, " |
|
|
|
"\"ap_authmode\": %d, " |
|
|
|
"\"ap_maxconn\": %d, " |
|
|
|
"\"ap_maxconn\": %d, " |
|
|
|
"\"ap_beacon\": %d, " |
|
|
|
"\"ap_beacon\": %d, " |
|
|
|
|
|
|
|
"\"ap_channel\": %d, " |
|
|
|
"\"ap_hidden\": \"%s\" " |
|
|
|
"\"ap_hidden\": \"%s\" " |
|
|
|
" }", |
|
|
|
" }", |
|
|
|
apconf.ssid, |
|
|
|
apconf.ssid, |
|
|
@ -666,6 +678,7 @@ int ICACHE_FLASH_ATTR cgiApSettingsInfo(HttpdConnData *connData) { |
|
|
|
apconf.authmode, |
|
|
|
apconf.authmode, |
|
|
|
apconf.max_connection, |
|
|
|
apconf.max_connection, |
|
|
|
apconf.beacon_interval, |
|
|
|
apconf.beacon_interval, |
|
|
|
|
|
|
|
apconf.channel, |
|
|
|
apconf.ssid_hidden ? "enabled" : "disabled" |
|
|
|
apconf.ssid_hidden ? "enabled" : "disabled" |
|
|
|
); |
|
|
|
); |
|
|
|
|
|
|
|
|
|
|
|