Blink example printf works but ED not flashing

bunfight
Posts: 14
Joined: Mon Mar 08, 2021 5:33 pm

Blink example printf works but ED not flashing

Postby bunfight » Tue Mar 09, 2021 10:57 am

I had VSCode installed on Ubuntu 18.04.
Then instaled ESP-IDF.
Then installed ESP-IDF into VSCode.

Connected a ESP32-WROOM-32D NodeMCU-ESP32 DEVKITV1 via USB.

Blue LED flashes.

Built & flashed blink.c example. This flashed successfully but blue LED is off and red LED is on continuously.

ESP-IDF Monitor displays:

Turning off the LED
Turning on the LED
Turning off the LED
Turning on the LED
Turning off the LED
....

I changed vTaskDelay in blink.c which verified that the program running is the one just built and flashed as the delay between displays of Turning off the LED, Turning on the LED correspond to those set in blink.c.

However the blue LED is off and red LED is on continuously. I have unplugged the USB, pressed BOOT, EN, BOOT+EN during power-up or whilst powered up but this has no effect.

Any ideas as to why the blue LED is off and red LED is on continuously?

ESP_Sprite
Posts: 9708
Joined: Thu Nov 26, 2015 4:08 am

Re: Blink example printf works but ED not flashing

Postby ESP_Sprite » Wed Mar 10, 2021 7:55 am

What devboard are you using? Are you sure the GPIO the blink example is using is connected to one of those LEDs?

bunfight
Posts: 14
Joined: Mon Mar 08, 2021 5:33 pm

Re: Blink example printf works but LED not flashing

Postby bunfight » Wed Mar 10, 2021 8:24 am

Thanks.

I Connected a ESP32-WROOM-32D NodeMCU-ESP32 DEVKITV1 via USB.

I will run a test to identify each physical pin on the board. It may well be the case that the pin layout is an issue.

bunfight
Posts: 14
Joined: Mon Mar 08, 2021 5:33 pm

Re: Blink example printf works but LED not flashing

Postby bunfight » Thu Mar 11, 2021 10:12 am

I tried all 30 pins on board excepting 0, 8 - 12. Either Monitor displayed continuous error/warning messages without program output, or program ran as described previously, with the blue LED not illuminating or flashing.

I have ordered some genuine Expressif ESP32-DevKitC-32D & CE boards to use instead.

I will be experimenting with the OTA update example in the VSCode_ESP-IDF setup. Is there a procedure to reset a board to a "just shipped from factory " state to completely restore the board to functioning normally?

Thanks.

ESP_Sprite
Posts: 9708
Joined: Thu Nov 26, 2015 4:08 am

Re: Blink example printf works but ED not flashing

Postby ESP_Sprite » Fri Mar 12, 2021 1:34 am

Are you sure that the blue LED is connected to a GPIO at all, and not e.g. a simple power LED directly connected to the power supply?

Not sure what the Visual Studio equivalent would be, but command line you could do an 'idf.py erase_flash' which nukes all remnants of earlier programs from flash. Although there are exceptions, you generally do not need to do this, though.

bunfight
Posts: 14
Joined: Mon Mar 08, 2021 5:33 pm

Re: Blink example printf works but ED not flashing

Postby bunfight » Fri Mar 12, 2021 5:22 pm

Thanks.

When the board was removed from the packet and plugged into the USB socket, the blue light flashed. From the first flash upload onwards it did not flash, whichever pin was used with blink.c.

gparvind
Posts: 3
Joined: Mon Jul 27, 2020 7:48 am

Re: Blink example printf works but ED not flashing

Postby gparvind » Fri Dec 10, 2021 6:37 am

Is this solved? I face the same problem. LED using GPIO doesn't work but it works with RMT for addressable LED.

Who is online

Users browsing this forum: No registered users and 35 guests