|
ONLP
Open Network Linux Platform APIs
|
Data Structures | |
| struct | onlp_led_info_s |
Macros | |
| #define | ONLP_LED_CAPS_VALID(_e) (onlp_led_caps_valid((_e))) |
| #define | ONLP_LED_MODE_STRINGS |
| #define | ONLP_LED_MODE_VALID(_e) ( (0 <= (_e)) && ((_e) <= ONLP_LED_MODE_PURPLE_BLINKING)) |
Typedefs | |
| typedef enum onlp_led_caps_e | onlp_led_caps_t |
| typedef enum onlp_led_mode_e | onlp_led_mode_t |
| typedef struct onlp_led_info_s | onlp_led_info_t |
Enumerations | |
| enum | onlp_led_caps_e { ONLP_LED_CAPS_OFF = (1 << 0), ONLP_LED_CAPS_AUTO = (1 << 1), ONLP_LED_CAPS_AUTO_BLINKING = (1 << 2), ONLP_LED_CAPS_CHAR = (1 << 3), ONLP_LED_CAPS_RED = (1 << 4), ONLP_LED_CAPS_RED_BLINKING = (1 << 5), ONLP_LED_CAPS_ORANGE = (1 << 6), ONLP_LED_CAPS_ORANGE_BLINKING = (1 << 7), ONLP_LED_CAPS_YELLOW = (1 << 8), ONLP_LED_CAPS_YELLOW_BLINKING = (1 << 9), ONLP_LED_CAPS_GREEN = (1 << 10), ONLP_LED_CAPS_GREEN_BLINKING = (1 << 11), ONLP_LED_CAPS_BLUE = (1 << 12), ONLP_LED_CAPS_BLUE_BLINKING = (1 << 13), ONLP_LED_CAPS_PURPLE = (1 << 14), ONLP_LED_CAPS_PURPLE_BLINKING = (1 << 15) } |
| enum | onlp_led_mode_e { ONLP_LED_MODE_OFF, ONLP_LED_MODE_AUTO, ONLP_LED_MODE_AUTO_BLINKING, ONLP_LED_MODE_CHAR, ONLP_LED_MODE_RED, ONLP_LED_MODE_RED_BLINKING, ONLP_LED_MODE_ORANGE, ONLP_LED_MODE_ORANGE_BLINKING, ONLP_LED_MODE_YELLOW, ONLP_LED_MODE_YELLOW_BLINKING, ONLP_LED_MODE_GREEN, ONLP_LED_MODE_GREEN_BLINKING, ONLP_LED_MODE_BLUE, ONLP_LED_MODE_BLUE_BLINKING, ONLP_LED_MODE_PURPLE, ONLP_LED_MODE_PURPLE_BLINKING, ONLP_LED_MODE_LAST = ONLP_LED_MODE_PURPLE_BLINKING, ONLP_LED_MODE_COUNT, ONLP_LED_MODE_INVALID = -1 } |
Functions | |
| int | onlp_led_sw_init (void) |
| Software initialization of the LED module. | |
| int | onlp_led_hw_init (uint32_t flags) |
| Hardware initialization of the LED module. | |
| int | onlp_led_sw_denit (void) |
| Deinitialize the led software module. More... | |
| int | onlp_led_hdr_get (onlp_oid_t oid, onlp_oid_hdr_t *rv) |
| Get the LED header. More... | |
| int | onlp_led_info_get (onlp_oid_t oid, onlp_led_info_t *rv) |
| Get LED information. More... | |
| int | onlp_led_caps_get (onlp_oid_t oid, uint32_t *caps) |
| Get the LED caps. More... | |
| int | onlp_led_mode_set (onlp_oid_t oid, onlp_led_mode_t mode) |
| Set the LED mode. More... | |
| int | onlp_led_char_set (onlp_oid_t oid, char c) |
| Set the LED char. More... | |
| int | onlp_led_info_to_user_json (onlp_led_info_t *info, cJSON **cj, uint32_t flags) |
| Convert an LED info structure to user JSON. More... | |
| int | onlp_led_info_to_json (onlp_led_info_t *info, cJSON **cj, uint32_t flags) |
| Convert an LED info structure to JSON. More... | |
| int | onlp_led_info_from_json (cJSON *cj, onlp_led_info_t *info) |
| Convert a JSON object to an LED info structure. More... | |
| const char * | onlp_led_caps_name (onlp_led_caps_t e) |
| int | onlp_led_caps_value (const char *str, onlp_led_caps_t *e, int substr) |
| const char * | onlp_led_caps_desc (onlp_led_caps_t e) |
| int | onlp_led_caps_valid (onlp_led_caps_t e) |
| const char * | onlp_led_mode_name (onlp_led_mode_t e) |
| int | onlp_led_mode_value (const char *str, onlp_led_mode_t *e, int substr) |
| const char * | onlp_led_mode_desc (onlp_led_mode_t e) |
Variables | |
| aim_map_si_t | onlp_led_caps_map [] |
| aim_map_si_t | onlp_led_caps_desc_map [] |
| aim_map_si_t | onlp_led_mode_map [] |
| aim_map_si_t | onlp_led_mode_desc_map [] |
| #define ONLP_LED_CAPS_VALID | ( | _e | ) | (onlp_led_caps_valid((_e))) |
validator
| #define ONLP_LED_MODE_STRINGS |
Strings macro.
| #define ONLP_LED_MODE_VALID | ( | _e | ) | ( (0 <= (_e)) && ((_e) <= ONLP_LED_MODE_PURPLE_BLINKING)) |
validator
| typedef enum onlp_led_caps_e onlp_led_caps_t |
onlp_led_caps
| typedef struct onlp_led_info_s onlp_led_info_t |
LED information structure.
| typedef enum onlp_led_mode_e onlp_led_mode_t |
onlp_led_mode
| enum onlp_led_caps_e |
onlp_led_caps
| enum onlp_led_mode_e |
onlp_led_mode
| const char* onlp_led_caps_desc | ( | onlp_led_caps_t | e | ) |
Enum descriptions.
| int onlp_led_caps_get | ( | onlp_oid_t | oid, |
| uint32_t * | caps | ||
| ) |
Get the LED caps.
| oid | The LED OID. | |
| [out] | caps | Receives the caps. |
| const char* onlp_led_caps_name | ( | onlp_led_caps_t | e | ) |
Enum names.
| int onlp_led_caps_valid | ( | onlp_led_caps_t | e | ) |
Enum validator.
| int onlp_led_caps_value | ( | const char * | str, |
| onlp_led_caps_t * | e, | ||
| int | substr | ||
| ) |
Enum values.
| int onlp_led_char_set | ( | onlp_oid_t | oid, |
| char | c | ||
| ) |
Set the LED char.
| oid | The LED OID |
| c | The character. |
| int onlp_led_hdr_get | ( | onlp_oid_t | oid, |
| onlp_oid_hdr_t * | rv | ||
| ) |
Get the LED header.
| oid | The LED OID | |
| [out] | rv | Receives the header. |
| int onlp_led_info_from_json | ( | cJSON * | cj, |
| onlp_led_info_t * | info | ||
| ) |
Convert a JSON object to an LED info structure.
| cj | The JSON oibject. | |
| [out] | info | Receives the LED info structure. |
| int onlp_led_info_get | ( | onlp_oid_t | oid, |
| onlp_led_info_t * | rv | ||
| ) |
Get LED information.
| oid | The LED OID. | |
| [out] | rv | Receives the information structure. |
| int onlp_led_info_to_json | ( | onlp_led_info_t * | info, |
| cJSON ** | cj, | ||
| uint32_t | flags | ||
| ) |
Convert an LED info structure to JSON.
| info | The LED info structure. | |
| [out] | cj | Receives the JSON object. |
| flags | The JSON format flags. |
| int onlp_led_info_to_user_json | ( | onlp_led_info_t * | info, |
| cJSON ** | cj, | ||
| uint32_t | flags | ||
| ) |
Convert an LED info structure to user JSON.
| info | The LED info structure. | |
| [out] | cj | Receives the JSON object. |
| flags | The JSON format flags. |
| const char* onlp_led_mode_desc | ( | onlp_led_mode_t | e | ) |
Enum descriptions.
| const char* onlp_led_mode_name | ( | onlp_led_mode_t | e | ) |
Enum names.
| int onlp_led_mode_set | ( | onlp_oid_t | oid, |
| onlp_led_mode_t | mode | ||
| ) |
Set the LED mode.
| oid | The LED OID. |
| mode | The mode. . |
| int onlp_led_mode_value | ( | const char * | str, |
| onlp_led_mode_t * | e, | ||
| int | substr | ||
| ) |
Enum values.
| int onlp_led_sw_denit | ( | void | ) |
Deinitialize the led software module.
| aim_map_si_t onlp_led_caps_desc_map[] |
onlp_led_caps_desc_map table.
| aim_map_si_t onlp_led_caps_map[] |
onlp_led_caps_map table.
| aim_map_si_t onlp_led_mode_desc_map[] |
onlp_led_mode_desc_map table.
| aim_map_si_t onlp_led_mode_map[] |
onlp_led_mode_map table.
1.8.13