-->
Page 1 of 1

Init.lua doesn't change.

PostPosted: Mon Aug 10, 2015 6:20 pm
by Mondo90
Hello,

I noticed that init.lua once edited and flashed again apply only part of script changes. For example, ssid never changes in my case and still is "mywifi" the same with password. Fortunately baudrate changes but I am not sure other variables and since something doesnt work as it should this bug makes it very very hard to debug !

I use ESP-01 moudle and installed all folowing this tut -> http://www.roboremo.com/esp8266-tcp-to-serial.html

What's wrong ?

Re: Init.lua doesn't change.

PostPosted: Wed Aug 12, 2015 11:54 am
by devsaurus
Mondo90 wrote:I noticed that init.lua once edited and flashed again apply only part of script changes. For example, ssid never changes in my case and still is "mywifi" the same with password.


You don't need to run the WIFI configuration each time. The ESP8266 stores the settings in flash and will recall them after boot. Thus I'd propose you remove these commands from init.lua and apply them semi-manually when you need to change the configuration (or after flashing the firmware).

Start with downloading the firmware again together with blank.bin and esp_init_data_default.bin (INTERNAL://BLANK and INTERNAL://DEFAULT for the nodemcu flash utility). Then execute the configuration commands and see how your init.lua script behaves now.
I'd also recommend to increase the delay in your init.lua to >1 s in case you need to delete it due to bugs.