CAN BUS SHIELD
CAN-BUS is a common industrial bus because of its long travel distance, medium communication speed and high reliability. It is commonly found on modern machine tools, such as an automotive diagnostic bus.
This CAN Bus Shield adopts MCP2515 CAN Bus controller with SPI interface and MCP2551 CAN transceiver to give your Arduino CAN Bus capability. With an OBD-II converter cable added on and the OBD-II library imported, you are ready to build an onboard diagnostic device or data logger.
For transportation considerations, the plug-in components of the kit are not soldered by default. After you receive the kit, you need to do some soldering work. If necessary, you can also contact email@example.com after purchasing the board, then we can send it to you after the board is soldered well.
CAN BUS PRODUCTS LIST OF LONGAN LABS¶
We have made a lot of can bus products, you can get more information through the following list, so as to choose a product suitable for you.
|Serial CAN Bus Module||LINK||$19.9||ATMEGA168PA||MCP2515||CAN2.0|
|I2C CAN Bus Module||LINK||$19.9||ATMEGA168PA||MCP2515||CAN2.0|
|OBD-II Serial CAN Bus Dev Kit||LINK||$20.9||ATMEGA168PA||MCP2515||CAN2.0|
|OBD-II CAN Bus GPS Dev Kit||LINK||$29.9||ATMEGA32U4||MCP2515||CAN2.0|
|OBD-II CAN Bus Basic Dev Kit||LINK||$24.9||ATMEGA32U4||MCP2515||CAN2.0|
|CAN-FD Shield||LINK||$12.9||NO MCU||MCP2517FD||CAN-FD|
|CAN Bus Shield||LINK||$5.9||NO MCU||MCP2515||CAN2.0|
|OBD-II RF Dev Kit||LINK||$19.9||ATmega168PA||MCP2515||CAN2.0|
- Implements CAN V2.0B speed up to 1 Mb/s
- Industrial standard 9 pin sub-D connector
- Standard (11 bit) and extended (29 bit) data and remote frames
- OBD-II and CAN standard pinout selectable.
- Changeable chip select pin
- Changeable CS pin for TF card slot
- Changeable INT pin
- Arduino Uno pin headers
CAN Bus Shield Work well with Arduino UNO (ATmega328), Arduino Mega (ATmega1280/2560) as well as Arduino Leonardo (ATmega32U4).
- CAN Bus Shield PCBA x 1
- 6 pin header x 1
- 8 pin header x 2
- 10 pin header x 1
- 2x3 pin header x 1
- 2 pin terminal x 1
- DB9 connector x 1
- Switch x 2
- DB9 Interface - to connect to OBDII Interface via a DBG-OBD Cable.
- V_OBD - It gets power from OBDII Interface (from DB9)
- Led Indicator:
- PWR: power
- TX: blink when the data is sending
- RX: blink when there's data receiving
- INT: data interrupt
- Terminal - CAN_H and CAN_L
- Arduino UNO R3 pin out
- ICSP pins
- SD card slot
- 120Ω terminal resistor switch
The DB9 interface of CAN Bus has two different protocols, OBD and CAN Open. Their definition is as follows,
If you want to use the OBD protocol, you don't need to make any changes to the hardware.
If you need to use the CAN Open protocol, first we look at the back side of the PCB board, you can see the Pads below,
The picture shows another board, but it doesn't matter, the operation method is the same.
These pads are connected to the OBD side by default. We have to prepare a knife to disconnect the OBD side, and then use an electric soldering iron to solder the CAN Open side of the pads.
- The FREE pin is available for the other usages.
Here's a simple example to show you how CAN-BUS Shield works. In this example we need 2 pieces of CAN-BUS Shields as well as Longan Core 01 (or others Arduino UNO like board).
This example is built under Arduino IDE version 1.8.10.
STEP1: What do we need
|CAN Bus Shield||CAN Bus communication||2||GET ONE NOW|
|Longan Core 01||Controller||2||GET ONE NOW|
STEP2: Hardware Connection
Insert each CAN-BUS Shield into Longan Core 01 (or others Arduino UNO like board), and connect the 2 CAN-BUS Shield together via 2 jumper wires. Shown as below images.
CAN_H to CAN_H, CAN_L to CAN_L
Please follow how to install an arduino library procedures to install CAN BUS shield library.
Click library for CAN Bus Shield to download the library.
Install the library to your Arduino IDE when it is downloaded.
One of the node (a node means Longan Core 01 + CAN_BUS Shield) acts as master, the other acts as slaver. The master will send data to slaver constantly.
Each node can act as master before the code being uploaded.
Open the send example (File > Examples > Longan_CAN_MCP2515 > send) and upload to the master.
Open the recv example (File > Examples > Longan_CAN_MCP2515 > recv) and upload to the slaver.
STEP4: View Result
Open the Serial Monitor of Arduino IDE(slaver), you will get the data sent from the master.