-->
Page 1 of 1

Compiling code

PostPosted: Thu Apr 02, 2020 5:27 am
by MrHause
Hi !
I'm developing different ways to code ESP8266 and compare them. I'm stucked in understanding LUA and I have few question which allow me write article and end the study project. I read documentation LUA Faq and other what I got really lost and can't understand anything. I will be very grateful for any help. So I develop some simply script with ESPlorer. I send them to board as init.lua. Here are my hard thoughts:
1. Is the code somehow check for errors during flashing? Sometimes I get some error and sometimes just board restart.
2. The code send via ESPlorer as init.lua is stored in SPIFFS?
3. What are the advantages of compilation using node.compile()? I only know that I get a .lc file and it takes additional space in the memory.
4. Maybe after compilation init.lua ang get init.lc file is that .lc file executed?
5. Is it required to do compilation if the code works?
6. I know that user can do compilation on PC and get luac.cross and then get LFSimage. What are the advantages of that approach in comparison to node.compile()? I only know that node.compile() use the board RAM to do it. But what after? Is it stored in flash memory and it's somehow better or what?