Commit 8a08ea0a authored by 李梓源's avatar 李梓源

feat:坐桶锁打开改手动轮动报警换到第三步

parent 6550d451
......@@ -73,7 +73,7 @@ void Function_Check_Ctrl(uint32_t cmd);
void MENU_CHECK_STEP_ADD(void)
{
MENU_CHECK_STEP++;
if(MENU_CHECK_STEP > 10)
if(MENU_CHECK_STEP > 8)
{
MENU_CHECK_STEP = 0;
}
......@@ -645,10 +645,15 @@ void Function_Check_Ctrl(uint32_t cmd)
RELAY_KEY_MCU = 0;
ONE_START = 1;
}
else
else if(ONE_KEY_ONOFF>110 && ONE_KEY_ONOFF <=120)
{
ONE_START = 0;
ABC_OUT = 1;
}
else
{
ABC_OUT = 0;
}
break;
}
case 3:
......@@ -707,65 +712,12 @@ void Function_Check_Ctrl(uint32_t cmd)
}
case 8:
{
RELAY_VBAT_MCU = 1;
RELAY_DC12V_MCU = 1;
RELAY_KEY_MCU = 0;
RELAY_LIGHTCONTROL_MCU = 0;
if (ONE_KEY_ONOFF >=160 && ONE_KEY_ONOFF < 170)
{
ABC_OUT = 1;
}
else if (ONE_KEY_ONOFF >= 170)
{
ABC_OUT = 0;
}
break;
}
case 9:
{
RELAY_VBAT_MCU = 1;
RELAY_DC12V_MCU = 1;
RELAY_KEY_MCU = 1;
ABC_OUT = 0;
if(ACCONOFF_delay_3s >= 115)
{
ONE_START = 0;
}
else if (ACCONOFF_delay_3s >=110 && ACCONOFF_delay_3s < 115)
{
ONE_START = 1;
}
else if (ACCONOFF_delay_3s >= 105 && ACCONOFF_delay_3s < 110)
{
ONE_START = 0;
}
else if (ACCONOFF_delay_3s >= 100 && ACCONOFF_delay_3s < 105)
{
ONE_START = 1;
}
else if (ACCONOFF_delay_3s >= 95 && ACCONOFF_delay_3s < 100)
{
ONE_START = 0;
}
else if (ACCONOFF_delay_3s >= 90 && ACCONOFF_delay_3s < 95)
{
ONE_START = 1;
}
else
{
ONE_START = 0;
}
RELAY_LIGHTCONTROL_MCU = 0;
break;
}
case 10:
{
RELAY_VBAT_MCU = 1;
RELAY_DC12V_MCU = 1;
RELAY_KEY_MCU = 0;
break;
}
default:
break;
......
......@@ -4427,7 +4427,12 @@ void Display_Send_Vspead(uint8_t menu)
switch (menu)
{
case 1:
case 0:
{
CHECK_Value = 1;
break;
}
case 1:
if(DIS_AD == 0)
{
......@@ -4445,20 +4450,44 @@ void Display_Send_Vspead(uint8_t menu)
}
break;
case 2:
if(CHECK_Ctrl_delay >= 100)
// if(CHECK_Ctrl_delay >= 100)
// {
// CHECK_Value = 1;
// }
// else
// {
// CHECK_Value = 0;
// }
if(DIS_AD == 0)
{
CHECK_Value = 1;
DIS_VALUE = 1;
TFT_LCD_Draw_Bmp(51,261,( uint8_t * )gImage_Alarm_10_Word0X51_Y261);
}
else
{
CHECK_Value = 0;
if(DIS_VALUE == 1)
{
CHECK_Value = 1;
DIS_VALUE = 0;
}
// TFT_LCD_Draw_Box(0, 261, 239, 319, TFT_LCD_FILL_FULL, TFT_LCD_TYPE_CLR);
}
break;
case 3:
if(LOGOTY_AD == 1)
{
CHECK_Value = 1;
TFT_LCD_Draw_Bmp(51,261,( uint8_t * )gImage_Alarm_13_Word0X51_Y261);
}
else
{
TFT_LCD_Draw_Box(0, 261, 239, 319, TFT_LCD_FILL_FULL, TFT_LCD_TYPE_CLR);
}
break;
case 4:
CHECK_Value = 1;
CHECK_Value = 1;
break;
case 5:
if(ZXSW_AD == 1)
......@@ -4494,23 +4523,23 @@ void Display_Send_Vspead(uint8_t menu)
}
break;
// case 8:
// if(DIS_AD == 0)
// {
// DIS_VALUE = 1;
// TFT_LCD_Draw_Bmp(51,261,( uint8_t * )gImage_Alarm_10_Word0X51_Y261);
// }
// else
// {
// if(DIS_VALUE == 1)
// {
// CHECK_Value = 1;
// DIS_VALUE = 0;
// }
// // TFT_LCD_Draw_Box(0, 261, 239, 319, TFT_LCD_FILL_FULL, TFT_LCD_TYPE_CLR);
// }
// break;
case 8:
if(DIS_AD == 0)
{
DIS_VALUE = 1;
TFT_LCD_Draw_Bmp(51,261,( uint8_t * )gImage_Alarm_10_Word0X51_Y261);
}
else
{
if(DIS_VALUE == 1)
{
CHECK_Value = 1;
DIS_VALUE = 0;
}
// TFT_LCD_Draw_Box(0, 261, 239, 319, TFT_LCD_FILL_FULL, TFT_LCD_TYPE_CLR);
}
break;
case 9:
if(ZYS_A == 1)
{
CHECK_Value = 1;
......@@ -4530,25 +4559,6 @@ void Display_Send_Vspead(uint8_t menu)
// Display_TFT_Clear();
}
break;
case 10:
if(WYTY_AD == 1)
{
TFT_LCD_Draw_Bmp(51,200,( uint8_t * )gImage_Alarm_12_Word0X51_Y261);
}
else
{
TFT_LCD_Draw_Box(0, 200, 239, 261, TFT_LCD_FILL_FULL, TFT_LCD_TYPE_CLR);
}
if(LOGOTY_AD == 1)
{
CHECK_Value = 1;
TFT_LCD_Draw_Bmp(51,261,( uint8_t * )gImage_Alarm_13_Word0X51_Y261);
}
else
{
TFT_LCD_Draw_Box(0, 261, 239, 319, TFT_LCD_FILL_FULL, TFT_LCD_TYPE_CLR);
}
break;
default:
MENU_CHECK_STEP = 0;
break;
......
......@@ -4,7 +4,7 @@
* \attention
*
* This file is automatically generated by analog signals configuration tool.
* Date : 2025/2/18 19:34:44
* Date : 2025/3/5 20:42:21
* Cfg Tool Ver : 1.1.0
* Engineer :
* (c) Heilongjiang TYW electronics co., LTD
......@@ -27,19 +27,13 @@ extern {
/* Exported types ------------------------------------------------------------*/
enum ADCChName
{
ADC_CH_ZXSW = 0,
ADC_CH_GKDD,
ADC_CH_ZTS_A,
ADC_CH_DIS,
ADC_CH_ZTS_B,
ADC_CH_LOGOTY,
ADC_CH_WYTY,
ADC_CH_ACC,
ADC_CH_12_VOLTAGE = 0,
ADC_CH_13_VOLTAGE,
};
/* Exported macro ------------------------------------------------------------*/
#define ADC_TOTAL_CH_NUMBER (8U)
#define ADC_SIGNAL_CH_NUMBER (8U)
#define ADC_TOTAL_CH_NUMBER (2U)
#define ADC_SIGNAL_CH_NUMBER (2U)
#define ADC_REF_VOLTAGE u16ADCRefVoltage
/* Exported variables --------------------------------------------------------*/
......
......@@ -4,7 +4,7 @@
* \attention
*
* This file is automatically generated by analog signals configuration tool.
* Date : 2025/2/18 19:34:44
* Date : 2025/3/5 20:42:21
* Cfg Tool Ver : 1.1.0
* Engineer :
* (c) Heilongjiang TYW electronics co., LTD
......@@ -74,29 +74,17 @@ ADC_Data_st_t stADCData[ADC_SIGNAL_CH_NUMBER];
const uint8_t u8ADCChList[ADC_CONV_CH_NUMBER] =
{
13U, 12U, 15U, 11U, 14U, 10U, 9U, 7U,
12U, 13U,
};
const ADC_Ch_Cfg_st_t stADCChCfg[ADC_SIGNAL_CH_NUMBER] =
{
{ 0U, 0U, 0U, 0U, 0U, 1U, ADC_Voltage_Calc_Circuit102,},
{ 1U, 0U, 0U, 0U, 0U, 1U, ADC_Voltage_Calc_Circuit102,},
{ 2U, 0U, 0U, 0U, 0U, 1U, ADC_Voltage_Calc_Circuit102,},
{ 3U, 0U, 0U, 0U, 0U, 1U, ADC_Voltage_Calc_Circuit102,},
{ 4U, 0U, 0U, 0U, 0U, 1U, ADC_Voltage_Calc_Circuit102,},
{ 5U, 0U, 0U, 0U, 0U, 1U, ADC_Voltage_Calc_Circuit102,},
{ 6U, 0U, 0U, 0U, 0U, 1U, ADC_Voltage_Calc_Circuit102,},
{ 7U, 0U, 0U, 0U, 0U, 1U, ADC_Voltage_Calc_Circuit102,},
{ 1U, 0U, 0U, 0U, 0U, 1U, ADC_Voltage_Calc_Circuit101,},
};
const ADC_Res_List_st_t stADCResList[ADC_SIGNAL_CH_NUMBER] =
{
{ 3300000U, 1000000U, 0U, 0U,},
{ 3300000U, 1000000U, 0U, 0U,},
{ 3300000U, 1000000U, 0U, 0U,},
{ 3300000U, 1000000U, 0U, 0U,},
{ 3300000U, 1000000U, 0U, 0U,},
{ 3300000U, 1000000U, 0U, 0U,},
{ 3300000U, 1000000U, 0U, 0U,},
{ 3300000U, 100000U, 0U, 0U,},
};
......
/**************************************************************************//**
* \file Analog_Signals.h
* \brief Analog signal processing
* \attention
*
* This file is automatically generated by analog signals configuration tool.
* Date : 2023/9/9 15:45:21
* Cfg Tool Ver : 1.1.0
* Engineer :
* (c) Heilongjiang TYW electronics co., LTD
*
******************************************************************************/
#ifndef ANALOG_SIGNALS_H__
#define ANALOG_SIGNALS_H__
/* Includes -----------------------------------------------------------------*/
#include "ADC.h"
#include "Analog_Circuits.h"
/* C binding of definitions if building with C++ compiler */
#ifdef __cplusplus
extern {
#endif
/*! @{ */
/* Exported types ------------------------------------------------------------*/
enum ADCChName
{
ADC_CH_KL15_VOLTAGE = 0,
ADC_CH_KL30_VOLTAGE,
ADC_CH_10_VOLTAGE,
};
/* Exported macro ------------------------------------------------------------*/
#define ADC_TOTAL_CH_NUMBER (3U)
#define ADC_SIGNAL_CH_NUMBER (3U)
#define ADC_REF_VOLTAGE u16ADCRefVoltage
/* Exported variables --------------------------------------------------------*/
extern volatile uint16_t u16ADCRefVoltage;
/* Exported functions --------------------------------------------------------*/
extern void Analog_Signal_Conv_Init(void);
extern void Analog_Signal_Conv_Stop(void);
extern void Analog_Signal_Conv_Service(void);
extern uint16_t ADC_Read_Signal(uint8_t u8ADCCh);
extern uint8_t ADC_Read_Signal_Valid(uint8_t u8ADCCh);
extern uint16_t ADC_Conv_Single_Channel(uint8_t u8ADCCh);
/*! @} */
#ifdef __cplusplus
}
#endif
#endif /* ANALOG_SIGNALS_H__ */
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