Testing a RGB LED on NuttX with brightness control

In my previous post I explained how to control a RGB LED on NuttX, but at that time it doesn’t have brightness control.

Now I created a new driver that uses three PWM pins to control the LED intensive.

I posted the driver in the NuttX mailing list and Greg incorporated it on NuttX mainline (drivers/leds/rgbled.c).

A video worth more than 1 millions of words:

You can reproduce it just connection a RGB LED to STM32F4Discovery this way: Red pin connected to PE9, Green pin connected to PA1 and Blue pin connected to PB0 and compile NuttX with these commands:

$ cd nuttx
$ cd tools
$ ./configure.sh stm32f4discovery/rgbled
$ cd ..
$ make

Just write the nuttx.bin in your board and the LED fading will start after reset.