Commit afa7cddb authored by 郑萍's avatar 郑萍

feat:部分贴图

parent 5b45145d
...@@ -87,7 +87,7 @@ void Api_GPIO_Init(void) ...@@ -87,7 +87,7 @@ void Api_GPIO_Init(void)
Port_SetPinConfig(1, 3, &stc_IN_pin_config); // Port_SetPinConfig(1, 3, &stc_IN_pin_config); //
Port_SetPinConfig(1, 7, &stc_IN_pin_config); // Port_SetPinConfig(1, 7, &stc_IN_pin_config); //
// Port_SetPinConfig(1, 4, &stc_IN_pin_config); //NEW BUTTON 7 AD �ɼ� // Port_SetPinConfig(1, 4, &stc_IN_pin_config); //NEW BUTTON 7 AD �ɼ�
Port_SetPinConfig(1, 15, &stc_IN_pin_config); // b+~
Port_SetPinConfig(1, 10, &stc_IN_pin_config); // test Port_SetPinConfig(1, 10, &stc_IN_pin_config); // test
//AD�ɼ��� //AD�ɼ���
...@@ -111,7 +111,7 @@ void Api_GPIO_Init(void) ...@@ -111,7 +111,7 @@ void Api_GPIO_Init(void)
.enGpioInitOutputLevel = PortGpioLow, .enGpioInitOutputLevel = PortGpioLow,
}; };
Port_SetPinConfig(1, 15, &stc_OUT_pin_config); // b+~
//BD8379���� //BD8379����
Port_SetPinConfig(2, 4, &stc_OUT_pin_config); //L_ONEBitCLU_OUT Port_SetPinConfig(2, 4, &stc_OUT_pin_config); //L_ONEBitCLU_OUT
Port_SetPinConfig(2, 5, &stc_OUT_pin_config); //L_CLKBitCLU_OUT Port_SetPinConfig(2, 5, &stc_OUT_pin_config); //L_CLKBitCLU_OUT
......
...@@ -277,7 +277,7 @@ static void TIMER_1MS_ISR(void) ...@@ -277,7 +277,7 @@ static void TIMER_1MS_ISR(void)
CanRecvLibTimerCall(Timer1msCnts); CanRecvLibTimerCall(Timer1msCnts);
//button State //button State
if (ClusterValidTimerCnts) { if (ClusterValidTimerCnts) {
if(g_Stage != STAGE_ClearODO && g_Stage != STAGE_AutoCheck) { if(g_Stage != STAGE_ClearODO && HJ_OtherKeyCurrent.count != 11) {
ClusterValidTimerCnts--; ClusterValidTimerCnts--;
} }
else { else {
...@@ -656,7 +656,7 @@ static void TIMER13_10MS_ISR(void) ...@@ -656,7 +656,7 @@ static void TIMER13_10MS_ISR(void)
DisplayErrTimer = 0; DisplayErrTimer = 0;
} }
if (g_Stage == STAGE_AutoCheck) { if (HJ_OtherKeyCurrent.count == 11) {
if(StaticCurrent.count < 50){ if(StaticCurrent.count < 50){
StaticCurrent.buf[StaticCurrent.count] = AdcValList[14];//18 StaticCurrent.buf[StaticCurrent.count] = AdcValList[14];//18
AAA = AdcValList[14]; AAA = AdcValList[14];
......
This diff is collapsed.
This source diff could not be displayed because it is too large. You can view the blob instead.
...@@ -38,6 +38,8 @@ uint8_t NUM5_Data[10]; ...@@ -38,6 +38,8 @@ uint8_t NUM5_Data[10];
uint8_t NUM6_Data[10]; uint8_t NUM6_Data[10];
uint8_t NUM7_Data[10]; uint8_t NUM7_Data[10];
uint8_t NUM8_Data[20]; uint8_t NUM8_Data[20];
uint8_t NUM9_Data[20];
uint8_t NUM10_Data[20];
uint8_t CSW_Data[10]; uint8_t CSW_Data[10];
uint8_t SendSW; uint8_t SendSW;
uint8_t SendNUM1; uint8_t SendNUM1;
...@@ -2057,7 +2059,7 @@ void OtherCheck(void) ...@@ -2057,7 +2059,7 @@ void OtherCheck(void)
SetStartTime(0); SetStartTime(0);
break; break;
case AUTO_STATIC: case AUTO_STATIC:
StaticCurrentCheck();
break; break;
// case AUTO_OTHER: // case AUTO_OTHER:
// SpeedFreqILLCheck(); // SpeedFreqILLCheck();
...@@ -2528,7 +2530,7 @@ void APP_AUTO(void) ...@@ -2528,7 +2530,7 @@ void APP_AUTO(void)
default: default:
ErrorCode = 99;//?????? ErrorCode = 99;//??????
SetStartTime(0); SetStartTime(0);
ButtomCurrent.enable = 0;
break; break;
} }
} }
......
...@@ -131,7 +131,7 @@ void Get_Button_Value()//��ȡ����AD ...@@ -131,7 +131,7 @@ void Get_Button_Value()//��ȡ����AD
else else
Botton.Back_light.Flag = 0; Botton.Back_light.Flag = 0;
#else #else
if (g_Stage != STAGE_AutoCheck) { if (HJ_OtherKeyCurrent.count != 11) {
Test_AD = Calculate_Thermistor(AdcValList[15]); Test_AD = Calculate_Thermistor(AdcValList[15]);
if((Test_AD > 130) && (Test_AD < 150))//���� if((Test_AD > 130) && (Test_AD < 150))//����
Botton.Luminosity.Flag = 1; Botton.Luminosity.Flag = 1;
...@@ -1409,7 +1409,7 @@ void UserPressAuto(void) ...@@ -1409,7 +1409,7 @@ void UserPressAuto(void)
{ {
g_Stage = STAGE_AutoCheck; g_Stage = STAGE_AutoCheck;
#if (PRO_CONFIG_CHECK_APPLY) #if (PRO_CONFIG_CHECK_APPLY)
Auto_Init(1);//��������̬������� // Auto_Init(1);//��������̬�������
#endif #endif
} }
...@@ -1447,41 +1447,42 @@ uint8_t g_LedCheckDeriction = 0; ...@@ -1447,41 +1447,42 @@ uint8_t g_LedCheckDeriction = 0;
void UserPressWarning(void) void UserPressWarning(void)
{ {
g_Stage = STAGE_Led_Telltale_Check; g_Stage = STAGE_Led_Telltale_Check;
#if (PRO_CONFIG_CHECK_APPLY)
if(g_LedCheckDeriction == 1 && LedCurrent.count > 0) { // #if (PRO_CONFIG_CHECK_APPLY)
LedCurrent.count = 0; // if(g_LedCheckDeriction == 1 && LedCurrent.count > 0) {
} // LedCurrent.count = 0;
g_LedCheckDeriction = 0; // }
if (g_uiLedWaitTimer <= 0){ // g_LedCheckDeriction = 0;
#if (SEMI_AUTOMATIC_STAGE) // if (g_uiLedWaitTimer <= 0){
if(LedCurrent.count < STAGE_COUNT_HARD_LINE_LED) // #if (SEMI_AUTOMATIC_STAGE)
LedCurrent.count ++; // if(LedCurrent.count < STAGE_COUNT_HARD_LINE_LED)
g_uiLedWaitTimer = 1000; // LedCurrent.count ++;
// if(LedCurrent.count == 4){ // g_uiLedWaitTimer = 1000;
// LedCurrent.count = 1; // // if(LedCurrent.count == 4){
// } // // LedCurrent.count = 1;
#else // // }
#if (PRO_NU2) // #else
if(LedCurrent.count < 6) // #if (PRO_NU2)
LedCurrent.count ++; // if(LedCurrent.count < 6)
g_uiLedWaitTimer = 1000; // LedCurrent.count ++;
if(LedCurrent.count == 6){ // g_uiLedWaitTimer = 1000;
LedCurrent.count = 1; // if(LedCurrent.count == 6){
} // LedCurrent.count = 1;
#else // }
if(LedCurrent.count < 4) // #else
LedCurrent.count ++; // if(LedCurrent.count < 4)
g_uiLedWaitTimer = 1000; // LedCurrent.count ++;
if(LedCurrent.count == 4){ // g_uiLedWaitTimer = 1000;
LedCurrent.count = 1; // if(LedCurrent.count == 4){
} // LedCurrent.count = 1;
#endif // }
#endif // #endif
} // #endif
memset(&BuzzerAlarm, 0, sizeof(BuzzerAlarm)); // }
memset(&CheckCurrent,0,sizeof(CheckCurrent)); // memset(&BuzzerAlarm, 0, sizeof(BuzzerAlarm));
LedCurrent.Flag = 0; // memset(&CheckCurrent,0,sizeof(CheckCurrent));
#endif // LedCurrent.Flag = 0;
// #endif
} }
uint8_t g_SpeedCheckDeriction = 0; uint8_t g_SpeedCheckDeriction = 0;
void UserPressKeySpeedUp(void) void UserPressKeySpeedUp(void)
...@@ -2290,23 +2291,7 @@ void HJ_SwitchSecondPage() ...@@ -2290,23 +2291,7 @@ void HJ_SwitchSecondPage()
g_Stage = STAGE_Other; g_Stage = STAGE_Other;
//VSPEED //VSPEED
if(HJ_OtherKeyCurrent.count <= 10) {
HJ_CurvSpeedNum = ((((HJ_OtherKeyCurrent.count - 1) * 20 )*100)/105) + 1;
if(HJ_CurvSpeedNum < 25)
HJ_CurvSpeedNum-=1;
} else {
HJ_CurvSpeedNum = 199;
}
//Gear
if(HJ_OtherKeyCurrent.count <= 7) {
HJ_SettingNum = (HJ_OtherKeyCurrent.count-1);}
else if(HJ_OtherKeyCurrent.count == 8 ) {
HJ_SettingNum = 0;
} else{
HJ_SettingNum = 15 - HJ_OtherKeyCurrent.count;
}
//ESPEED //ESPEED
if(HJ_OtherKeyCurrent.count <= 9) { if(HJ_OtherKeyCurrent.count <= 9) {
...@@ -2519,7 +2504,7 @@ void Stage_Manage() ...@@ -2519,7 +2504,7 @@ void Stage_Manage()
#endif #endif
} }
if(Botton.Auto.Statu == 1){ // �Լ� if((Botton.Auto.Statu == 1)){ // �Լ�
Botton.Auto.Statu = 0; Botton.Auto.Statu = 0;
#if (SEMI_AUTOMATIC_STAGE) #if (SEMI_AUTOMATIC_STAGE)
#else #else
...@@ -2534,11 +2519,7 @@ void Stage_Manage() ...@@ -2534,11 +2519,7 @@ void Stage_Manage()
// UserPressEOL();//�������� // UserPressEOL();//��������
g_Stage = STAGE_Other; g_Stage = STAGE_Other;
if (HJ_OtherKeyCurrent.count == 0) {
HJ_OtherKeyCurrent.count = 11;
} else {
HJ_OtherKeyCurrent.count --;
}
ClearOtherSWFlagFun(); ClearOtherSWFlagFun();
ClearOtherFlagFun(); ClearOtherFlagFun();
Othercount = 0; Othercount = 0;
...@@ -2557,11 +2538,24 @@ void Stage_Manage() ...@@ -2557,11 +2538,24 @@ void Stage_Manage()
if(Botton.SpeedDown.Statu == 1){ // SPEED DOWN if(Botton.SpeedDown.Statu == 1){ // SPEED DOWN
Botton.SpeedDown.Statu = 0; Botton.SpeedDown.Statu = 0;
g_Stage = STAGE_Speed;
HJ_OtherKeyCurrent.count ++;
if(HJ_OtherKeyCurrent.count == 11)
{
Auto_Init(1);
}
if(HJ_OtherKeyCurrent.count > 11) {
HJ_OtherKeyCurrent.count = 1;
}
#if (SEMI_AUTOMATIC_STAGE) #if (SEMI_AUTOMATIC_STAGE)
if (g_PerFuncExecSecond == 0) if (g_PerFuncExecSecond == 0)
ExecSemiAutomaticCheck(0); ExecSemiAutomaticCheck(0);
#else #else
UserPressKeySpeedDown();//����-����
// UserPressKeySpeedDown();//����-����
#endif #endif
} }
...@@ -2575,14 +2569,22 @@ void Stage_Manage() ...@@ -2575,14 +2569,22 @@ void Stage_Manage()
if(Botton.FuelWaterUp.Statu == 1){ if(Botton.FuelWaterUp.Statu == 1){
Botton.FuelWaterUp.Statu = 0; Botton.FuelWaterUp.Statu = 0;
g_Stage = STAGE_WaterAndFuel;
if (HJ_OtherKeyCurrent.count == 0) {
HJ_OtherKeyCurrent.count = 11;
Auto_Init(1);
} else {
HJ_OtherKeyCurrent.count --;
}
#if (SEMI_AUTOMATIC_STAGE) #if (SEMI_AUTOMATIC_STAGE)
#else #else
UserPressKeyOilTempUp();//ȼ�͡�ˮ��+���� // UserPressKeyOilTempUp();//ȼ�͡�ˮ��+����
Gear_SWCount ++; // Gear_SWCount ++;
if(Gear_SWCount > 5) // if(Gear_SWCount > 5)
{ // {
Gear_SWCount = 1; // Gear_SWCount = 1;
} // }
#endif #endif
} }
...@@ -2684,15 +2686,12 @@ void Stage_Manage() ...@@ -2684,15 +2686,12 @@ void Stage_Manage()
//UserPressKeyElse();//�������� //UserPressKeyElse();//��������
// DOWNKeyCurrent.count ++; // DOWNKeyCurrent.count ++;
g_Stage = STAGE_Other; g_Stage = STAGE_Other;
HJ_OtherKeyCurrent.count ++;
Line_Temp(); Line_Temp();
ClearOtherSWFlagFun(); ClearOtherSWFlagFun();
ClearOtherFlagFun(); ClearOtherFlagFun();
Othercount = 0; Othercount = 0;
if(HJ_OtherKeyCurrent.count > 11) {
HJ_OtherKeyCurrent.count = 1;
}
#endif #endif
} }
...@@ -2707,7 +2706,7 @@ void Stage_Manage() ...@@ -2707,7 +2706,7 @@ void Stage_Manage()
g_OldStage = g_Stage; g_OldStage = g_Stage;
if(g_Stage != STAGE_AutoCheck) if(HJ_OtherKeyCurrent.count != 11)
{ {
ErrorCode = 0; ErrorCode = 0;
StaticCurrent.Finsh = 0; StaticCurrent.Finsh = 0;
......
...@@ -26,6 +26,8 @@ extern uint8_t NUM5_Data[10]; ...@@ -26,6 +26,8 @@ extern uint8_t NUM5_Data[10];
extern uint8_t NUM6_Data[10]; extern uint8_t NUM6_Data[10];
extern uint8_t NUM7_Data[10]; extern uint8_t NUM7_Data[10];
extern uint8_t NUM8_Data[20]; extern uint8_t NUM8_Data[20];
extern uint8_t NUM9_Data[20];
extern uint8_t NUM10_Data[20];
extern uint8_t CSW_Data[10]; extern uint8_t CSW_Data[10];
extern volatile uint16_t ErrorCode; extern volatile uint16_t ErrorCode;
......
...@@ -836,7 +836,7 @@ void CANInit(void) ...@@ -836,7 +836,7 @@ void CANInit(void)
for(;;) for(;;)
{ {
RS485_User_Tx_Data(); // RS485_User_Tx_Data();
// // Port_SetPortPinLevel(1, 21, PortGpioLow);//测试 // // Port_SetPortPinLevel(1, 21, PortGpioLow);//测试
// Speed_Output_Update(PWMCH_SPEED_OUT, 356, 50); // Speed_Output_Update(PWMCH_SPEED_OUT, 356, 50);
......
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