Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
R
RT_RMR42E
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
时昊
RT_RMR42E
Commits
6c520d78
Commit
6c520d78
authored
Mar 01, 2025
by
李冠华
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
🐞
fix:修改累计工作时长从E方获取后被改的问题
parent
6c0643c3
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
12 additions
and
3 deletions
+12
-3
CAN_CH0_CAN_Communication_Matrix.c
...ce/Application/CAN_APP/CAN_CH0_CAN_Communication_Matrix.c
+1
-1
Can_RX_User.c
Firmware/Source/Application/CAN_User/Can_RX_User.c
+4
-0
Can_RX_User.h
Firmware/Source/Application/CAN_User/Can_RX_User.h
+1
-0
Data_Time.c
Firmware/Source/Application/Driving_Information/Data_Time.c
+5
-2
Data_Time.h
Firmware/Source/Application/Driving_Information/Data_Time.h
+1
-0
No files found.
Firmware/Source/Application/CAN_APP/CAN_CH0_CAN_Communication_Matrix.c
View file @
6c520d78
...
@@ -556,7 +556,7 @@ const st_CANMsgAttribute CAN_CH0_CAN_MSG_CONST_ARRAY[CAN_CH0_ID_TOTAL_MAX] =
...
@@ -556,7 +556,7 @@ const st_CANMsgAttribute CAN_CH0_CAN_MSG_CONST_ARRAY[CAN_CH0_ID_TOTAL_MAX] =
20000ul
,
20000ul
,
0x339ul
,
0x339ul
,
((
void
*
)
0
),
((
void
*
)
0
),
(
(
void
*
)
0
),
(
CAN_0x339_Receive
),
((
void
*
)
0
),
((
void
*
)
0
),
},
},
{
{
...
...
Firmware/Source/Application/CAN_User/Can_RX_User.c
View file @
6c520d78
...
@@ -662,3 +662,7 @@ void CAN_0x170_Receive(uint8_t CopyData [])
...
@@ -662,3 +662,7 @@ void CAN_0x170_Receive(uint8_t CopyData [])
#endif
#endif
}
}
void
CAN_0x339_Receive
(
uint8_t
CopyData
[])
{
g_u8ID339flag
=
1U
;
}
Firmware/Source/Application/CAN_User/Can_RX_User.h
View file @
6c520d78
...
@@ -45,5 +45,6 @@ extern void CAN_0x220_Receive(uint8_t CopyData []);
...
@@ -45,5 +45,6 @@ extern void CAN_0x220_Receive(uint8_t CopyData []);
extern
void
CAN_0x16B_Receive
(
uint8_t
CopyData
[]);
extern
void
CAN_0x16B_Receive
(
uint8_t
CopyData
[]);
extern
void
CAN_0x22F_Receive
(
uint8_t
CopyData
[]);
extern
void
CAN_0x22F_Receive
(
uint8_t
CopyData
[]);
extern
void
CAN_0x170_Receive
(
uint8_t
CopyData
[]);
extern
void
CAN_0x170_Receive
(
uint8_t
CopyData
[]);
extern
void
CAN_0x339_Receive
(
uint8_t
CopyData
[]);
#endif
#endif
Firmware/Source/Application/Driving_Information/Data_Time.c
View file @
6c520d78
...
@@ -4,6 +4,7 @@
...
@@ -4,6 +4,7 @@
DataTimeStruct_st_t
Time
;
DataTimeStruct_st_t
Time
;
uint16_t
u16EngineTimeCount
;
uint16_t
u16EngineTimeCount
;
uint8_t
g_u8ID339flag
=
0U
;
void
Data_Time_KL30_Init
(
void
)
void
Data_Time_KL30_Init
(
void
)
{
{
...
@@ -13,6 +14,7 @@ void Data_Time_KL30_Init(void)
...
@@ -13,6 +14,7 @@ void Data_Time_KL30_Init(void)
Time
.
SingleValid
=
0U
;
Time
.
SingleValid
=
0U
;
Time
.
KeepTimeCount
=
0U
;
Time
.
KeepTimeCount
=
0U
;
u16EngineTimeCount
=
0U
;
u16EngineTimeCount
=
0U
;
g_u8ID339flag
=
0U
;
}
}
void
Data_Time_KL15_Init
(
void
)
void
Data_Time_KL15_Init
(
void
)
...
@@ -21,10 +23,11 @@ void Data_Time_KL15_Init(void)
...
@@ -21,10 +23,11 @@ void Data_Time_KL15_Init(void)
uint32_t
u32Data_read
[
1
]
=
{
0
};
uint32_t
u32Data_read
[
1
]
=
{
0
};
Time
.
KeepTimeCount
=
0U
;
Time
.
KeepTimeCount
=
0U
;
u16EngineTimeCount
=
0U
;
u16EngineTimeCount
=
0U
;
g_u8ID339flag
=
0U
;
#if (PART_NUMBER == G54_A01)
#if (PART_NUMBER == G54_A01)
for
(
uint8_t
i
=
0U
;
i
<
3U
;
i
++
)
for
(
uint8_t
i
=
0U
;
i
<
3U
;
i
++
)
{
{
eeprom_ReadRecord
(
EEPROM_BLOCK_00
,
(
uint8_t
*
)
u32Data_read
,
4
);
u16Result
=
eeprom_ReadRecord
(
EEPROM_BLOCK_00
,
(
uint8_t
*
)
u32Data_read
,
4
);
if
(
u16Result
==
0x2U
)
if
(
u16Result
==
0x2U
)
{
{
break
;
break
;
...
@@ -106,7 +109,7 @@ void Data_Time_Total_Working_Hours(void)
...
@@ -106,7 +109,7 @@ void Data_Time_Total_Working_Hours(void)
uint16_t
u16Result
=
0U
;
uint16_t
u16Result
=
0U
;
uint32_t
AccumulatedWorkHours
=
0U
;
uint32_t
AccumulatedWorkHours
=
0U
;
if
(
CAN_MSG_Status
(
&
CAN_CH0_CanMsgOp
,
Co_Can_ConvertSubID_CAN_CH0
(
CAN_CH0_ID_CAN_0x339_Msg
))
==
CAN_SIG_NORMAL
)
if
(
(
CAN_MSG_Status
(
&
CAN_CH0_CanMsgOp
,
Co_Can_ConvertSubID_CAN_CH0
(
CAN_CH0_ID_CAN_0x339_Msg
))
==
CAN_SIG_NORMAL
)
&&
(
g_u8ID339flag
==
1U
)
)
{
{
AccumulatedWorkHours
=
(
uint32_t
)
Get_CAN_CH0_ID_339_Sig_MMCU_AccumulatedWorkHours
();
AccumulatedWorkHours
=
(
uint32_t
)
Get_CAN_CH0_ID_339_Sig_MMCU_AccumulatedWorkHours
();
if
(
AccumulatedWorkHours
!=
Time
.
TotalHour
)
if
(
AccumulatedWorkHours
!=
Time
.
TotalHour
)
...
...
Firmware/Source/Application/Driving_Information/Data_Time.h
View file @
6c520d78
...
@@ -16,6 +16,7 @@ typedef struct //__attribute__((aligned(4)))
...
@@ -16,6 +16,7 @@ typedef struct //__attribute__((aligned(4)))
}
DataTimeStruct_st_t
;
}
DataTimeStruct_st_t
;
extern
uint8_t
g_u8ID339flag
;
extern
void
Data_Time_KL30_Init
(
void
);
extern
void
Data_Time_KL30_Init
(
void
);
extern
void
Data_Time_KL15_Init
(
void
);
extern
void
Data_Time_KL15_Init
(
void
);
...
...
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