This example demonstrates how to blink the WS2812 LED using the led_strip component.
Before project configuration and build, be sure to set the correct chip target using idf.py set-target <chip_name>. Then assign the proper GPIO in the source file. If your led strip has multiple LEDs, don't forget update the number.
Run idf.py -p PORT build flash monitor to build, flash and monitor the project.
(To exit the serial monitor, type Ctrl-].)
See the Getting Started Guide for full steps to configure and use ESP-IDF to build projects.
Text
I (299) gpio: GPIO[14]| InputEn: 0| OutputEn: 1| OpenDrain: 0| Pullup: 1| Pulldown: 0| Intr:0
I (309) example: Created LED strip object with SPI backend
I (309) example: Start blinking LED strip
To create a project from this example, run:
idf.py create-project-from-example "espressif/led_strip=2.5.5:led_strip_spi_ws2812"