feat: 完成弹力魔盒初版固件
This commit is contained in:
+12
-1
@@ -124,6 +124,16 @@ void app_led_request_ota(void)
|
||||
LED_EventAdd(LED_EVENT_OTA);
|
||||
}
|
||||
|
||||
void app_led_exit_ota(void)
|
||||
{
|
||||
if (!s_initialized || !s_ota) {
|
||||
return;
|
||||
}
|
||||
s_ota = 0;
|
||||
LED_EventDelete(LED_EVENT_OTA);
|
||||
bsp_led_all_off();
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief 查询是否处于 OTA 灯效
|
||||
* @return 1=OTA 灯效中,0=否
|
||||
@@ -230,7 +240,8 @@ void app_led_run(uint16_t dt, uint8_t app_power)
|
||||
charge_led = app_power_charge_led();
|
||||
low_bat = app_power_low_bat();
|
||||
func_on = app_power ? 1 : 0;
|
||||
pairing = (uint8_t)(app_pair_is_active() && func_on);
|
||||
pairing = (uint8_t)(app_pair_is_active() && func_on
|
||||
&& !app_power_usb_online());
|
||||
|
||||
/* 充电红 / 充满绿:和功能开关无关,关着设备也可能在充电 */
|
||||
if (charge_led == 1) {
|
||||
|
||||
Reference in New Issue
Block a user