1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
#include "Can_App.h"
void Can_Set_Buff_500(canlib_uint8_t CopyData[])
{
CANMsg500Union *p500;
uint8_t i = 0;
for (i = 0; i < 8; i++)
{
CopyData[i] = 0xFFU;
}
p500 = (CANMsg500Union *)CopyData;
if (p500 != (void *)0)
{
p500->Sig.Key_ISTOP = 1;
p500->Msg[1] = 0x00;
p500->Msg[2] = 0x00;
p500->Msg[3] = 0x00;
p500->Msg[4] = 0x00;
p500->Msg[5] = 0x00;
p500->Msg[6] = 0x00;
p500->Msg[7] = 0x00;
}
}
void Can_Set_Buff_3A2(canlib_uint8_t CopyData[])
{
CANMsg3A2Union *p3A2;
uint8_t i = 0;
for (i = 0; i < 8; i++)
{
CopyData[i] = 0xFFU;
}
p3A2 = (CANMsg3A2Union *)CopyData;
if (p3A2 != (void *)0)
{
p3A2->Sig.ICU_POWERStateFB = 1;
p3A2->Sig.ICU_KL15State = 1;
p3A2->Sig.ICU_LEDLightState = 1;
p3A2->Sig.ICU_BuzzerState = 1;
p3A2->Sig.ICU_IndicatorLightState = 1;
p3A2->Sig.ICU_IndicatorLightPowerState = 1;
p3A2->Sig.ICU_GrassFullState = 1;
p3A2->Sig.ICU_kEY_AState = 1;
p3A2->Sig.ICU_kEY_BState = 1;
p3A2->Sig.ICU_kEY_CState = 1;
p3A2->Sig.ICU_kEY_DState = 1;
p3A2->Sig.ICU_kEY_EState = 1;
p3A2->Sig.ICU_BluetoothConnectState = 1;
p3A2->Msg[4] = 0x00;
p3A2->Msg[5] = 0x00;
p3A2->Msg[6] = 0x00;
p3A2->Msg[7] = 0x00;
}
}
void Can_Set_Buff_3A7(canlib_uint8_t CopyData[])
{
CANMsg3A7Union *p3A7;
uint8_t i = 0;
for (i = 0; i < 8; i++)
{
CopyData[i] = 0xFFU;
}
p3A7 = (CANMsg3A7Union *)CopyData;
if (p3A7 != (void *)0)
{
p3A7->Sig.ICU_MasterBMSCommunicatlost = 1;
p3A7->Sig.ICU_SlaveBMSCommunicatlost = 1;
p3A7->Sig.ICU_MCUCommunicatlost = 1;
p3A7->Sig.ICU_VCUCommunicatlost = 1;
p3A7->Msg[1] = 0x00;
p3A7->Msg[2] = 0x00;
p3A7->Msg[3] = 0x00;
p3A7->Msg[4] = 0x00;
p3A7->Msg[5] = 0x00;
p3A7->Msg[6] = 0x00;
p3A7->Msg[7] = 0x00;
}
}