Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
H
haoJin750TFT
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
时昊
haoJin750TFT
Commits
1095238b
Commit
1095238b
authored
Aug 17, 2024
by
郑萍
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
🐞
fix:56272 【豪进7500TFT】【小计】小计里程不能清零&54865 【豪进750TFT】【按键】通过按键无法切换大小计里程
parent
a99874fa
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
4 deletions
+8
-4
Key_user.c
Firmware/Source/Component/Key/Key_user.c
+4
-0
Services_Mileage_User.c
Firmware/Source/Component/Mileage/Services_Mileage_User.c
+4
-4
No files found.
Firmware/Source/Component/Key/Key_user.c
View file @
1095238b
...
...
@@ -21,6 +21,10 @@ void Key_Operation_Left(Key_Event_en_t enKeyEvent)//选择
case
KEY_EVENT_SHORT_PRESS_2
:
break
;
case
KEY_EVENT_LONG_PRESS_1
:
//2
if
(
Get_Dis_OdoAndTrip
()
==
1
)
{
Data_Clear_Trip
(
1
);
}
break
;
case
KEY_EVENT_LONG_PRESS_2
:
//3
break
;
...
...
Firmware/Source/Component/Mileage/Services_Mileage_User.c
View file @
1095238b
...
...
@@ -218,15 +218,15 @@ uint32_t Get_Trip_Value(void)
uint32_t
Trip
=
0
;
if
(
Get_Dis_Unit
()
==
0
)
/* 公制 */
{
Trip
=
Data_Read_Trip
(
EM_TRIP_
A
);
Trip
=
Data_Read_Trip
(
EM_TRIP_
B
);
}
else
if
(
Get_Dis_Unit
()
==
1
)
/* 英制 */
{
Trip
=
Data_Km_To_Mile
(
Data_Read_Trip
(
EM_TRIP_
A
));
Trip
=
Data_Km_To_Mile
(
Data_Read_Trip
(
EM_TRIP_
B
));
}
else
/* 无效值,按照公里处理,理论上不会执行到这 */
{
Trip
=
Data_Read_Trip
(
EM_TRIP_
A
);
Trip
=
Data_Read_Trip
(
EM_TRIP_
B
);
}
return
Trip
;
}
...
...
@@ -239,7 +239,7 @@ void Trip_Clear_Km_Service(void)
{
if
(
Get_Dis_Unit
()
==
0
)
/* 公制 */
{
if
(
Data_Read_Trip
(
EM_TRIP_
A
)
>
9999
)
/* 当前单位在KM时,里程大于999.9KM进行清零 */
if
(
Data_Read_Trip
(
EM_TRIP_
B
)
>
9999
)
/* 当前单位在KM时,里程大于999.9KM进行清零 */
{
Data_Clear_Trip_All
();
}
...
...
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