rgb_led
rgb_led is a simple component for ESP32 to control RGB LEDs.
Colors
- White
- Yellow
- Purple
- Red
- Cyan
- Green
- Blue
- Black
These are addressed as rgb_[color], for example rgb_white.
Example usage
Create an LED variable, say MY_LED.
rgb_led MY_LED;
Initialize it with each corresponding pin.
rgb_init_LED(&MY_LED, red_pin, green_pin, blue_pin);
And one can then set the color of the LED.
rgb_set_color(&MY_LED, rgb_purple);
