rgbled: added LED_MODE_RGB to allow for constant RGB values

this allows apps to fully control the 3 LED elements
This commit is contained in:
Andrew Tridgell
2013-08-14 15:02:15 +02:00
committed by Lorenz Meier
parent e14d034528
commit 21a919d973
2 changed files with 56 additions and 6 deletions
+14
View File
@@ -65,3 +65,17 @@
* The script is terminated by a zero command.
*/
#define RGBLED_SET_USER_SCRIPT _RGBLEDIOC(3)
/** set constant RGB values */
#define RGBLED_SET _RGBLEDIOC(4)
/*
structure passed to RGBLED_SET ioctl()
Note that the driver scales the brightness to 0 to 255, regardless
of the hardware scaling
*/
struct RGBLEDSet {
uint8_t red;
uint8_t green;
uint8_t blue;
};