/18/2018 Serial CAN Bus - Longan Docs Serial CAN Bus Introduction [https://www.seeedstudio.com/Serial-CAN-BUS-Module-based-on-MCP2551-and-MCP2515-p-2924.html] The Serial CAN BUS provide your Arduino or others MCU with the capability to communication to CAN Bus, such as hacking your vehicle. CAN Bus is a common industrial bus because of its long travel distance, medium communication speed and high reliability.
1/18/2018 Serial CAN Bus - Longan Docs Features Uart to CAN Bus communication Work with Arduino/BeagleBone board/Pi or any MCU that integrated with Uart. AT command Up to 115200 Uart baud rate (default 9600) Up to 1Mb/s CAN Bus baud rate TX and RX led indicator 4pin Grove connector 3.3 / 5V working voltage Easy-to-use Arduino library Small size: 20x40 mm Hardware Overview http://docs.longan-labs.
1/18/2018 Serial CAN Bus - Longan Docs 1. 4 pin 2.0mm Grove Connector 2. Power and status led indicator 3. Send and Recv led indicator 4. 3.5mm terminal to connect to CAN Bus (CAN_H & CAN_L) 5. 120Ω registor, default connected, if you don't need you cut this pad with a box cutter. AT Command You can achieve the complete function of this Serial CAN Bus module with only a few AT command.
1/18/2018 Serial CAN Bus - Longan Docs You can set the serial baud rate of the module with this command. There're 5 rates available, up to 115200 b/s. AT+S=[value] value 0 1 2 3 4 baud rate(b/s) 9600 19200 38400 57600 115200 Note Default is 9600 Eg: Set serial baud rate to 57600 AT+S=3 Respose OK or ERROR Set CAN Bus Baudrate You can use this command to set the rate of CAN Bus, there's 18 rates available. Normally, if you want to hack your vehicle, 500k is the right one.
1/18/2018 Serial CAN Bus - Longan Docs There're 2 Mask for the module, Mask0 and Mask1. AT+M=[N][EXT][value] N: 0: Mask0 1: Mask1 EXT: 0: Standard Frame 1: Extended Frame value: Neeed 8 bit of character, hexadecimal.
1/18/2018 Serial CAN Bus - Longan Docs Eg: Set Filt3 to 0x2C, standard frame: AT+M=[1][0][0000002C] Respose OK or ERROR Normal Mode When the module working on Normal mode, you can send and recevie data from CAN Bus. Send You should send 14 byte of data per frame. De ne as below, bit 0 1 2 3 4 5 6 7 de ne ID3 ID2 ID1 ID0 EXT RTR DTA0 DTA1 ID0~ID3: CAN ID EXT: 0 for standard frame, 1 for extended frame RTR: 0 for standard frame, 1 for remote frame DTA0~DTA7: 8 byte of data Eg.
1/18/2018 Serial CAN Bus - Longan Docs Arduino Library We provide an library for Aruino Software Serial. Please download it at Github [https://github.com/Longan-Labs/Serial_CAN_Arduino] There're many examples for the library, which is consist of, send - How to send a frame to CAN Bus recv - How to recv a frame from CAN Bus debug - debug mode, you can send a cmd to the module set_can_baudrate - set can bus baudrate set_mask_ lt - set mask and lt of the module Reference Arduino Library [https://github.