管壳码全0判断
This commit is contained in:
@@ -159,20 +159,20 @@ uint8_t coder_judge(const uint8_t *data)
|
||||
}
|
||||
|
||||
// 检测电流
|
||||
TASK_FIND_NEXT(4);
|
||||
TASK_FIND_NEXT(3);
|
||||
temp=TASK_DATA(0);
|
||||
temp2=TASK_DATA(1);
|
||||
if((temp<10)&&(temp2<10))
|
||||
if((temp<100)&&(temp2<100))
|
||||
{
|
||||
// 接触异常
|
||||
return 3;
|
||||
}
|
||||
else if(((temp>task->range[0].max)&&(temp<1500))||
|
||||
((temp2>task->range[0].max)&&(temp2<1500)))
|
||||
else if(((temp>task->range[0].max)&&(temp<800))||
|
||||
((temp2>task->range[0].max)&&(temp2<800)))
|
||||
{
|
||||
// 过流
|
||||
return 7;
|
||||
}else if((temp>1500)&&(temp2>1500))
|
||||
}else if((temp>800)&&(temp2>800))
|
||||
{
|
||||
// 短路
|
||||
return 8;
|
||||
@@ -180,7 +180,7 @@ uint8_t coder_judge(const uint8_t *data)
|
||||
|
||||
|
||||
// 检测uid
|
||||
TASK_FIND_NEXT(5);
|
||||
TASK_FIND_NEXT(4);
|
||||
if(get_ack(data,task->taskindex))
|
||||
{
|
||||
// 芯片错误
|
||||
@@ -188,7 +188,7 @@ uint8_t coder_judge(const uint8_t *data)
|
||||
}
|
||||
|
||||
// 检测桥丝
|
||||
TASK_FIND_NEXT(6);
|
||||
TASK_FIND_NEXT(11);
|
||||
temp=TASK_DATA(0);
|
||||
if((temp<task->range[0].min)||(temp>task->range[0].max))
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user