Commit 50993e08 authored by hu's avatar hu

修改水温上升一个BUG

parent 68bcac1a
......@@ -83,9 +83,9 @@ void Coolant_Processing_Service(void)
if (CanStatus == CAN_SIG_LOST)
{
CoolantVariable.Valid = 0 ;
CoolantVariable.Valid = 0u;
CoolantVariable.Value = 0u;
Timer2s = 0 ;
Timer2s = 0u;
}
else
{
......@@ -94,6 +94,7 @@ void Coolant_Processing_Service(void)
if (Msg_CoolTemp > 0xFAu)
{
CoolantVariable.Valid = 0u ;
CoolantVariable.Value = 0u;
TargetSeg = 0u;
}
else
......@@ -115,17 +116,17 @@ void Coolant_Processing_Service(void)
TempCurSeg = CalCoolant_CurSeg(CoolantVariable.Valid, CoolantVariable.Value);
if (
(GetGaugesDirec(TempGauges) == 1) &&
(TempCurSeg == DestPostion[TempGauges] / 10)
(GetGaugesDirec(TempGauges) == 1u) &&
(TempCurSeg == DestPostion[TempGauges] / 10u)
)
{
if (DestPostionOld != DestPostion[TempGauges] / 10)
if (DestPostionOld != DestPostion[TempGauges] / 10u)
{
DestPostionOld = DestPostion[TempGauges] / 10;
TempCurSegTime = 0;
DestPostionOld = DestPostion[TempGauges] / 10u;
TempCurSegTime = 0u;
}
if (TempCurSegTime < 200)
if (TempCurSegTime < 200u)
{
TempCurSegTime ++;
}
......@@ -136,7 +137,7 @@ void Coolant_Processing_Service(void)
}
else
{
TempCurSegTime = 0;
TempCurSegTime = 0u;
CoolantVariable.CurSeg = TempCurSeg;
}
}
......
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