Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
TianYing_ty100
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
TY
TianYing_ty100
Commits
3fa98a0d
Commit
3fa98a0d
authored
May 06, 2024
by
李俭双
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
🐞
fix:更改编译报错
parent
fe699558
Changes
12
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
12 changed files
with
348 additions
and
249 deletions
+348
-249
CAN_CH0_CAN_Communication_Matrix.c
...ce/Application/CAN_APP/CAN_CH0_CAN_Communication_Matrix.c
+8
-2
CAN_CH0_CAN_Communication_Matrix.h
...ce/Application/CAN_APP/CAN_CH0_CAN_Communication_Matrix.h
+4
-1
Can_App.c
Firmware/Source/Application/CAN_User/Can_App.c
+1
-1
Can_App.h
Firmware/Source/Application/CAN_User/Can_App.h
+1
-1
GUI_Display.c
Firmware/Source/Application/GUI_Display/GUI_Display.c
+22
-22
SEG_DISPLAY.c
Firmware/Source/Application/SEG_DISPLAY/SEG_DISPLAY.c
+18
-18
Key_user.c
Firmware/Source/Component/Key/Key_user.c
+17
-17
Line_In_user.c
Firmware/Source/Component/Line_In/Line_In_user.c
+1
-1
Line_In_user.h
Firmware/Source/Component/Line_In/Line_In_user.h
+2
-0
PowerManag_user.c
Firmware/Source/Component/PowerManagement/PowerManag_user.c
+2
-2
Telltales_user.c
Firmware/Source/Component/Telltales/Telltales_user.c
+250
-175
Telltales_user.h
Firmware/Source/Component/Telltales/Telltales_user.h
+22
-9
No files found.
Firmware/Source/Application/CAN_APP/CAN_CH0_CAN_Communication_Matrix.c
View file @
3fa98a0d
#include "CAN_CH0_CAN_Communication_Matrix.h"
#include "Components.h"
#include "Application.h"
/* 2024/04/26 10:01:26 */
st_CanMsgOp
CAN_CH0_CanMsgOp
;
st_CanMsgTxOp
CAN_CH0_CanMsgTxOp
;
...
...
@@ -6,6 +8,10 @@ st_CanMsgTxOp CAN_CH0_CanMsgTxOp;
const
st_CAN_SendAttribute
CAN_CH0_CANSendAttr
[
CAN_CH0_ID_SEND_TOTAL
]
=
{
{
0x220ul
,
8ul
*
1000ul
,
7ul
*
1000ul
,
0u
,
MSG_STD
,
1u
,
8u
,
CAN_MSG_TX_CYCLE
,
Can_Set_Buff_500
,
(
void
*
)
0
},
{
0x6EEul
,
8ul
*
1000ul
,
7ul
*
1000ul
,
0u
,
MSG_STD
,
1u
,
8u
,
CAN_MSG_TX_CYCLE
,
Can_Set_Buff_500
,
(
void
*
)
0
},
{
0x6EFul
,
8ul
*
1000ul
,
7ul
*
1000ul
,
0u
,
MSG_STD
,
1u
,
8u
,
CAN_MSG_TX_CYCLE
,
Can_Set_Buff_500
,
(
void
*
)
0
},
{
0x450ul
,
8ul
*
1000ul
,
7ul
*
1000ul
,
0u
,
MSG_STD
,
1u
,
8u
,
CAN_MSG_TX_CYCLE
,
Can_Set_Buff_500
,
(
void
*
)
0
},
};
const
st_CANMsgAttribute
CAN_CH0_CAN_MSG_CONST_ARRAY
[
CAN_CH0_ID_TOTAL_MAX
]
=
...
...
@@ -54,7 +60,7 @@ const st_CANMsgAttribute CAN_CH0_CAN_MSG_CONST_ARRAY[CAN_CH0_ID_TOTAL_MAX] =
{
0x00u
,
0x00u
,
0x00u
,
0x00u
,
0x00u
,
0x00u
,
0x00u
,
0x00u
},
{
0x00u
,
0x00u
,
0x00u
,
0x00u
,
0x00u
,
0x00u
,
0x00u
,
0x00u
},
{
0x00u
,
0x00u
,
0x00u
,
0x00u
,
0x00u
,
0x00u
,
0x00u
,
0x00u
},
5
000ul
,
1
000ul
,
0x120ul
,
((
void
*
)
0
),
((
void
*
)
0
),
...
...
@@ -64,7 +70,7 @@ const st_CANMsgAttribute CAN_CH0_CAN_MSG_CONST_ARRAY[CAN_CH0_ID_TOTAL_MAX] =
{
0x00u
,
0x00u
,
0x00u
,
0x00u
,
0x00u
,
0x00u
,
0x00u
,
0x00u
},
{
0x00u
,
0x00u
,
0x00u
,
0x00u
,
0x00u
,
0x00u
,
0x00u
,
0x00u
},
{
0x00u
,
0x00u
,
0x00u
,
0x00u
,
0x00u
,
0x00u
,
0x00u
,
0x00u
},
5
000ul
,
2
000ul
,
0x101ul
,
((
void
*
)
0
),
((
void
*
)
0
),
...
...
Firmware/Source/Application/CAN_APP/CAN_CH0_CAN_Communication_Matrix.h
View file @
3fa98a0d
...
...
@@ -20,7 +20,10 @@ typedef enum
typedef
enum
{
CAN_CH0_ID_CAN_0x220_Msg_Count
,
CAN_CH0_ID_CAN_0x6EE_Msg_Count
,
CAN_CH0_ID_CAN_0x6EF_Msg_Count
,
CAN_CH0_ID_CAN_0x450_Msg_Count
,
CAN_CH0_ID_SEND_TOTAL
,
}
CAN_CH0_CAN_MSG_SEND_ID_t
;
...
...
Firmware/Source/Application/CAN_User/Can_App.c
View file @
3fa98a0d
...
...
@@ -12,7 +12,7 @@ void Can_Set_Buff_500(canlib_uint8_t CopyData[])
p500
=
(
CANMsg500Union
*
)
CopyData
;
if
(
p500
!=
(
void
*
)
0
)
{
p500
->
Sig
.
Key_ISTOP
=
Auto_Start_Stop
;
//
p500->Sig.Key_ISTOP = Auto_Start_Stop;
p500
->
Msg
[
1
]
=
0x00
;
p500
->
Msg
[
2
]
=
0x00
;
p500
->
Msg
[
3
]
=
0x00
;
...
...
Firmware/Source/Application/CAN_User/Can_App.h
View file @
3fa98a0d
...
...
@@ -26,7 +26,7 @@ typedef union
void
Can_Set_Buff_500
(
canlib_uint8_t
CopyData
[]);
#endif
Firmware/Source/Application/GUI_Display/GUI_Display.c
View file @
3fa98a0d
...
...
@@ -31,7 +31,7 @@ void Gauge_Clock_Display(void)
{
PageType_DIS
=
Get_Current_PageType
();
LED_Driver_Channel_Set
(
LampChannel_0
,
LampCh0_06_Screen_Time
,
100
);
//
LED_Driver_Channel_Set(LampChannel_0, LampCh0_06_Screen_Time, 100);
if
(
PageType_DIS
==
1
)
{
...
...
@@ -64,7 +64,7 @@ void Gauge_Clock_Display(void)
else
{
SEG_SET_Clock
(
0
,
0
,
0
,
0
,
0
);
LED_Driver_Channel_Set
(
LampChannel_0
,
LampCh0_06_Screen_Time
,
0
);
//
LED_Driver_Channel_Set(LampChannel_0, LampCh0_06_Screen_Time, 0);
}
}
...
...
@@ -151,16 +151,16 @@ void Gauge_Service(void)
else
{
Clear_Bu98
();
RTE_GPIO_Set_Level
(
VSPEED_TEN_OUT
,
0
);
RTE_GPIO_Set_Level
(
VSPEED_HUNDREDS_OUT
,
0
);
LED_Driver_Channel_Set
(
LampChannel_0
,
LampCh0_29_MPH
,
0
);
LED_Driver_Channel_Set
(
LampChannel_0
,
LampCh0_30_KM_H
,
0
);
LED_Driver_Channel_Set
(
LampChannel_0
,
LampCh0_07_Key_ISTOP
,
0
);
LED_Driver_Channel_Set
(
LampChannel_0
,
LampCh0_02_Normal_Voltage
,
0
);
LED_Driver_Channel_Set
(
LampChannel_0
,
LampCh0_03_High_Low_Voltage
,
0
);
LED_Driver_Channel_Set
(
LampChannel_0
,
LampCh0_04_Fuel_W
,
0
);
LED_Driver_Channel_Set
(
LampChannel_0
,
LampCh0_05_Fuel_Y
,
0
);
LED_Driver_Channel_Set
(
LampChannel_0
,
LampCh0_06_Screen_Time
,
0
);
//
RTE_GPIO_Set_Level(VSPEED_TEN_OUT, 0);
//
RTE_GPIO_Set_Level(VSPEED_HUNDREDS_OUT, 0);
//
LED_Driver_Channel_Set(LampChannel_0, LampCh0_29_MPH, 0);
//
LED_Driver_Channel_Set(LampChannel_0, LampCh0_30_KM_H, 0);
//
LED_Driver_Channel_Set(LampChannel_0, LampCh0_07_Key_ISTOP, 0);
//
LED_Driver_Channel_Set(LampChannel_0, LampCh0_02_Normal_Voltage, 0);
//
LED_Driver_Channel_Set(LampChannel_0, LampCh0_03_High_Low_Voltage, 0);
//
LED_Driver_Channel_Set(LampChannel_0, LampCh0_04_Fuel_W, 0);
//
LED_Driver_Channel_Set(LampChannel_0, LampCh0_05_Fuel_Y, 0);
//
LED_Driver_Channel_Set(LampChannel_0, LampCh0_06_Screen_Time, 0);
}
}
else
...
...
@@ -193,16 +193,16 @@ void Gauge_Service(void)
else
{
Clear_Bu98
();
RTE_GPIO_Set_Level
(
VSPEED_TEN_OUT
,
0
);
RTE_GPIO_Set_Level
(
VSPEED_HUNDREDS_OUT
,
0
);
LED_Driver_Channel_Set
(
LampChannel_0
,
LampCh0_29_MPH
,
0
);
LED_Driver_Channel_Set
(
LampChannel_0
,
LampCh0_30_KM_H
,
0
);
LED_Driver_Channel_Set
(
LampChannel_0
,
LampCh0_07_Key_ISTOP
,
0
);
LED_Driver_Channel_Set
(
LampChannel_0
,
LampCh0_02_Normal_Voltage
,
0
);
LED_Driver_Channel_Set
(
LampChannel_0
,
LampCh0_03_High_Low_Voltage
,
0
);
LED_Driver_Channel_Set
(
LampChannel_0
,
LampCh0_04_Fuel_W
,
0
);
LED_Driver_Channel_Set
(
LampChannel_0
,
LampCh0_05_Fuel_Y
,
0
);
LED_Driver_Channel_Set
(
LampChannel_0
,
LampCh0_06_Screen_Time
,
0
);
//
RTE_GPIO_Set_Level(VSPEED_TEN_OUT, 0);
//
RTE_GPIO_Set_Level(VSPEED_HUNDREDS_OUT, 0);
//
LED_Driver_Channel_Set(LampChannel_0, LampCh0_29_MPH, 0);
//
LED_Driver_Channel_Set(LampChannel_0, LampCh0_30_KM_H, 0);
//
LED_Driver_Channel_Set(LampChannel_0, LampCh0_07_Key_ISTOP, 0);
//
LED_Driver_Channel_Set(LampChannel_0, LampCh0_02_Normal_Voltage, 0);
//
LED_Driver_Channel_Set(LampChannel_0, LampCh0_03_High_Low_Voltage, 0);
//
LED_Driver_Channel_Set(LampChannel_0, LampCh0_04_Fuel_W, 0);
//
LED_Driver_Channel_Set(LampChannel_0, LampCh0_05_Fuel_Y, 0);
//
LED_Driver_Channel_Set(LampChannel_0, LampCh0_06_Screen_Time, 0);
}
}
...
...
Firmware/Source/Application/SEG_DISPLAY/SEG_DISPLAY.c
View file @
3fa98a0d
...
...
@@ -1618,20 +1618,20 @@ _Fun_Res SEG_SET_VSpeed_NUM(uint8_t m_Flag, uint16_t m_NUM)
uint8_t
m8
;
if
(
m_NUM
>
9
)
{
RTE_GPIO_Set_Level
(
VSPEED_TEN_OUT
,
1
);
//
RTE_GPIO_Set_Level(VSPEED_TEN_OUT, 1);
}
else
{
RTE_GPIO_Set_Level
(
VSPEED_TEN_OUT
,
0
);
//
RTE_GPIO_Set_Level(VSPEED_TEN_OUT, 0);
}
if
(
m_NUM
>
99
)
{
RTE_GPIO_Set_Level
(
VSPEED_HUNDREDS_OUT
,
1
);
//
RTE_GPIO_Set_Level(VSPEED_HUNDREDS_OUT, 1);
}
else
{
RTE_GPIO_Set_Level
(
VSPEED_HUNDREDS_OUT
,
0
);
//
RTE_GPIO_Set_Level(VSPEED_HUNDREDS_OUT, 0);
}
if
((
m_Flag
>
2u
)
||
(
m_NUM
>
299u
))
...
...
@@ -1647,7 +1647,7 @@ _Fun_Res SEG_SET_VSpeed_NUM(uint8_t m_Flag, uint16_t m_NUM)
IC1_SEG059
=
IC_SEG_ON
;
IC1_SEG058
=
IC_SEG_ON
;
LED_Driver_Channel_Set
(
LampChannel_0
,
LampCh0_29_MPH
,
100
);
LED_Driver_Channel_Set
(
LampChannel_0
,
LampCh0_30_KM_H
,
100
);
//
LED_Driver_Channel_Set(LampChannel_0, LampCh0_30_KM_H, 100);
}
else
{
...
...
@@ -1656,7 +1656,7 @@ _Fun_Res SEG_SET_VSpeed_NUM(uint8_t m_Flag, uint16_t m_NUM)
IC1_SEG059
=
IC_SEG_ON
;
IC1_SEG058
=
IC_SEG_ON
;
LED_Driver_Channel_Set
(
LampChannel_0
,
LampCh0_29_MPH
,
100
);
LED_Driver_Channel_Set
(
LampChannel_0
,
LampCh0_30_KM_H
,
100
);
//
LED_Driver_Channel_Set(LampChannel_0, LampCh0_30_KM_H, 100);
}
else
{
...
...
@@ -1665,14 +1665,14 @@ _Fun_Res SEG_SET_VSpeed_NUM(uint8_t m_Flag, uint16_t m_NUM)
IC1_SEG059
=
IC_SEG_OFF
;
IC1_SEG058
=
IC_SEG_ON
;
LED_Driver_Channel_Set
(
LampChannel_0
,
LampCh0_29_MPH
,
100
);
LED_Driver_Channel_Set
(
LampChannel_0
,
LampCh0_30_KM_H
,
0
);
//
LED_Driver_Channel_Set(LampChannel_0, LampCh0_30_KM_H, 0);
}
else
{
IC1_SEG059
=
IC_SEG_ON
;
IC1_SEG058
=
IC_SEG_OFF
;
LED_Driver_Channel_Set
(
LampChannel_0
,
LampCh0_29_MPH
,
0
);
LED_Driver_Channel_Set
(
LampChannel_0
,
LampCh0_30_KM_H
,
100
);
//
LED_Driver_Channel_Set(LampChannel_0, LampCh0_30_KM_H, 100);
}
}
}
...
...
@@ -3132,16 +3132,16 @@ void Check_SEG_Display(void)
SEG_SET_LED_STS
(
1
,
1
);
SEG_SET_LED_STS
(
2
,
1
);
LED_Driver_Channel_Set
(
LampChannel_0
,
LampCh0_07_Key_ISTOP
,
LED_ON
);
LED_Driver_Channel_Set
(
LampChannel_0
,
LampCh0_02_Normal_Voltage
,
LED_ON
);
LED_Driver_Channel_Set
(
LampChannel_0
,
LampCh0_03_High_Low_Voltage
,
LED_ON
);
LED_Driver_Channel_Set
(
LampChannel_0
,
LampCh0_05_Fuel_Y
,
LED_ON
);
LED_Driver_Channel_Set
(
LampChannel_0
,
LampCh0_04_Fuel_W
,
LED_ON
);
LED_Driver_Channel_Set
(
LampChannel_0
,
LampCh0_06_Screen_Time
,
LED_ON
);
LED_Driver_Channel_Set
(
LampChannel_0
,
LampCh0_29_MPH
,
LED_ON
);
LED_Driver_Channel_Set
(
LampChannel_0
,
LampCh0_30_KM_H
,
LED_ON
);
RTE_GPIO_Set_Level
(
VSPEED_TEN_OUT
,
1
);
RTE_GPIO_Set_Level
(
VSPEED_HUNDREDS_OUT
,
1
);
//
LED_Driver_Channel_Set(LampChannel_0, LampCh0_07_Key_ISTOP, LED_ON);
//
LED_Driver_Channel_Set(LampChannel_0, LampCh0_02_Normal_Voltage, LED_ON);
//
LED_Driver_Channel_Set(LampChannel_0, LampCh0_03_High_Low_Voltage, LED_ON);
//
LED_Driver_Channel_Set(LampChannel_0, LampCh0_05_Fuel_Y, LED_ON);
//
LED_Driver_Channel_Set(LampChannel_0, LampCh0_04_Fuel_W, LED_ON);
//
LED_Driver_Channel_Set(LampChannel_0, LampCh0_06_Screen_Time, LED_ON);
//
LED_Driver_Channel_Set(LampChannel_0, LampCh0_29_MPH, LED_ON);
//
LED_Driver_Channel_Set(LampChannel_0, LampCh0_30_KM_H, LED_ON);
//
RTE_GPIO_Set_Level(VSPEED_TEN_OUT, 1);
//
RTE_GPIO_Set_Level(VSPEED_HUNDREDS_OUT, 1);
SEG_Scan_SET_FuelDial
();
SEG_Scan_SET_EspeedDial
();
...
...
Firmware/Source/Component/Key/Key_user.c
View file @
3fa98a0d
...
...
@@ -86,14 +86,14 @@ Key_Status_en_t Key_Status_Read_Left(void)
Key_Status_en_t
enKeyReal
=
KEY_REALTIME_LOOSEN
;
if
(
SYS_OPR_STAT_IGN_ON
)
{
if
(
RTE_GPIO_Get_Level
(
MODE_P_IN
))
{
enKeyReal
=
KEY_REALTIME_LOOSEN
;
}
else
{
enKeyReal
=
KEY_REALTIME_PRESS
;
}
//
if (RTE_GPIO_Get_Level(MODE_P_IN))
//
{
//
enKeyReal = KEY_REALTIME_LOOSEN;
//
}
//
else
//
{
//
enKeyReal = KEY_REALTIME_PRESS;
//
}
}
return
enKeyReal
;
}
...
...
@@ -102,14 +102,14 @@ Key_Status_en_t Key_Status_Read_Right(void)
Key_Status_en_t
enKeyReal
=
KEY_REALTIME_LOOSEN
;
if
(
SYS_OPR_STAT_IGN_ON
)
{
if
(
RTE_GPIO_Get_Level
(
SET_P_IN
))
{
enKeyReal
=
KEY_REALTIME_LOOSEN
;
}
else
{
enKeyReal
=
KEY_REALTIME_PRESS
;
}
//
if (RTE_GPIO_Get_Level(SET_P_IN))
//
{
//
enKeyReal = KEY_REALTIME_LOOSEN;
//
}
//
else
//
{
//
enKeyReal = KEY_REALTIME_PRESS;
//
}
}
return
enKeyReal
;
}
...
...
@@ -285,7 +285,7 @@ void Key_Left_Long_Press(void)
{
if
((
PageType
==
Page_Time
)
&&
(
Key_Status_Read_Right
()
==
KEY_REALTIME_LOOSEN
))
{
Telltales_Auto_Start_Stop_Setting
();
//
Telltales_Auto_Start_Stop_Setting();
}
}
...
...
Firmware/Source/Component/Line_In/Line_In_user.c
View file @
3fa98a0d
...
...
@@ -101,7 +101,7 @@ Linelib_uint8_t Get_LINE_IN_Oil_Pressure(void)
Linelib_uint8_t
Get_LINE_IN_Auto_Start_Stop
(
void
)
{
Linelib_uint8_t
ret
=
0U
;
if
(
RTE_GPIO_Get_Level
(
START_STOP_P
_IN
))
if
(
RTE_GPIO_Get_Level
(
Auto_StartStop
_IN
))
{
ret
=
1u
;
}
...
...
Firmware/Source/Component/Line_In/Line_In_user.h
View file @
3fa98a0d
...
...
@@ -12,6 +12,8 @@ typedef enum
LINE_IN_Fault_ABS
,
LINE_IN_Oil_Pressure
,
LINE_IN_Auto_Start_Stop
,
LINE_IN_MAX
,
}
LINE_IN_Enum_t
;
extern
void
LINE_IN_Init
(
void
);
...
...
Firmware/Source/Component/PowerManagement/PowerManag_user.c
View file @
3fa98a0d
...
...
@@ -69,7 +69,7 @@ static void Power_KL30_Init(void)
TimerM_PWM_CH_Output_init
(
TIMERM_COUNTER0
,
TIMERM_CHC
,
ActiveLevel_High
);
TimerM_PWM_CH_Output_init
(
TIMERM_COUNTER0
,
TIMERM_CHD
,
ActiveLevel_High
);
TimerM_PWM_CH_Output_init
(
TIMERM_COUNTER1
,
TIMERM_CHB
,
ActiveLevel_High
);
Telltales_Auto_Start_Stop
();
Telltales_Init
();
MenuData_Unit_Init
();
g_stRTCInformation
.
u8RTCSecond
=
0
;
...
...
@@ -139,7 +139,7 @@ static void Power_IG_ON_Init(void)
Line_In_KL15_ON_Init
();
Telltales_KL15_Init
();
Fuel_KL15_Init
();
Telltales_Auto_Start_Stop
();
}
static
void
Power_Sleep_Init
(
void
)
...
...
Firmware/Source/Component/Telltales/Telltales_user.c
View file @
3fa98a0d
This diff is collapsed.
Click to expand it.
Firmware/Source/Component/Telltales/Telltales_user.h
View file @
3fa98a0d
...
...
@@ -5,20 +5,33 @@
typedef
enum
{
em_LED_High_Beam
,
em_LED_Efi_Fault
,
em_LED_FAULT_ELECTROSPRAY
,
em_LED_ABS
,
em_LED_Oil_Pressure
,
em_LED_Fuel
,
em_LED_Coolant
,
em_LED_Bluetooth
,
em_LED_TCS
,
em_LED_Auto_Start_Stop
,
em_LED_Voltage
,
em_LED_Fuel
,
em_LED_Atmosphere
,
em_LED_Keys
,
em_LED_Maintain
,
em_LED_Low_Batt_Vol
,
em_LED_Lateral_Strut
,
em_LED_Tire_Pressure_Alarm
,
em_LED_Navigator
,
LED_Max
,
}
LED_Idx_t
;
extern
Tellib_uint8_t
Auto_Start_Stop
;
typedef
struct
{
Tellib_uint8_t
LED_Turnon
;
Tellib_uint8_t
LED_Turnoff
;
}
Led_HighBeam_Count
;
extern
Led_HighBeam_Count
HighBeam_Timer
;
void
Telltales_Init
(
void
);
void
Telltales_Auto_Start_Stop
(
void
);
void
Telltales_Auto_Start_Stop_Setting
(
void
);
Tellib_uint8_t
Telltales_Voltage_Date
(
void
);
#endif
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment