|
PebbleOS
|
Backlight driver interface. More...
Modules | |
| AW9364E | |
| Backlight implementation for the AW9364E LED driver. | |
| PWM backlight | |
| Backlight implementation driving the LED with a PWM output. | |
Functions | |
| void | backlight_init (void) |
| Initialize the backlight. | |
| void | backlight_set_brightness (uint8_t brightness) |
| Set the backlight brightness. | |
| uint8_t | backlight_get_level (uint8_t brightness) |
| Map a brightness to an opaque hardware level identifier. | |
| void | backlight_refresh (void) |
| Re-apply the cached driver state to the hardware. | |
| void | backlight_set_color (uint32_t rgb_color) |
| Set the backlight color. | |
| uint32_t | backlight_get_color (void) |
| Get the backlight color. | |
Backlight colors | |
Colors for backlight_set_color(), as 0xRRGGBB. Not gamma-corrected. | |
| #define | BACKLIGHT_COLOR_RED 0xFF0000 |
| Red. | |
| #define | BACKLIGHT_COLOR_GREEN 0x00FF00 |
| Green. | |
| #define | BACKLIGHT_COLOR_BLUE 0x0000FF |
| Blue. | |
| #define | BACKLIGHT_COLOR_BLACK 0x000000 |
| Black (off). | |
| #define | BACKLIGHT_COLOR_WHITE 0xFFFFFF |
| White. | |
| #define | BACKLIGHT_COLOR_WARM_WHITE 0xFFBFA2 |
| Warm white. | |
Backlight driver interface.
| #define BACKLIGHT_COLOR_BLACK 0x000000 |
Black (off).
| #define BACKLIGHT_COLOR_BLUE 0x0000FF |
Blue.
| #define BACKLIGHT_COLOR_GREEN 0x00FF00 |
Green.
| #define BACKLIGHT_COLOR_RED 0xFF0000 |
Red.
| #define BACKLIGHT_COLOR_WARM_WHITE 0xFFBFA2 |
Warm white.
| #define BACKLIGHT_COLOR_WHITE 0xFFFFFF |
White.
| uint32_t backlight_get_color | ( | void | ) |
Get the backlight color.
Only on boards with CONFIG_BACKLIGHT_HAS_COLOR.
| uint8_t backlight_get_level | ( | uint8_t | brightness | ) |
Map a brightness to an opaque hardware level identifier.
Two brightness values with the same identifier produce identical output, which lets callers collapse steps the hardware cannot distinguish. Drivers with continuous control return the input unchanged.
| brightness | Brightness from 0 to 100. |
| void backlight_init | ( | void | ) |
Initialize the backlight.
| void backlight_refresh | ( | void | ) |
Re-apply the cached driver state to the hardware.
A no-op if the driver believes the backlight is off.
| void backlight_set_brightness | ( | uint8_t | brightness | ) |
Set the backlight brightness.
| brightness | Brightness from 0 (off) to 100. |
| void backlight_set_color | ( | uint32_t | rgb_color | ) |
Set the backlight color.
Only on boards with CONFIG_BACKLIGHT_HAS_COLOR.
| rgb_color | Color as 0xRRGGBB, e.g. one of the BACKLIGHT_COLOR_* values. |