Commit 350ca82e authored by 时昊's avatar 时昊

feat:修改功率表显示

parent 1a7911c7
......@@ -311,13 +311,20 @@ void Gauge_Power_Display(void)
}
else//PTModeInd = 1,且有效时
{
//-1格和-50%
SEG_SET_PowerDial(1u, 0x81u, 1u, 50u);
if(BattCurr.Value > 50)
if(BattCurr.Value == 0)
{
SEG_SET_PowerDial(1u, 0u, 0u, 255u);
}
else
{
//-1 -2格和-100%
SEG_SET_PowerDial(1u, 0x82u, 1u, 100u);
//-1格和-50%
SEG_SET_PowerDial(1u, 0x81u, 1u, 50u);
if(BattCurr.Value > 50)
{
//-1 -2格和-100%
SEG_SET_PowerDial(1u, 0x82u, 1u, 100u);
}
}
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment