5

I just bought an ESP32-C3-DevKitC-02 from Espressif, which features an onboard color LED. I'm a bit of a newbie in this space, so I thought I'd start by trying to get a simple "blink" program running. I've installed the Espressif VSCode extension, and I can successfully compile and load (flash) code. ...But the basic "blink" example doesn't blink the LED --- probably because the GPIO number is wrong. I did find a library for managing LEDs for this board, but it is generic and also accepts a GPIO as input, and running its sample code didn't work either. (Both the generic blink and the library samples specified GPIO 5 as the connection.)

Does anybody know what the right value is, or am I missing something else?

Damian
  • 103
  • 3
Denise Draper
  • 153
  • 1
  • 5
  • @jcaron --- thank you! Now that it is pointed out, I can see it printed on the board :-) – Denise Draper Jan 18 '22 at 15:25
  • I got it working (yay!). It turns out there is an example that works for this: it is called led_strip, and it is in the peripherals/rmt subdirectory, which made it hard to find. It just happens to be an led_strip of length (1). – Denise Draper Jan 19 '22 at 00:42

1 Answers1

5

As stated in the page you linked to :) and as stencilled directly on the board, it’s connected to GPIO8.

Note that it’s an “addressable” RGB LED, so samples which just toggle an output won’t work, it needs to use a library for addressable LEDs. I suppose this is a WS2812 or equivalent, also known as a Neopixel in the Adafruit world, but I haven’t checked further.

jcaron
  • 2,283
  • 4
  • 9