LED driver for an LED on a GPIO.
More...
LED driver for an LED on a GPIO.
The LED is on at any brightness but 0, whatever the color, and off when it comes up.
◆ pbl_led_gpio
| Data Fields |
|
struct pbl_gpio |
gpio |
GPIO, active when the LED is on. |
|
struct pbl_led |
led |
LED. |
◆ PBL_LED_GPIO_DEFINE
| #define PBL_LED_GPIO_DEFINE |
( |
|
sym, |
|
|
|
_name, |
|
|
|
_gpio |
|
) |
| |
Value:
.led =
PBL_LED_INIT(sym, _name, pbl_led_gpio_init,
nullptr, &pbl_led_gpio_ops), .gpio = _gpio, \
}
#define PBL_DEVICE_STATE_DEFINE(sym)
Define the runtime state of device instance sym.
Definition device.h:132
LED on a GPIO.
Definition gpio.h:19
#define PBL_LED_INIT(sym, _name, _init, _parent, _ops)
Initialize a struct pbl_led.
Definition led.h:57
Define an LED on a GPIO.
- Parameters
-
| sym | Symbol of the LED. |
| _name | Name. |
| _gpio | GPIO, from PBL_GPIO(). |