-->
Page 1 of 1

.lua are deleted when trying to copy nodemcu to other ESP

PostPosted: Thu May 17, 2018 1:48 pm
by jvune
Hi!
I'm trying to make a full flash dump of ESP8266 running nodemcu (with some .lua files) to make a copy of it. I'm using esptool.py for a dump. Like this: esptool.py.exe -p COM3 -b 230400 read_flash 0 0x200000 test.bin

When I look inside test.bin, I can see my lua code. So, those files are definitely there. But, when I upload this .bin to another ESP , nodemcu starts filesystem format procedure. Therefore, all .lua files are deleted. NodeMCU build itself seems to be fine.

Why does this happen if I make a full dump of the flash? Is there a register flag or something what defines that nodemcu should format filesystem? How can I copy ESP keeping all .lua files in place?

Re: .lua are deleted when trying to copy nodemcu to other ES

PostPosted: Fri May 18, 2018 11:52 am
by jvune
Ok, I found a reason.
Seems like NodeMcu was missing init data on 0x3fc000.
So, the best way to solve an issue was to make a complete memory dump.
esptool.py.exe -p COM3 -b 230400 read_flash 0 0x400000 test.bin in my case.