12
Appendix
:
GCAN-203 data flow definition
Bluetooth
→
CAN-bus data flow definition
A CAN frame contains 13 bytes.
CAN frame
,
For example, type or length of the CAN frame, and so on.
BIT7 BIT0
FF
:
Identifier for standard and extended frames, 1 means extended frame
,
0 means
Standard frame.
RTR
:
Remote frame and data frame identification bit, 1means extended frame
,
0
means Standard frame.
Reserve
:
Retention value is always 0.
B3
~
B0
:
Data length. Identifying the data length of the CAN frame.
Frame ID. Its length is 4 bytes. Standard frame’s ID has 11 bits; extended
frame’s ID has 29bits.
High byte Low byte High byte Low byte
Representation of extended frame ID Representation of standard frame ID
0X12345678 0X123
Frame data. Its length is 8 bytes. The effective length is determined by the
B3~B0 value of the frame information.
DATA1 DATA8
11h
22h
33h
44h
55h
66h
77h
88h
The above is a typical representation of data, which has 8 bytes.
DATA1 DATA8
The above is a typical representation of data, which has 5 bytes.
Example
:
The following example is an extended data frame, Frame ID is 0x12345678
,
Contains 8 bytes of data.
(
11h,22h,33h,44h,55h,66h,77h,88h
)
.
Note: each frame is fixed to 13 bytes. If it is less than 13, the empty parts will be
written with 0. Otherwise it will lead to communication error.
FF
RTR
Reserve
Reserve
B3
B2
B1
B0
12h
34h
56h
78h
00h
00h
01h
23h
11h
22h
33h
44h
55h
00h
00h
00h
88h
12h
34h
56h
78h
11h
22h
33h
44h
55h
66h
77h
88h