4 Ejemplos
4.1 Conversión transparente
1. Puerto serie→CAN
GCAN-207 will send the serial data to CAN-Bus immediately if GCAN-207 receive the serial data.


Por ejemplo, los datos serie 11 22 33 44 55 66 77 88 se convierten en bus CAN. El ID de trama es la configuración de "发送标识符" que han establecido los usuarios. Los datos del fotograma son 11 22 33 44 55 66 77 88.
2. CAN→Puerto serie
GCAN-207 will send the CAN data to serial port immediately if GCAN-207 receive the CAN data.


E.g.:Check“允许CAN帧信息转发到串行帧中”and“允许CAN帧标识转发到串行帧中”which means the CAN frame information(帧信息) and the frame ID (帧标识)will display in the serial frame.
CAN frame is standard data frame. Frame ID is 00 01. Frame data is 11 22 33 44 55 66 77 88. GCAN-207 converts to Serial port. Serial data is 08 00 01 11 22 33 44 55 66 77 88.
4.2 Conversión transparente con identidad
Transparente con transformación de identidad es el uso especial de la conversión Transparente.
1. Puerto serie→CAN
Los usuarios pueden establecer la dirección de la posición de inicio y la longitud de la ID de la trama CAN en la configuración.
E.g.:If the CAN frame ID starting position address is 1, the length is 2 in the Serial frame.
Serial frame data is 01 23 33 44 55 66 77 88. GCAN-207 converts to CAN. CAN frame ID is 123, and frame data is 33 44 55 66 77 88.
2. CAN→Puerto serie
E.g.:If the CAN frame ID starting position address is 1, the length is 3 in the Serial frame(Extension frames). Conversion is shown as Figure below.


4.3 Format conversion
Each CAN frame of GCAN-207 contains 13 bytes, which include CAN frame information+ frame ID + frame data.
CAN frame    CAN frame    CAN frame    CAN frame    ……    CAN frame

FF:Standard frame and extended frame identification, 1 for extension frames, 0 for the standard frame.
RTR:Remote frame and data frame identification, 1 for remote frame, 0 for the data frame.
Reserve:Retains the value is 0.
D3~D0 :Data length, data which CAN frame length.


Note: Each frame is fixed on 13 bytes, insufficient must fill 0, otherwise will cause communication error.