This commit is contained in:
dgjames 2025-01-18 12:50:27 +08:00
parent 6a594d6cdc
commit a55ef6efcc

View File

@ -26,15 +26,15 @@ const RGBColor_TypeDef LED_ON = {255, 255, 255};
void LED_BreathTurn(uint8_t LedBreath_state)
{
LED_Breath_State = LedBreath_state;
if (LedBreath_state == LED_BREATH_OFF)
{
// rt_thread_suspend(led_breath_thread);
LED_SetMore(LED_BREATH_ID(1), LED_BREATH_ID(12), LED_OFF);
}
else if (LedBreath_state == LED_BREATH_ON)
{
// rt_thread_resume(led_breath_thread);
}
// if (LedBreath_state == LED_BREATH_OFF)
// {
// // rt_thread_suspend(led_breath_thread);
// LED_SetMore(LED_BREATH_ID(1), LED_BREATH_ID(12), LED_OFF);
// }
// else if (LedBreath_state == LED_BREATH_ON)
// {
// // rt_thread_resume(led_breath_thread);
// }
}
/**
* @brief LED的颜色或开关
@ -154,7 +154,7 @@ void led_breath_entry(void *parameter)
break;
}
RGB_Reflash();
rt_thread_mdelay(500);
rt_thread_delay(40);
}
count = (count + 1) % 3;
}
@ -187,7 +187,7 @@ static int borad_check(void)
/* 转换为对应电压值 */
vol = value * REFER_VOLTAGE / CONVERT_BITS;
if(vol>=0.25)
if(vol>=0.25*100)
{
rt_kprintf("NOT correct borad!\n");
rt_kprintf("the value is :%d \n", value);