Commit bbe17e7f authored by 何锐's avatar 何锐

feat:针对差异部分二合一

parent 43dca105
...@@ -4664,6 +4664,7 @@ uint8_t SlopeDescentflaglast; ...@@ -4664,6 +4664,7 @@ uint8_t SlopeDescentflaglast;
uint8_t RampParkflaglast; uint8_t RampParkflaglast;
uint8_t Autoheadlightflaglast; uint8_t Autoheadlightflaglast;
uint8_t jiaoyan = 0; uint8_t jiaoyan = 0;
uint8_t up_key_press_number;
void Display_Version_Info(uint32_t ON_OFF) void Display_Version_Info(uint32_t ON_OFF)
{ {
uint8_t pbuff [ 40 ]; uint8_t pbuff [ 40 ];
...@@ -4822,12 +4823,16 @@ void Display_Version_Info(uint32_t ON_OFF) ...@@ -4822,12 +4823,16 @@ void Display_Version_Info(uint32_t ON_OFF)
nowpuran = 14; nowpuran = 14;
now7926 = 14; now7926 = 14;
now7106 = 37; now7106 = 37;
up_key_press_number = 1;
} }
else if((wuliao[12] == 0x33) || (wuliao[12] == 0x34)) //5寸 else if((wuliao[12] == 0x33) || (wuliao[12] == 0x34)) //5寸
{ {
nowpuran = 37; nowpuran = 37;
now7926 = 37; now7926 = 37;
now7106 = 37; now7106 = 37;
up_key_press_number = 2;
} }
else else
{ {
...@@ -4919,7 +4924,7 @@ void Display_Version_Info(uint32_t ON_OFF) ...@@ -4919,7 +4924,7 @@ void Display_Version_Info(uint32_t ON_OFF)
// TFT_LCD_Draw_Bmp(3, 160, ( uint8_t * )gImage_Alarm_12_WordX6_Y165); //24脚输出占空比 // TFT_LCD_Draw_Bmp(3, 160, ( uint8_t * )gImage_Alarm_12_WordX6_Y165); //24脚输出占空比
// TFT_LCD_Draw_Bmp(210, 160, ( uint8_t * )gImage_Alarm_13_ImageX222_Y166); //% // TFT_LCD_Draw_Bmp(210, 160, ( uint8_t * )gImage_Alarm_13_ImageX222_Y166); //%
TFT_LCD_Draw_Bmp(3, 290, ( uint8_t * )gImage_gImage_checkVX6_Y165 ); //检测台版本号 TFT_LCD_Draw_Bmp(3, 290, ( uint8_t * )gImage_gImage_checkVX6_Y165 ); //检测台版本号
uint8_t mbuff [7] = {2,5,1,2,2,0,0xff}; uint8_t mbuff [7] = {2,5,1,2,2,6,0xff};
General_Number_Disp(mbuff, 160, 290); General_Number_Disp(mbuff, 160, 290);
} }
......
...@@ -86,6 +86,7 @@ void GUI_General_Digit_Display(uint32_t Digit, const uint8_t *Font[], uint8_t Le ...@@ -86,6 +86,7 @@ void GUI_General_Digit_Display(uint32_t Digit, const uint8_t *Font[], uint8_t Le
void GUI_Display_Version_Code_Service(uint8_t StarX, uint16_t PosY, uint8_t * Str, const uint8_t * Version[] , uint8_t SpaceKeySize); void GUI_Display_Version_Code_Service(uint8_t StarX, uint16_t PosY, uint8_t * Str, const uint8_t * Version[] , uint8_t SpaceKeySize);
extern uint8_t UDS_Warning_Voltage; extern uint8_t UDS_Warning_Voltage;
extern uint8_t up_key_press_number;
extern const uint16_t BackLightDigitNum09PosX[]; extern const uint16_t BackLightDigitNum09PosX[];
extern const uint8_t *Num_09[]; extern const uint8_t *Num_09[];
......
...@@ -396,14 +396,34 @@ void OpenOTASercice(void) ...@@ -396,14 +396,34 @@ void OpenOTASercice(void)
uint8_t Version_number_key_time; uint8_t Version_number_key_time;
uint8_t Version_number_begin; uint8_t Version_number_begin;
uint16_t enterdelaytime; uint16_t enterdelaytime;
uint8_t entermenutime;
void EnterVersionNumber(void) void EnterVersionNumber(void)
{ {
LeftturnSignal = 1; LeftturnSignal = 1;
RightturnSignal = 1; RightturnSignal = 1;
Lowbeam = 1; Lowbeam = 1;
uint8_t up_key_press_time = (up_key_press_number * 20);
if(enterdelaytime <= 600) //等待开机动画 if(enterdelaytime <= 600) //等待开机动画
{ {
if(jiaoyan == 1)
{
if(entermenutime <= 200)
{
entermenutime++;
}
if(entermenutime >= 110)
{
queren = 0;
}
else if(entermenutime >= 100)
{
queren = 1;
}
}
enterdelaytime++; enterdelaytime++;
} }
else else
...@@ -418,15 +438,15 @@ void EnterVersionNumber(void) ...@@ -418,15 +438,15 @@ void EnterVersionNumber(void)
Version_number_begin = 1; Version_number_begin = 1;
} }
if(Version_number_key_time <= 60) if(Version_number_key_time <= up_key_press_time)
{ {
Press_to_down = ((Version_number_key_time / 10) % 2) == 0 ? 1 : 0; Press_to_up = ((Version_number_key_time / 10) % 2) == 0 ? 1 : 0;
} }
else if(Version_number_key_time < 80) else if(Version_number_key_time < (up_key_press_time + 20))
{ {
queren = ((Version_number_key_time / 10) % 2) == 0 ? 1 : 0; queren = ((Version_number_key_time / 10) % 2) == 0 ? 1 : 0;
} }
else if(Version_number_key_time <= 100) else if(Version_number_key_time <= (up_key_press_time + 40))
{ {
Press_to_up = ((Version_number_key_time / 10) % 2) == 0 ? 1 : 0; Press_to_up = ((Version_number_key_time / 10) % 2) == 0 ? 1 : 0;
} }
......
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