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
7f5b2cd0
Commit
7f5b2cd0
authored
Sep 06, 2024
by
王金亮
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'dev' of
http://tyw-server.synology.me:12345/shihao/haojin750tft
into wjl_devlop
parents
36322f83
a2684129
Changes
9
Show whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
142 additions
and
103 deletions
+142
-103
BlueTooth.c
Firmware/Source/Application/BlueTooth.c
+15
-9
BlueTooth.h
Firmware/Source/Application/BlueTooth.h
+8
-2
Data_ESpeed.c
Firmware/Source/Application/Data_ESpeed.c
+20
-20
Data_VSpeed.c
Firmware/Source/Application/Data_VSpeed.c
+18
-8
AMT630H_Datas.c
Firmware/Source/Component/AMT630H/AMT630H_Datas.c
+71
-58
PicBin.c
Firmware/Source/Component/AMT630H/PicBin.c
+1
-1
PicBin.h
Firmware/Source/Component/AMT630H/PicBin.h
+6
-2
Key_user.c
Firmware/Source/Component/Key/Key_user.c
+2
-2
Sys_Task_List.c
Firmware/Source/System/Sys_Task_List.c
+1
-1
No files found.
Firmware/Source/Application/BlueTooth.c
View file @
7f5b2cd0
...
...
@@ -10,12 +10,9 @@ uint8_t SetUUIDTimes = 0;
_PICID_Struct
PicObj
;
_QRCODE_RECT
QRCode_Rect
;
const
uint8_t
HJBlueToothName
[
9
]
=
{
"HJ750"
};
uint8_t
UUIDConfigBuf
[
22
]
=
{
0xff
,
0xff
,
0xff
,
0xff
,
0xff
,
0xff
,
0xff
,
0xff
,
0xff
,
0xff
,
0xff
,
0xff
,
0xff
,
0xff
,
0xff
,
0xff
,
0xff
,
0xff
,
0xff
,
0xff
,
0xff
,
0x00
};
uint8_t
UUIDConfigBuf
[
22
]
=
{
"800082024071700000001"
};
// 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00
// uint8_t sjhja[20] = {0};
// uint8_t PhoneName[100] = {0};
// uint8_t BlueConnectStatus;
// ee_uint16_t juasfha;
void
TextService
(
void
);
...
...
@@ -54,9 +51,18 @@ void BlueToothService()
Menu_Change_Branch_To_Item
(
MENU_BRANCH_ANIMATION
,
MENU_ITEM_MAIN_ITEM
);
}
SetUUIDData
((
char
*
)
UUIDConfigBuf
,
22
);
if
(
OTA_Update_Flag
==
1
)
{
QRCode_Rect
.
x
=
650
;
QRCode_Rect
.
y
=
210
;
}
else
{
QRCode_Rect
.
x
=
QRCode_X
;
QRCode_Rect
.
y
=
QRCode_Y
;
}
// QRCode_Rect.x = 650;
// QRCode_Rect.y = 210;
QRCode_Rect
.
height
=
240
;
QRCode_Rect
.
width
=
240
;
SetScreenType
(
QRCode_TYPE
,
QRCode_Rect
);
...
...
@@ -82,7 +88,7 @@ void BlueToothService()
}
OTA_Update_Count_Open
=
0
;
}
//
SetTaskbarHeight(150);
SetTaskbarHeight
(
150
);
SetBlueToothName
((
uint8_t
*
)
HJBlueToothName
,
sizeof
(
HJBlueToothName
));
TextService
();
...
...
Firmware/Source/Application/BlueTooth.h
View file @
7f5b2cd0
...
...
@@ -23,9 +23,12 @@ typedef struct {
uint16_t
Vaild
;
}
TEXT_STRUCT
;
/*QRCode X Y height Width*/
#define QRCode_X
457
#define QRCode_Y 13
4
#define QRCode_X
178
#define QRCode_Y 13
0
#define QRCode_HEIGHT 240
#define QRCode_WIDTH 240
#define QRCode_TYPE Square_Instrument
...
...
@@ -34,5 +37,8 @@ typedef struct {
extern
void
BlueToothService
(
void
);
extern
_PICID_Struct
PicObj
;
extern
_QRCODE_RECT
QRCode_Rect
;
extern
uint8_t
PhoneNumber
[
40
];
extern
uint8_t
CurBlueToothPhoneName
[
100
];
extern
TEXT_STRUCT
TextPara
[];
#endif
\ No newline at end of file
Firmware/Source/Application/Data_ESpeed.c
View file @
7f5b2cd0
...
...
@@ -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
)
...
...
Firmware/Source/Application/Data_VSpeed.c
View file @
7f5b2cd0
...
...
@@ -321,12 +321,22 @@ void Data_Vehicle_Speed_Processing_Service(void)
}
// 第3步:生成显示车速
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*/
...
...
Firmware/Source/Component/AMT630H/AMT630H_Datas.c
View file @
7f5b2cd0
...
...
@@ -3143,33 +3143,57 @@ static void AMT630H_GUI_PhoneConnect_TIME(uint16_t Hour ,uint16_t Minute)
*/
static
void
AMT630H_GUI_Telephone
()
{
//if((TextPara[TEXT_NUM_BLUETOOTH_PHONENAME].Vaild == 0X01)||(TextPara[TEXT_NUM_PHONE_NUMBER].Vaild == 0X01))
if
(
BlueToothPhoneData
.
BlueToothPhoneSate
==
Phone_Outgoing
)
{
//SetPagePic(GRAPHICS_PAGE_0, );
SetPagePic
(
GRAPHICS_PAGE_0
,
Pic_0939_62_401
);
if
(
TextPara
[
TEXT_NUM_BLUETOOTH_PHONENAME
].
Vaild
==
0X01
)
{
PackedTransfer_LabelsList
(
0x4007
,(
uint8_t
*
)
CurBlueToothPhoneName
,
40
);
SetPageText
(
GRAPHICS_PAGE_0
,
0x4007
,
200
,
200
,
200
,
ALIGN_LEFT
,
0
,
TEXT_COLOR
(
0XFF
,
0
,
0
,
0XFF
),
TEXT_LINE_OFFSET
(
1
,
1
));
}
if
(
TextPara
[
TEXT_NUM_PHONE_NUMBER
].
Vaild
==
0X01
)
{
PackedTransfer_LabelsList
(
0x4007
,(
uint8_t
*
)
PhoneNumber
,
40
);
SetPageText
(
GRAPHICS_PAGE_0
,
0x4007
,
200
,
200
,
200
,
ALIGN_LEFT
,
0
,
TEXT_COLOR
(
0XFF
,
0
,
0
,
0XFF
),
TEXT_LINE_OFFSET
(
1
,
1
));
}
}
else
if
(
BlueToothPhoneData
.
BlueToothPhoneSate
==
Phone_Talking
)
{
//SetPagePic(GRAPHICS_PAGE_0, );
SetPagePic
(
GRAPHICS_PAGE_0
,
Pic_0938_62_399
);
if
(
TextPara
[
TEXT_NUM_BLUETOOTH_PHONENAME
].
Vaild
==
0X01
)
{
PackedTransfer_LabelsList
(
0x4007
,(
uint8_t
*
)
CurBlueToothPhoneName
,
40
);
SetPageText
(
GRAPHICS_PAGE_0
,
0x4007
,
200
,
200
,
200
,
ALIGN_LEFT
,
0
,
TEXT_COLOR
(
0XFF
,
0
,
0
,
0XFF
),
TEXT_LINE_OFFSET
(
1
,
1
));
}
if
(
TextPara
[
TEXT_NUM_PHONE_NUMBER
].
Vaild
==
0X01
)
{
PackedTransfer_LabelsList
(
0x4007
,(
uint8_t
*
)
PhoneNumber
,
40
);
SetPageText
(
GRAPHICS_PAGE_0
,
0x4007
,
200
,
200
,
200
,
ALIGN_LEFT
,
0
,
TEXT_COLOR
(
0XFF
,
0
,
0
,
0XFF
),
TEXT_LINE_OFFSET
(
1
,
1
));
}
}
else
if
(
BlueToothPhoneData
.
BlueToothPhoneSate
==
Phone_Incoming
)
{
SetPagePic
(
GRAPHICS_PAGE_0
,
Pic_0548_62_401
);
if
(
TextPara
[
TEXT_NUM_BLUETOOTH_PHONENAME
].
Vaild
==
0X01
)
{
PackedTransfer_LabelsList
(
0x4007
,(
uint8_t
*
)
CurBlueToothPhoneName
,
40
);
SetPageText
(
GRAPHICS_PAGE_0
,
0x4007
,
200
,
200
,
200
,
ALIGN_LEFT
,
0
,
TEXT_COLOR
(
0XFF
,
0
,
0
,
0XFF
),
TEXT_LINE_OFFSET
(
1
,
1
));
}
if
(
TextPara
[
TEXT_NUM_PHONE_NUMBER
].
Vaild
==
0X01
)
{
PackedTransfer_LabelsList
(
0x4007
,(
uint8_t
*
)
PhoneNumber
,
40
);
SetPageText
(
GRAPHICS_PAGE_0
,
0x4007
,
200
,
200
,
200
,
ALIGN_LEFT
,
0
,
TEXT_COLOR
(
0XFF
,
0
,
0
,
0XFF
),
TEXT_LINE_OFFSET
(
1
,
1
));
}
}
else
{
;
}
uint8_t
*
BLUETOOTH_PHONENAME
=
(
uint8_t
*
)
TEXT_NUM_BLUETOOTH_PHONENAME
;
uint8_t
*
PHONE_NUMBER
=
(
uint8_t
*
)
TEXT_NUM_PHONE_NUMBER
;
/*联系人*/
PackedTransfer_LabelsList
(
0x4007
,
BLUETOOTH_PHONENAME
,
22
);
SetPageText
(
GRAPHICS_PAGE_0
,
0x4007
,
200
,
200
,
200
,
ALIGN_LEFT
,
0
,
TEXT_COLOR
(
0XFF
,
0XFF
,
0XFF
,
0XFF
),
TEXT_LINE_OFFSET
(
1
,
1
));
/*手机号码*/
PackedTransfer_LabelsList
(
0x4009
,
PHONE_NUMBER
,
22
);
SetPageText
(
GRAPHICS_PAGE_0
,
0x4009
,
200
,
200
,
200
,
ALIGN_LEFT
,
0
,
TEXT_COLOR
(
0XFF
,
0XFF
,
0XFF
,
0XFF
),
TEXT_LINE_OFFSET
(
1
,
1
));
}
/*
*NAME : AMT630H_GUI_Fuel
*FUNCTION : 燃油显示函数
...
...
@@ -4179,6 +4203,7 @@ void AMT630H_GUI_BACKGRAND()
AMT630H_GUI_Light
();
AMT630H_GUI_TIME
(
Get_Dis_Hour_Time
(),
Get_Dis_Minute_Time
());
AMT630H_GUI_Telephone
();
/*燃油*/
if
(
Get_Fuel_Sensor_State
()
==
FuelSensorNormal
)
{
...
...
@@ -4207,7 +4232,7 @@ void AMT630H_GUI_BACKGRAND()
{
AMT630H_GUI_Trip
(
Get_Trip_Value
(),
Get_Dis_Unit
());
}
if
(
0
)
if
(
VechileSpeed_time
<
4
)
{
VechileSpeed_time
++
;
}
...
...
@@ -4217,23 +4242,9 @@ void AMT630H_GUI_BACKGRAND()
VechileSpeed
=
Get_DispVechileSpeed
()
/
10
;
}
if
(
Get_VechileSpeedValid
()
==
1
)
{
AMT630H_GUI_VSpeed
(
VechileSpeed
);
}
else
{
AMT630H_GUI_VSpeed
(
0
);
}
/*转速*/
if
(
Get_EngineValid
()
==
1
)
{
AMT630H_GUI_ESpeed
(
Get_DispEngineSpeed
());
}
else
{
AMT630H_GUI_ESpeed
(
0
);
}
}
...
...
@@ -4459,7 +4470,6 @@ void AMT630H_GUI_DisplayProc(void)
PackedTransfer_Page
();
}
void
AMT630H_GUI_ReadPosittion_Display
(
void
)
{
switch
(
g_u8Cursor_Posittion
)
...
...
@@ -4629,20 +4639,23 @@ void AMT630H_GUI_ReadPosittion_Display(void)
AMT630H_GUI_Phone_Connect_Win
();
break
;
case
MENU_ITEM_PHONE_CONNECT_APP
:
// PicObj.qr_logo_id = Pic_0234;//小数字9
// PicObj.main_pic_id = Pic_0382; //大白背景图
// PicObj.qr_pic_id = Pic_0479;//小数字0
// PicObj.update_pic_id = Pic_0233;//小数字8
// PicObj.second_menu = 0;
// PicObj.navigation_task_id = Pic_0411;//红色小e
// PackedTransfer_DisplayPhoneMirrorQRcode(1, PicObj);
// SetPagePic(GRAPHICS_PAGE_0, Pic_0001_0_0);
// SetPagePic(GRAPHICS_PAGE_0, Pic_0476_0_0);
// SetPagePic(GRAPHICS_PAGE_0, Pic_0477_178_130);
// SetPagePic(GRAPHICS_PAGE_0, Pic_0234_605_289);
// SetPagePic(GRAPHICS_PAGE_0, Pic_0479_242_313);
// SetPagePic(GRAPHICS_PAGE_0, Pic_0411_56_533);
SetPagePic
(
GRAPHICS_PAGE_0
,
Pic_0382_0_0
);
/*背景图*/
PicObj
.
qr_logo_id
=
0
;
//Pic_0234 小数字9 EA
PicObj
.
main_pic_id
=
Pic_0382
;
//大白背景图 17E
PicObj
.
qr_pic_id
=
Pic_0479
;
//小数字0 1DF
PicObj
.
update_pic_id
=
Pic_0233
;
//小数字8 E9
PicObj
.
second_menu
=
0
;
PicObj
.
navigation_task_id
=
Pic_0411
;
//红色小e 19B
if
(
GetPhoneMirrorst
()
==
0
)
{
SetPagePic
(
GRAPHICS_PAGE_0
,
Pic_0001_0_0
);
SetPagePic
(
GRAPHICS_PAGE_0
,
Pic_0476_0_0
);
PackedTransfer_DisplayPhoneMirrorQRcode
(
1
,
PicObj
);
}
else
{
PackedTransfer_DisplayPhoneMirrorQRcode
(
0
,
PicObj
);
}
SetPagePic
(
GRAPHICS_PAGE_0
,
Pic_0479_242_313
);
// SetPagePic(GRAPHICS_PAGE_0, Pic_0382_0_0);/*背景图*/
AMT630H_GUI_PhoneConnect_Light
();
AMT630H_GUI_PhoneConnect_TIME
(
Get_Dis_Hour_Time
(),
Get_Dis_Minute_Time
());
AMT630H_GUI_PhoneConnect_VSpeed
(
VechileSpeed
);
...
...
Firmware/Source/Component/AMT630H/PicBin.c
View file @
7f5b2cd0
...
...
@@ -118,7 +118,7 @@ static const uint16_t PicIndexData[] = {
Pic_0910
,
13
,
639
,
293
,
Pic_0911
,
17
,
636
,
292
,
Pic_0912
,
13
,
639
,
293
,
Pic_0913
,
17
,
636
,
292
,
Pic_0914
,
13
,
638
,
293
,
Pic_0915
,
16
,
636
,
293
,
Pic_0916
,
11
,
640
,
293
,
Pic_0917
,
14
,
639
,
293
,
Pic_0899
,
11
,
638
,
293
,
Pic_0918
,
3
,
643
,
293
,
Pic_0898
,
14
,
637
,
293
,
Pic_0897
,
15
,
637
,
292
,
Pic_0919
,
11
,
640
,
293
,
Pic_0920
,
12
,
639
,
293
,
Pic_0921
,
14
,
638
,
293
,
Pic_0922
,
14
,
638
,
292
,
Pic_0923
,
14
,
638
,
293
,
Pic_0924
,
15
,
637
,
293
,
Pic_0925
,
221
,
501
,
160
,
Pic_0926
,
50
,
619
,
240
,
Pic_0926
,
50
,
619
,
175
,
Pic_0927
,
50
,
619
,
240
,
Pic_0927
,
50
,
619
,
175
,
Pic_0928
,
75
,
894
,
310
,
Pic_0929
,
75
,
894
,
310
,
Pic_0930
,
64
,
612
,
240
,
Pic_0930
,
64
,
612
,
175
,
Pic_0931
,
64
,
612
,
240
,
Pic_0931
,
64
,
612
,
175
,
Pic_0932
,
777
,
124
,
85
,
Pic_0933
,
317
,
101
,
210
,
Pic_0934
,
209
,
102
,
260
,
Pic_0935
,
461
,
36
,
367
,
Pic_0936
,
350
,
92
,
367
,
Pic_0937
,
323
,
564
,
521
,
Pic_0933
,
317
,
101
,
210
,
Pic_0934
,
209
,
102
,
260
,
Pic_0935
,
461
,
36
,
367
,
Pic_0936
,
350
,
92
,
367
,
Pic_0937
,
323
,
564
,
521
,
Pic_0938
,
41
,
62
,
399
,
Pic_0939
,
41
,
62
,
401
,
};
#define PicIndexData_LEN 14888
//uint32_t PicIndexDataLEN = 0;
...
...
Firmware/Source/Component/AMT630H/PicBin.h
View file @
7f5b2cd0
#ifndef PICBIN_H
#define PICBIN_H
/* Flash Bin Version:20240
828 2024-08-28 15:55:32
Compression ratio:70.00% */
/* Flash Bin Version:20240
902 2024-09-02 13:18:34
Compression ratio:70.00% */
#define Pic_0001 1
#define Pic_0002 2
#define Pic_0003 3
...
...
@@ -939,6 +939,8 @@
#define Pic_0935 935
#define Pic_0936 936
#define Pic_0937 937
#define Pic_0938 938
#define Pic_0939 939
enum
{
Pic_0001_0_0
=
0
,
...
...
@@ -2121,9 +2123,11 @@ enum {
Pic_0935_36_367
,
Pic_0936_92_367
,
Pic_0937_564_521
,
Pic_0938_62_399
,
Pic_0939_62_401
,
};
#define PIC_INDEX_DATA_CRC 0x
D0B47BE
6
#define PIC_INDEX_DATA_CRC 0x
53F47F4
6
extern
void
User_PicIndexDataInit
(
void
);
#endif
Firmware/Source/Component/Key/Key_user.c
View file @
7f5b2cd0
...
...
@@ -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
(
7
000U
);
Key_Parameter_Set_Long_Press_1_Time
(
2
000U
);
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
(
7
000U
);
Key_Parameter_Set_Long_Press_1_Time
(
2
000U
);
Key_Parameter_Set_Long_Press_2_Time
(
8000U
);
Key_Parameter_Set_Long_Press_3_Time
(
9000U
);
Key_Parameter_Set_Long_Press_4_Time
(
10000U
);
...
...
Firmware/Source/System/Sys_Task_List.c
View file @
7f5b2cd0
...
...
@@ -20,7 +20,7 @@ void Sys_2ms_Tasks(void)
Sys_Status_Update_Service
();
Analog_Signal_Conv_Service
();
AMT630H_Main
();
Check_MCU_Info_in_630H
();
//
Check_MCU_Info_in_630H();
DoCAN_Timer_Update
(
2000u
);
//Can_Write_Fun(&CAN_CH0_CanMsgTxOp, 2000u);无外发
CanMSg_XMS_Analysis
(
&
CAN_CH0_CanMsgOp
,
2u
);
...
...
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