Same hardware setup as in the previous blog post.
And here is the source code:
![]() |
NodeMCU custom build options. |
ESP8266 -- DISP -- ESP8266 OPTION 1 OPTION 2 -------------------------- | ST7735B 1.8 TFT | | | GND -- | GND (1) | 3V3 -- | VCC (2) | | NC (3) | 3V3 -- | BL (4) (1) RST | -- GPIO16 (D0) | NC (5) (2) CS | -- GPIO15* (D8) GPIO16 (D0) -- | RST (6) TFT (3) D/C | -- GPIO02 (D4) GPIO02 (D4) -- | RS (7) TFT (4) DIN | -- GPIO13 (D7) GPIO13 (D7) -- | SDA (8) TFT (5) CLK | -- GPIO14 (D5) GPIO14 (D5) -- | SCK (9) TFT (6) VCC | -- 3V3 GPIO15* (D8) -- | CS (10)TFT (7) BL | -- 3V3 | CLK (11)SD (8) GND | -- GND | MISO (12)SD | | MOSI (13)SD | | CS (14)SD | | NC (16) | | NC (15) | -------------------------- *) pull-down 10k to GND
![]() |
ESP8266 NodeMCU dev board connected to 16pin interface of TFT |
![]() |
ESP8266 NodeMCU dev board connected to 8pin interface of TFT |
esptool.py --port port-of-esp8266 --baud 115200 read_flash 0x000 4194304 fw_backup.bin
esptool.py --port port-of-esp8266 --baud 115200 erase_flash
esptool.py --port port-of-esp8266 --baud 115200 write_flash 0x3fc000 esp_init_data_default.bin
esptool.py --port port-of-esp8266 --baud 115200 write_flash 0x0000 fw.bin
firmwareInfo()
to output information about the firmware. For the moment it just inform if it is a FLOAT or INTEGER versionBootTimeout
ms (to give the NodeMCU some time to initialize it self) init()
is calledinit()
the serial port is initialized and configured to watch for a transmitted ENTER keyabort()
is called, which set the abortFlag
to true.AbortTimeout
ms startup()
is called. There the abortFlag
is checked and the startup is canceled or executed by trying to load and execute 'user.lua'