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

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

parents 63456160 3acfc682
......@@ -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,11 @@
<FileType>5</FileType>
<FilePath>..\..\..\..\Source\Component\System_Monitor\System_Monitor_User.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>
</Files>
</Group>
<Group>
......
......@@ -23,6 +23,9 @@ typedef struct {
uint16_t Vaild;
}TEXT_STRUCT;
/*QRCode X Y height Width*/
#define QRCode_X 178
#define QRCode_Y 130
......@@ -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
......@@ -2972,7 +2972,7 @@ static void AMT630H_GUI_Light()
{
SetPagePic(GRAPHICS_PAGE_0, Pic_0737_875_23);
}
if(Get_TelltalesLedSts(em_LED_Bluetooth))
if(BlueToothPhoneData.BlueToothSignalSate == BlueTooth_Connection)
{
SetPagePic(GRAPHICS_PAGE_0, Pic_0740_682_21);
}
......@@ -3143,33 +3143,111 @@ static void AMT630H_GUI_PhoneConnect_TIME(uint16_t Hour ,uint16_t Minute)
*/
static void AMT630H_GUI_Telephone()
{
if(BlueToothPhoneData.BlueToothPhoneSate == Phone_Outgoing)
{
//SetPagePic(GRAPHICS_PAGE_0, );
}
else if(BlueToothPhoneData.BlueToothPhoneSate == Phone_Talking)
{
//SetPagePic(GRAPHICS_PAGE_0, );
}
else if(BlueToothPhoneData.BlueToothPhoneSate == Phone_Incoming)
{
SetPagePic(GRAPHICS_PAGE_0, Pic_0548_62_401);
if(BlueToothPhoneData.BlueToothSignalSate == BlueTooth_Connection)
{ if(BlueToothPhoneData.BlueToothPhoneSate == Phone_Outgoing)
{
SetPagePic(GRAPHICS_PAGE_0, Pic_0939_62_401);
if(g_u8Display_Mode == ModeDAY)
{
if(TextPara[TEXT_NUM_BLUETOOTH_PHONENAME].Vaild == 0X01)
{
PackedTransfer_LabelsList( 0x4022,(uint8_t *)CurBlueToothPhoneName, 40);
SetPageText(GRAPHICS_PAGE_0, 0x4022, 53, 463, 200, ALIGN_LEFT, 0, TEXT_COLOR(0,0,0,0XFF),TEXT_LINE_OFFSET(1,1));
}
if(TextPara[TEXT_NUM_PHONE_NUMBER].Vaild == 0X01)
{
PackedTransfer_LabelsList( 0x4009,(uint8_t *)PhoneNumber, 40);
SetPageText(GRAPHICS_PAGE_0, 0x4009, 54, 499, 200, ALIGN_LEFT, 0, TEXT_COLOR(0,0,0,0XFF),TEXT_LINE_OFFSET(1,1));
}
}
else if(g_u8Display_Mode == ModeNIGHT)
{
if(TextPara[TEXT_NUM_BLUETOOTH_PHONENAME].Vaild == 0X01)
{
PackedTransfer_LabelsList( 0x4022,(uint8_t *)CurBlueToothPhoneName, 40);
SetPageText(GRAPHICS_PAGE_0, 0x4022, 53, 463, 200, ALIGN_LEFT, 0, TEXT_COLOR(0XFF,0XFF,0XFF,0XFF),TEXT_LINE_OFFSET(1,1));
}
if(TextPara[TEXT_NUM_PHONE_NUMBER].Vaild == 0X01)
{
PackedTransfer_LabelsList( 0x4009,(uint8_t *)PhoneNumber, 40);
SetPageText(GRAPHICS_PAGE_0, 0x4009, 54, 499, 200, ALIGN_LEFT, 0, TEXT_COLOR(0XFF,0XFF,0XFF,0XFF),TEXT_LINE_OFFSET(1,1));
}
}
}
else if(BlueToothPhoneData.BlueToothPhoneSate == Phone_Talking)
{
SetPagePic(GRAPHICS_PAGE_0, Pic_0938_62_399);
if(g_u8Display_Mode == ModeDAY)
{
if(TextPara[TEXT_NUM_BLUETOOTH_PHONENAME].Vaild == 0X01)
{
PackedTransfer_LabelsList( 0x4022,(uint8_t *)CurBlueToothPhoneName, 40);
SetPageText(GRAPHICS_PAGE_0, 0x4022, 53, 463, 200, ALIGN_LEFT, 0, TEXT_COLOR(0,0,0,0XFF),TEXT_LINE_OFFSET(1,1));
}
if(TextPara[TEXT_NUM_PHONE_NUMBER].Vaild == 0X01)
{
PackedTransfer_LabelsList( 0x4009,(uint8_t *)PhoneNumber, 40);
SetPageText(GRAPHICS_PAGE_0, 0x4009, 54, 499, 200, ALIGN_LEFT, 0, TEXT_COLOR(0,0,0,0XFF),TEXT_LINE_OFFSET(1,1));
}
}
else if(g_u8Display_Mode == ModeNIGHT)
{
if(TextPara[TEXT_NUM_BLUETOOTH_PHONENAME].Vaild == 0X01)
{
PackedTransfer_LabelsList( 0x4022,(uint8_t *)CurBlueToothPhoneName, 40);
SetPageText(GRAPHICS_PAGE_0, 0x4022, 53, 463, 200, ALIGN_LEFT, 0, TEXT_COLOR(0XFF,0XFF,0XFF,0XFF),TEXT_LINE_OFFSET(1,1));
}
if(TextPara[TEXT_NUM_PHONE_NUMBER].Vaild == 0X01)
{
PackedTransfer_LabelsList( 0x4009,(uint8_t *)PhoneNumber, 40);
SetPageText(GRAPHICS_PAGE_0, 0x4009, 54, 499, 200, ALIGN_LEFT, 0, TEXT_COLOR(0XFF,0XFF,0XFF,0XFF),TEXT_LINE_OFFSET(1,1));
}
}
}
else if(BlueToothPhoneData.BlueToothPhoneSate == Phone_Incoming)
{
SetPagePic(GRAPHICS_PAGE_0, Pic_0548_62_401);
if(g_u8Display_Mode == ModeDAY)
{
if(TextPara[TEXT_NUM_BLUETOOTH_PHONENAME].Vaild == 0X01)
{
PackedTransfer_LabelsList( 0x4022,(uint8_t *)CurBlueToothPhoneName, 40);
SetPageText(GRAPHICS_PAGE_0, 0x4022, 53, 463, 200, ALIGN_LEFT, 0, TEXT_COLOR(0,0,0,0XFF),TEXT_LINE_OFFSET(1,1));
}
if(TextPara[TEXT_NUM_PHONE_NUMBER].Vaild == 0X01)
{
PackedTransfer_LabelsList( 0x4009,(uint8_t *)PhoneNumber, 40);
SetPageText(GRAPHICS_PAGE_0, 0x4009, 54, 499, 200, ALIGN_LEFT, 0, TEXT_COLOR(0,0,0,0XFF),TEXT_LINE_OFFSET(1,1));
}
}
else if(g_u8Display_Mode == ModeNIGHT)
{
if(TextPara[TEXT_NUM_BLUETOOTH_PHONENAME].Vaild == 0X01)
{
PackedTransfer_LabelsList( 0x4022,(uint8_t *)CurBlueToothPhoneName, 40);
SetPageText(GRAPHICS_PAGE_0, 0x4022, 53, 463, 200, ALIGN_LEFT, 0, TEXT_COLOR(0XFF,0XFF,0XFF,0XFF),TEXT_LINE_OFFSET(1,1));
}
if(TextPara[TEXT_NUM_PHONE_NUMBER].Vaild == 0X01)
{
PackedTransfer_LabelsList( 0x4009,(uint8_t *)PhoneNumber, 40);
SetPageText(GRAPHICS_PAGE_0, 0x4009, 54, 499, 200, ALIGN_LEFT, 0, TEXT_COLOR(0XFF,0XFF,0XFF,0XFF),TEXT_LINE_OFFSET(1,1));
}
}
}
else
{
;
}
}
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 +4257,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)
{
......
......@@ -61,6 +61,7 @@ extern void AMT630H_GUI_SELFCHECK_STS_INIT(void);
extern uint8_t g_u8Display_Mode;
extern uint8_t g_u8Display_Mode_select;
extern uint8_t g_u8SelfCheck;
......
......@@ -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;
......
#ifndef PICBIN_H
#define PICBIN_H
/* Flash Bin Version:20240828 2024-08-28 15:55:32 Compression ratio:70.00% */
/* Flash Bin Version:20240902 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 0xD0B47BE6
#define PIC_INDEX_DATA_CRC 0x53F47F46
extern void User_PicIndexDataInit(void);
#endif
......@@ -5,7 +5,7 @@
__align(4)
#define BACK_MENU_TIME 1000
#define BACK_MENU_TIME 800
_Menu_Data MenuData;
RTC_TimeTypeDef RTC_TimeStruct;
RTC_DateTypeDef RTC_DateStruct;
......@@ -385,6 +385,18 @@ void Get_DisTime_Service(void)
}
void My_Key_Service(void)
{
/* 自检时不可操作按键 */
if(g_u8SelfCheck)
{
if(Get_ActualVechileSpeed() == 0)
{
Key_Service();
}
}
}
uint8_t Get_Dis_Hour_Time(void)
{
return MenuData.u8Dis_Hour;
......
......@@ -77,6 +77,8 @@ uint8_t Get_Dis_Bluetooth_Open_Close(void);
uint8_t Get_Dis_Language(void);
void Get_DisTime_Service(void);
extern void My_Key_Service(void);
#endif
......@@ -395,6 +395,13 @@ void Menu_Logic_Operation_Clock_Hour_Tenb_Set(Menu_Key_en_t enKeyType)
datmax = 2u;
datmin = 0u;
Menu_u8Data_Updata_Process(updataDir, datmax, datmin, 1u, (uint8_t*)&(MenuData.Dis_Hour_Tenb));
if(MenuData.Dis_Hour_Tenb == 2U)
{
if(MenuData.Dis_Hour_Bit > 3U)
{
MenuData.Dis_Hour_Bit = 0U;
}
}
MenuData.u8Dis_Hour = (MenuData.Dis_Hour_Tenb*10 + MenuData.Dis_Hour_Bit);
MenuData.u8Dis_Minute = (MenuData.Dis_Minute_Tenb*10 + MenuData.Dis_Minute_Bit);
}
......
......@@ -137,6 +137,7 @@ static void Power_IG_ON_Init(void)
AMT630H_Animation_IGON();
// Amt630hInit();
AMT630H_GUI_SELFCHECK_STS_INIT();
Menu_Service(MENU_KEY_TIMEOUT); /* 菜单回到初始界面 */
}
static void Power_Sleep_Init(void)
......
......@@ -470,3 +470,41 @@ static void LED_E_Execution(Tellib_uint16_t led_status)
;
}
Tellib_uint8_t g_u8UDSreadprec = 0U;
Tellib_uint8_t g_u8UDSreadprec_flag = 0U;
Tellib_uint16_t g_u16UDSreadprec_time = 0U;
void UDS_Read_Preconditions(void)
{
if (g_u8UDSreadprec > 0)
{
g_u16UDSreadprec_time ++;
}
if(Get_TelltalesLedSts(em_LED_High_Beam))
{
if(g_u8UDSreadprec_flag == 0U)
{
g_u8UDSreadprec_flag = 1U;
}
}
else
{
if(g_u8UDSreadprec_flag == 1U)
{
g_u8UDSreadprec_flag = 0U;
if(g_u8UDSreadprec < 5U)
{
g_u8UDSreadprec++;
}
}
}
if(g_u8UDSreadprec < 5)
{
if(g_u16UDSreadprec_time > 100U)
{
g_u16UDSreadprec_time = 0U;
g_u8UDSreadprec = 0U;
}
}
}
......@@ -26,4 +26,9 @@ typedef enum
extern Tellib_uint8_t Auto_Start_Stop ;
void Telltales_Init(void);
Tellib_uint8_t Telltales_Voltage_Date(void);
extern Tellib_uint8_t g_u8UDSreadprec;
extern Tellib_uint16_t g_u16UDSreadprec_time;
extern void UDS_Read_Preconditions(void);
#endif
......@@ -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);
......@@ -35,7 +35,7 @@ void Sys_10ms_Tasks(void)
{
FaultCode_Service(10u);
Line_In_Debounce_Service(10u);
Key_Service();
My_Key_Service();
Data_Mileage_Write_EEPROM();
Key_Clear_Time();
Key_TimeOut_Service();
......@@ -54,6 +54,7 @@ void Sys_50ms_Tasks(void)
{
BackLight_Service();
Telltales_Management();
UDS_Read_Preconditions();
g_u8Cursor_Posittion = Menu_Get_Current_Cursor_Information();
......
......@@ -6,6 +6,7 @@
日 期:2016.11.1
******************************************************************************/
#include "UDS_ISO14229_Server.h"
#include "Telltales\Telltales_user.h"
UDS_APP_RX_Union UDS_APP_RX;
UDS_APP_TX_Union UDS_APP_TX;
......@@ -211,7 +212,11 @@ void UDS_Process_Service_Request(void)
{
case 0x10: UDS_Service_10_Indication(UDS_APP_RX.A_PDU.TA_type, UDS_APP_RX.A_PDU.Length, UDS_APP_RX.A_PDU.Data);
break;
case 0x22: UDS_Service_22_Indication(UDS_APP_RX.A_PDU.TA_type, UDS_APP_RX.A_PDU.Length, UDS_APP_RX.A_PDU.Data);
case 0x22:
if(g_u8UDSreadprec >= 5U)
{
UDS_Service_22_Indication(UDS_APP_RX.A_PDU.TA_type, UDS_APP_RX.A_PDU.Length, UDS_APP_RX.A_PDU.Data);
}
break;
/* case 0x2E: UDS_Service_2E_Indication(UDS_APP_RX.A_PDU.TA_type, UDS_APP_RX.A_PDU.Length, UDS_APP_RX.A_PDU.Data);
break;
......
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