The blink script for the ESP8266 now looks like this
var on = false;
let LED1 = NodeMCU.D4;
on = !on;
for anyone that needs it.
this successfully will blink any LED on D4 and of course all 8266 seem to have a little light on the board that will also blink this (so nothing but your board is needed)
The Espruino IDE is of course set to the suggest 115200 baud and I'm connecting to what ever the connection is for the device.
COM10 in my case for windows /dev/ttyUSB0 on my linux and I cannot remember which port is the one on my mac but it was the one that DIDN'T start with /dev/tty.*
The designers of NodeMCU decided (for whatever reason) to come with new pin naming, and don't use the ESP8266 pin names.
For example NodeMCU.D4 is GPIO2 on the ESP8266.
And Wemos is using the same pin numbering. Pretty annoying IMO.
The ESP8266 is pretty sensitive to power supply: voltage drops on a longer or thinner (thinner copper conductor) cable, or not enough decoupling on the board can cause all kinds of issues like brownout resets and crashes.
I added a 100uF cap to the 5V rail of the boards that behaved erratically, and they are fine now.
© Espruino, powered by microcosm.
Report a problem