Saturday, November 12, 2016

Flashing NodeMCU and Espurino

Howdy!

This is going to be a quick one. When flashing NodeMCU with new firmware you need to remember that esptool.py requires some params for it to work correctly. And let's not forget the flash needs to be erased before we do anything.

esptool.py --port /dev/ttyUSB0 erase_flash
esptool.py --port /dev/ttyUSB0 write_flash -fm dio -fs 32m -ff 40m \
  0x000000 nodemcu-integer.bin \
  0x3fc000 esp_init_data_default.bin

Let me know if it works for you! Oh and btw - you can build the firmware online - I'm loving it!

With Espurino you do pretty much the same thing

esptool.py --port /dev/ttyUSB0 write_flash -fm dio -fs 32m -ff 40m \
  0x0000 "boot_v1.6.bin" \
  0x1000 espruino_esp8266_user1.bin \
  0x3FC000 esp_init_data_default.bin \
  0x3FE000 blank.bin

The original documentation for Espurino will tell you to use a higher frequency and the qio access method for the flash but I found that it just doesn't work on my D1 mini clone.

Happy flashing!

No comments: