Commit a5de7526 authored by 张金硕's avatar 张金硕

Merge branch 'dev' of http://tyw-server.synology.me:12345/shihao/haojin750tft into jinshuo

parents 867b358b 80ad8fd8
......@@ -275,7 +275,7 @@
</OCR_RVCT3>
<OCR_RVCT4>
<Type>1</Type>
<StartAddress>0xc400</StartAddress>
<StartAddress>0x0</StartAddress>
<Size>0x73c00</Size>
</OCR_RVCT4>
<OCR_RVCT5>
......@@ -978,11 +978,6 @@
<FileType>5</FileType>
<FilePath>..\..\..\..\Source\Component\AMT630H\PicBin.h</FilePath>
</File>
<File>
<FileName>kei_S1.0.6_20240827.lib</FileName>
<FileType>4</FileType>
<FilePath>..\..\..\..\Source\Component\AMT630H\kei_S1.0.6_20240827.lib</FilePath>
</File>
<File>
<FileName>UartProtocol.h</FileName>
<FileType>5</FileType>
......@@ -1018,6 +1013,16 @@
<FileType>5</FileType>
<FilePath>..\..\..\..\Source\Component\System_Monitor\System_Monitor_User.h</FilePath>
</File>
<File>
<FileName>System_Monitor.lib</FileName>
<FileType>4</FileType>
<FilePath>..\..\..\..\Source\Component\System_Monitor\System_Monitor.lib</FilePath>
</File>
<File>
<FileName>kei_S1.0.6_20240827.lib</FileName>
<FileType>4</FileType>
<FilePath>..\..\..\..\Source\Component\AMT630H\kei_S1.0.6_20240827.lib</FilePath>
</File>
</Files>
</Group>
<Group>
......
......@@ -2,8 +2,8 @@
; *** Scatter-Loading Description File generated by uVision ***
; *************************************************************
LR_IROM1 0x0000C400 0x00073C00 { ; load region size_region
ER_IROM1 0x0000C400 0x00073C00 { ; load address = execution address
LR_IROM1 0x00000000 0x00073C00 { ; load region size_region
ER_IROM1 0x00000000 0x00073C00 { ; load address = execution address
*.o (RESET, +First)
*(InRoot$$Sections)
.ANY (+RO)
......
......@@ -20,7 +20,7 @@ User definitions
typedef unsigned short MD_STATUS;
#define HAS_BOOTLOADER (1u) // 仅仿真App时设置为0
#define HAS_BOOTLOADER (0u) // 仅仿真App时设置为0
#define APP_BASE (0x0000C400ul)
/* Status list definition */
......
......@@ -289,26 +289,26 @@ void Data_Engine_Speed_Processing_Service ( void )
}
}
DataESpeedDisp = DataESPeedDamping.Speed;
// //第4步 增加回差
// if (DataESpeedDisp <= 80)
// {
// DataESpeedDisp = DataESPeedDamping.Speed;
// }
// else
// {
// if ( DataESpeedDisp < DataESPeedDamping.Speed )
// {
// DataESpeedDisp = DataESPeedDamping.Speed;
// }
// else
// {
// Delta = DataESpeedDisp - DataESPeedDamping.Speed;
// if ( Delta >= DATA_ESPEED_HYSTERESIS )
// {
// DataESpeedDisp = DataESPeedDamping.Speed;
// }
// }
// }
//第4步 增加回差
if (DataESpeedDisp <= 80)
{
DataESpeedDisp = DataESPeedDamping.Speed;
}
else
{
if ( DataESpeedDisp < DataESPeedDamping.Speed )
{
DataESpeedDisp = DataESPeedDamping.Speed;
}
else
{
Delta = DataESpeedDisp - DataESPeedDamping.Speed;
if ( Delta >= DATA_ESPEED_HYSTERESIS )
{
DataESpeedDisp = DataESPeedDamping.Speed;
}
}
}
}
uint8_t Get_EngineValid(void)
......
......@@ -321,12 +321,22 @@ void Data_Vehicle_Speed_Processing_Service(void)
}
// 第3步:生成显示车速
DataVSpeedHysteresis = DataVSPeedDamping.Speed;
if ((DataVSPeedDamping.Speed >= DataVSpeedHysteresis) || (DataVSPeedDamping.Speed < DATA_VSPEED_HYSTERESIS))
{
DataVSpeedHysteresis = DataVSPeedDamping.Speed;
}
else
{
if (DataVSpeedHysteresis - DataVSPeedDamping.Speed >= DATA_VSPEED_HYSTERESIS)
{
DataVSpeedHysteresis = DataVSPeedDamping.Speed;
}
}
VSpeedCal = ( uint32_t )DataVSpeedHysteresis;
if ( DataVSpeedValid )
{
// if ( DataVSpeedValid )
// {
VSpeedCal *= 105;
VSpeedCal /= 100;
// if((VSpeedCal % 10) >= 5)
......@@ -334,11 +344,11 @@ void Data_Vehicle_Speed_Processing_Service(void)
// VSpeedCal += 5; /* 四舍五入 */
// }
DataVSpeedDisp = ( uint16_t )VSpeedCal;
}
else
{
DataVSpeedDisp = 0;
}
// }
// else
// {
// DataVSpeedDisp = 0;
// }
}
/*车速有效位:有效=1,无效=0*/
......
#include "FaultCode.h"
#include "CAN_CH0_CAN_Communication_Matrix.h"
static _st_Init FaultCodeInit;
static uint16_t u16FaultCodeDtcCount = 0;
static uint16_t u16FaultCodeDtcCountBack = 0;
......@@ -395,3 +396,21 @@ uint8_t Get_FaultCode_Valid(void)
{
return u8FaultCodeValid;
}
/*
*NAME : Get_FaultCode_Lost()
*FUNCTION : 获取发送故障码的CAN是否掉线
*RETURN : 0-LOST 1-ONLINE
*/
uint8_t Get_FaultCode_Lost(void)
{
uint8_t u8FaultCodeLost = 0;
if(CAN_MSG_Status(&CAN_CH0_CanMsgOp, CAN_CH0_ID_CH0_402_Msg_Count) == CAN_SIG_LOST)
{
u8FaultCodeLost = 0;
}
else
{
u8FaultCodeLost = 1;
}
return u8FaultCodeLost;
}
......@@ -147,7 +147,7 @@ void Key_KL30_Init_EXample(void)
Key_Parameter_Set_Short_Press_1_Time(50U,2000U);
Key_Parameter_Set_Short_Press_2_Time(3000U,6000U);
Key_Parameter_Set_Long_Press_1_Time(7000U);
Key_Parameter_Set_Long_Press_1_Time(2000U);
Key_Parameter_Set_Long_Press_2_Time(8000U);
Key_Parameter_Set_Long_Press_3_Time(9000U);
Key_Parameter_Set_Long_Press_4_Time(10000U);
......@@ -163,7 +163,7 @@ void Key_Wakeup_Init_EXample(void)
Key_Parameter_Set_Short_Press_1_Time(50U,2000U);
Key_Parameter_Set_Short_Press_2_Time(3000U,6000U);
Key_Parameter_Set_Long_Press_1_Time(7000U);
Key_Parameter_Set_Long_Press_1_Time(2000U);
Key_Parameter_Set_Long_Press_2_Time(8000U);
Key_Parameter_Set_Long_Press_3_Time(9000U);
Key_Parameter_Set_Long_Press_4_Time(10000U);
......
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