전원 + BLE + 배터리
This commit is contained in:
@@ -0,0 +1,34 @@
|
||||
/*******************************************************************************
|
||||
* @file led_control.h
|
||||
* @brief LED direct control driver (Zephyr port)
|
||||
*
|
||||
* Green (P0.12) + Orange (P0.29) 2-color LED with k_timer based patterns
|
||||
******************************************************************************/
|
||||
#ifndef LED_CONTROL_H__
|
||||
#define LED_CONTROL_H__
|
||||
|
||||
#include <stdint.h>
|
||||
#include <stdbool.h>
|
||||
|
||||
/*==============================================================================
|
||||
* LED state enumeration
|
||||
*============================================================================*/
|
||||
typedef enum
|
||||
{
|
||||
LED_STATE_OFF = 0,
|
||||
LED_STATE_POWER_ON, /* 1: Green ON 2s -> stay on */
|
||||
LED_STATE_POWER_OFF, /* 2: Green ON 2s -> OFF */
|
||||
LED_STATE_ADVERTISING, /* 3: Green blink 500ms/500ms */
|
||||
LED_STATE_DETACH_WARNING, /* 4: Green 1s on / 3s off */
|
||||
LED_STATE_ALIGN_SEARCHING, /* 5: Orange blink 1s/1s */
|
||||
LED_STATE_ALIGN_COMPLETE, /* 6: Green 3s on / 1s off */
|
||||
LED_STATE_ERROR, /* 7: Orange 3Hz x3 / 1s off */
|
||||
LED_STATE_COUNT
|
||||
} led_state_t;
|
||||
|
||||
void led_init(void);
|
||||
void led_set_state(led_state_t state);
|
||||
led_state_t led_get_state(void);
|
||||
void led_ble_solid(void);
|
||||
|
||||
#endif /* LED_CONTROL_H__ */
|
||||
Reference in New Issue
Block a user