Commit da554a8b authored by 何锐's avatar 何锐

feat:更新版本号校验

parent 5f521800
...@@ -29,7 +29,6 @@ static uint32_t Protocol_UartRead1(uint8_t *pData, uint32_t len);//扫码枪 ...@@ -29,7 +29,6 @@ static uint32_t Protocol_UartRead1(uint8_t *pData, uint32_t len);//扫码枪
static uint32_t Protocol_UartRead2(uint8_t *pData, uint32_t len);//esp32 static uint32_t Protocol_UartRead2(uint8_t *pData, uint32_t len);//esp32
uint8_t nowdata[4]; uint8_t nowdata[4];
uint8_t lastdata[4]; uint8_t lastdata[4];
uint8_t checkresult;
uint8_t sendmsg[8]; uint8_t sendmsg[8];
uint8_t timenum = 0; uint8_t timenum = 0;
uint8_t firstflag = 0; uint8_t firstflag = 0;
......
...@@ -70,23 +70,37 @@ void Function_Check_Ctrl(uint32_t cmd); ...@@ -70,23 +70,37 @@ void Function_Check_Ctrl(uint32_t cmd);
void MENU_CHECK_STEP_ADD(void) void MENU_CHECK_STEP_ADD(void)
{ {
MENU_CHECK_STEP++; if(checkresult != 1) //版本号检验,如果取消版本号校验屏蔽此条
{
return ;
}
if(MENU_CHECK_STEP > 17) if(AutoCheck == 1) //光感校验,如果取消光感校验屏蔽此条(开发测试使用,正常自动判别在Display_Ctrl.c文件)
{ {
MENU_CHECK_STEP = 0; if((guangganflag != 3) && (MENU_CHECK_STEP == 3))
{
return ;
} }
if((guangganflag == 2 || guangganflag == 1 ) && guangganflag != 3) }
if((CurrentWrong == 1) && (MENU_CHECK_STEP == 13)) //静态电流检验,如果取消静态电流检验屏蔽此条
{ {
MENU_CHECK_STEP = 3; return ;
}
if(MENU_CHECK_STEP < 17) //循环
{
MENU_CHECK_STEP++;
}
else
{
MENU_CHECK_STEP = 0;
} }
} }
void MENU_CHECK_STEP_SUB(void) void MENU_CHECK_STEP_SUB(void)
{ {
if ( MENU_CHECK_STEP != 0 ); if ( MENU_CHECK_STEP != 0 );
MENU_CHECK_STEP--; MENU_CHECK_STEP--;
} }
void MENU_CHECK_Init(void) void MENU_CHECK_Init(void)
......
...@@ -49,6 +49,8 @@ enum DisplayFont ...@@ -49,6 +49,8 @@ enum DisplayFont
extern unsigned int Display_Menu_Type; extern unsigned int Display_Menu_Type;
extern uint32_t odo_val_Back ; extern uint32_t odo_val_Back ;
extern uint8_t AutoCheck;
extern uint8_t CurrentWrong;
void GeneralInfoDisp(unsigned char *p, unsigned short x, unsigned short y); void GeneralInfoDisp(unsigned char *p, unsigned short x, unsigned short y);
void Display_Title_Info(void); void Display_Title_Info(void);
void Display_Version_Info(uint32_t ON_OFF); void Display_Version_Info(uint32_t ON_OFF);
......
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