- Sat Jan 10, 2015 2:02 pm
#6924
Hi Sprite_em.. I think I found the reason for httpd not using saved AP info... in wifi.c 'setup_wifi_st_mode' routine I had to comment out some stuff:
if(wifi_station_get_config(&stconfig))
{
memset(stconfig.ssid, 0, sizeof(stconfig.ssid));
memset(stconfig.password, 0, sizeof(stconfig.password));
//os_sprintf(stconfig.ssid, "%s", WIFI_CLIENTSSID);
//os_sprintf(stconfig.password, "%s", WIFI_CLIENTPASSWORD);
/*if(!wifi_station_set_config(&stconfig))
{
#ifdef PLATFORM_DEBUG
os_printf("ESP8266 not set station config!\r\n");
#endif
}*/
}
I think this code runs over AP data with the default settings in WIFI_CLIENTSSID... is this some leftover debug stuff? some bug? intentional?
Now I'm facing another issue with wifi scan crashing...
BTW - the PUTC workaround works great. I can send clean data to the terminal (later on it will be Arduino). I just need to figure out how to read back data from the Arduino with some timeout (say - 1 sec max to not leave the connection hanging).
Nir