Commit 4dc403ba authored by 李俭双's avatar 李俭双

Merge branch 'CHENJIALE' into 'dev'

Chenjiale

See merge request !59
parents dc9948d0 06eb2b04
......@@ -35,7 +35,7 @@ void Fuel_KL30_Init(void)
FuelInitFlag = 1u;
FuelStateInitFlag = 1u;
FuelDir = FUEL_SEG_UP;
FuelSensorState = FuelSensorShortCircuit;//FuelSensorNormal;
FuelSensorState = FuelSensorNormal;//FuelSensorShortCircuit;//FuelSensorNormal;
FuelSensorNormalTime = 0u;
FuelSensorShortTime = 0u;
FuelSensorOpenTime = 0u;
......@@ -51,7 +51,7 @@ void Fuel_KL15_Init(void)
FuelInitFlag = 1u;
FuelStateInitFlag = 1u;
FuelDir = FUEL_SEG_UP;
FuelSensorState = FuelSensorShortCircuit;//FuelSensorNormal;
FuelSensorState = FuelSensorNormal;//FuelSensorShortCircuit;//FuelSensorNormal;
FuelSensorNormalTime = 0u;
FuelSensorShortTime = 0u;
FuelSensorOpenTime = 0u;
......@@ -130,7 +130,7 @@ void Fuel_State_Check(uint8_t deltaTime)
{ /*短路 1*/
FuelSensorOpenTime = 0;
FuelSensorNormalTime = 0;
if ((FuelSensorShortTime > 3000) || ((FuelStateInitFlag) && (FuelSensorShortTime > 3000)))
if ((FuelSensorShortTime > 3000) || ((FuelStateInitFlag) && (FuelSensorShortTime <= 3000)))
{
FuelSensorState = FuelSensorShortCircuit;
DesFuelSetp = 0;
......@@ -148,7 +148,7 @@ void Fuel_State_Check(uint8_t deltaTime)
{ /*断路 320*/
FuelSensorShortTime = 0;
FuelSensorNormalTime = 0;
if ((FuelSensorOpenTime > 2800) || ((FuelStateInitFlag) && (FuelSensorOpenTime > 2800)))
if ((FuelSensorOpenTime > 2800) || ((FuelStateInitFlag) && (FuelSensorOpenTime <= 2800)))
{
FuelSensorState = FuelSensorOpenCircuit;
DesFuelSetp = 0;
......@@ -221,7 +221,7 @@ void Fuel_Gauges_Cal(uint8_t deltaTime)
}
}
/*计算目标格数*/
if (FuelDir == FUEL_SEG_UP)
{
if (((DesFuelSetp == 4) || FuelInitFlag) && (FuelR < 130))
......@@ -268,6 +268,9 @@ void Fuel_Gauges_Cal(uint8_t deltaTime)
DesFuelSetp = 4;
}
}
}
/*IGN ON 1秒/故障恢复后,开始走格 立即指向当前格 20220704*/
......
......@@ -314,10 +314,10 @@
#define SWV 0x100 // 0x100 = 1.00 software version 软件版本号
#define HWV 0x101 // 0x100 = 1.00 hardware version 硬件版本号
#define BTV 0x100 // 0x100 = 1.00 bootloader version boot程序版本号
#define INTLV 0x109 // 0x100 = 1.00 internal version 内部版本号
#define INTLV 0x110 // 0x100 = 1.00 internal version 内部版本号
#define PROG_Y 0x24 // 0x24 = 2024年, program year
#define PROG_M 0x07 // 0x03 = 3月, program month
#define PROG_D 0x24 // 0x19 = 19日, program day
#define PROG_D 0x31 // 0x19 = 19日, program day
/******************************************************************************
Bootloader Variable
......
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