![]() |
cueOS
2.4
cueOS - Universal Show Control OS for ARM
|

Data Structures | |
| struct | led_driver_led_s |
| Defines a driver's LED instance. More... | |
| struct | led_driver_s |
| Defines the leds driver instance. More... | |
Macros | |
| #define | LED_DRIVER_COUNT 3 |
| #define | LED_DRIVER_PORT GPIOD |
| #define | LED_DRIVER_BLINK_RATE 250 |
| #define | LED_DRIVER_DEFAULT {{}, LED_DRIVER_UNINITIALISED} |
| leds driver instance default values More... | |
Enumerations | |
| enum | led_driver_status_e { LED_DRIVER_UNINITIALISED , LED_DRIVER_INITIALISED } |
| Status of the leds driver instance. More... | |
| enum | led_driver_led_state_e { LED_OFF , LED_ON , LED_BLINK } |
| defines the running mode of one of the driver's LED instance More... | |
| enum | led_driver_pin_e { LED_STATE_PIN = GPIO_PIN_12 , LED_ERROR_PIN = GPIO_PIN_14 , LED_NETWORK_PIN = GPIO_PIN_15 } |
| defines the driver's LED pin numbers More... | |
| enum | led_driver_led_e { LED_STATE , LED_ERROR , LED_NETWORK } |
| defines index of the driver's LED to be used to select a specific led from the driver's led pool More... | |
Functions | |
| void | leds_driver_init (void) |
| LED Driver initialisation. More... | |
| void | leds_driver_set (led_driver_led_e led, led_driver_led_state_e state) |
| Assigns a state to a driver's led. More... | |
Abstraction layer for system LEDs
| #define LED_DRIVER_BLINK_RATE 250 |
Blink rate of a driver LED in ms
Definition at line 15 of file leds_driver.h.
| #define LED_DRIVER_COUNT 3 |
the amount of leds supported by the driver
Definition at line 13 of file leds_driver.h.
| #define LED_DRIVER_DEFAULT {{}, LED_DRIVER_UNINITIALISED} |
leds driver instance default values
Used during initialisation of a leds driver instance, it lowers the risk of conflicts by ensuring that every parameters which will be set are correctly initialised.
Definition at line 23 of file leds_driver.h.
| #define LED_DRIVER_PORT GPIOD |
GPIO port over which these LEDs should be controlled
Definition at line 14 of file leds_driver.h.
| enum led_driver_led_e |
defines index of the driver's LED to be used to select a specific led from the driver's led pool
| Enumerator | |
|---|---|
| LED_STATE | Index of the driver's "STATE" LED |
| LED_ERROR | Index of the driver's "ERROR" LED |
| LED_NETWORK | Index of the driver's "NETWORK" LED |
Definition at line 58 of file leds_driver.h.
defines the running mode of one of the driver's LED instance
| Enumerator | |
|---|---|
| LED_OFF | Sets an LED in OFF mode |
| LED_ON | Sets an LED in ON mode |
| LED_BLINK | Sets an LED in blink mode |
Definition at line 39 of file leds_driver.h.
| enum led_driver_pin_e |
defines the driver's LED pin numbers
| Enumerator | |
|---|---|
| LED_STATE_PIN | Pin number of the driver's "STATE" LED |
| LED_ERROR_PIN | Pin number of the driver's "ERROR" LED |
| LED_NETWORK_PIN | Pin number of the driver's "NETWORK" LED |
Definition at line 48 of file leds_driver.h.
| enum led_driver_status_e |
Status of the leds driver instance.
Defines whether or not the leds driver instance has been correctly initialised.
| Enumerator | |
|---|---|
| LED_DRIVER_UNINITIALISED | The driver is initialised |
| LED_DRIVER_INITIALISED | The driver is uninitialised |
Definition at line 31 of file leds_driver.h.
| void leds_driver_init | ( | void | ) |
LED Driver initialisation.
Definition at line 87 of file leds_driver.c.
| void leds_driver_set | ( | led_driver_led_e | led, |
| led_driver_led_state_e | state | ||
| ) |
Assigns a state to a driver's led.
| led | the led which state is to be set |
| state | the selected state |
Definition at line 110 of file leds_driver.c.