-->
Page 1 of 3

Can flash but can't run blink. Tried a power adapter. Ideas?

PostPosted: Wed Feb 17, 2016 1:36 pm
by OnlineDishwasher
Hi,

I bought a Chinese NodeMCU and would like to use it with the Arduino IDE/language. I tried to flash the hello-world/led blink sketch as a test.

I believe it flashed correctly because the IDE writes to the flash (I think, it shows a series of `.` and no error message) but when I reset the ESP, nothing happens. I tried connecting it to an actual power supply because I read it could be the cause but still no dice, the LED doesn't blink.

I checked it's the right pin too.

So it would seem it can flash but won't run the sketch. What am I missing? Could it be that I chose the wrong USD adapter in the settings or the wrong board? Wouldn't a mistake there prevent any flashing at all?

Does the ESP need a special firmware to run Arduino sketches or is it the IDE translating the Arduino language to pure C that the ESP can run directly?

Re: Can flash but can't run blink. Tried a power adapter. Id

PostPosted: Wed Feb 17, 2016 2:04 pm
by krzychb
Hi OnlineDishwasher,

What particular NodeMCU board you have? Please post a picture or schematic.
Post your upload settings and upload log for the Blink.ino sketch.
How do you know that right LED pin is selected in the sketch?
If I load my NodeMCU board using default Blink.ino sketch, the LED is not blinking unless I change the pin.

Krzysztof

Re: Can flash but can't run blink. Tried a power adapter. Id

PostPosted: Wed Feb 17, 2016 2:09 pm
by martinayotte
How your wiring looks like ? What kind of power supply and voltage regulator ?
In ArduinoIDE, did you selected the proper NodeMCU in the board settings ?

Re: Can flash but can't run blink. Tried a power adapter. Id

PostPosted: Wed Feb 17, 2016 5:49 pm
by OnlineDishwasher
This is the board I bought: http://www.aliexpress.com/item/V2-4M-4F ... 62166.html

And this si the programmer I use: http://www.aliexpress.com/item/J34-Free ... 62466.html

I used the USB cable to power the board and I also tried my Nexus 5's charger.

The pin number I use in the Blink sketch is the same as the one that worked for the blink.js script using Smart.js. The LED is built into the board, next to the antenna.

My settings: Image

edit:

This is the code:
Code: Select allvoid setup() {
  pinMode(0, OUTPUT);
}
 
void loop() {
  digitalWrite(0, HIGH);
  delay(500);
  digitalWrite(0, LOW);
  delay(500);
}