This is my module saver program. It works now and can be used to save modules stored on a webserver onto esp8266 flash memory. Start the program and then key in on the left side:
s.save('MyModule');
I had to find out the size of the module. It was stored in the header of the received code.
then it needs to specify the total module size for each chunk to be written to the flash:
this.st.write(name, data, offset, sz);
Altough some times i get an error which might be from a buffer overrun in the http.get module.
Espruino is a JavaScript interpreter for low-power Microcontrollers. This site is both a support community for Espruino and a place to share what you are working on.
This is my module saver program. It works now and can be used to save modules stored on a webserver onto esp8266 flash memory. Start the program and then key in on the left side:
s.save('MyModule');
I had to find out the size of the module. It was stored in the header of the received code.
then it needs to specify the total module size for each chunk to be written to the flash:
Altough some times i get an error which might be from a buffer overrun in the http.get module.