This book details the use of the Arduino Uno and the Raspberry Pi 4 in practical CAN bus based projects. Using either the Arduino Uno or the Raspberry Pi with off-the-shelf CAN bus interface modules considerably ease developing, debugging, and testing CAN bus based projects.
This book is written for students, practicing engineers, enthusiasts, and for everyone else wanting to learn more about the CAN bus and its applications. The book assumes that the reader has some knowledge of basic electronics. Knowledge of the C and Python programming languages and programming the Arduino Uno using its IDE and Raspberry Pi will be useful, especially if the reader intends to develop microcontroller-based projects using the CAN bus.
The book should be a useful source of reference material for anyone interested in finding answers to questions such as:
What bus systems are available for the automotive industry?
What are the principles of the CAN bus?
How can I create a physical CAN bus?
What types of frames (or data packets) are available in a CAN bus system?
How can errors be detected in a CAN bus system and how dependable is a CAN bus system?
What types of CAN bus controllers exist?
How do I use the MCP2515 CAN bus controller?
How do I create 2-node Arduino Uno-based CAN bus projects?
How do I create 3-node Arduino Uno-based CAN bus projects?
How do I set the acceptance masks and acceptance filters?
How do I analyze data on the CAN bus?
How do I create 2-node Raspberry Pi-based CAN bus projects?
How do I create 3-node Raspberry Pi-based CAN bus projects?
Projects with Arduino Uno & Raspberry Pi with Examples for the MCP2515 CAN Bus Interface Module This book details the use of the Arduino Uno and the Raspberry Pi 4 in practical CAN bus based projects. Using either the Arduino Uno or the Raspberry Pi with off-the-shelf CAN bus interface modules considerably ease developing, debugging, and testing CAN bus based projects. This book is written for students, practicing engineers, enthusiasts, and for everyone else wanting to learn more about the CAN bus and its applications. The book assumes that the reader has some knowledge of basic electronics. Knowledge of the C and Python programming languages and programming the Arduino Uno using its IDE and Raspberry Pi will be useful, especially if the reader intends to develop microcontroller-based projects using the CAN bus. The book should be a useful source of reference material for anyone interested in finding answers to questions such as: What bus systems are available for the automotive industry? What are the principles of the CAN bus? How can I create a physical CAN bus? What types of frames (or data packets) are available in a CAN bus system? How can errors be detected in a CAN bus system and how dependable is a CAN bus system? What types of CAN bus controllers exist? How do I use the MCP2515 CAN bus controller? How do I create 2-node Arduino Uno-based CAN bus projects? How do I create 3-node Arduino Uno-based CAN bus projects? How do I set the acceptance masks and acceptance filters? How do I analyze data on the CAN bus? How do I create 2-node Raspberry Pi-based CAN bus projects? How do I create 3-node Raspberry Pi-based CAN bus projects?
The USB-CAN-FD is an industrial-grade high-performance USB to CAN-FD adapter, CAN/CAN-FD bus communication interface card, and CAN/CAN-FD protocol data analyzer. Onboard dual independent CAN-FD interfaces with electrical isolation and multiple protection circuits. Supports Windows system, comes with drivers, CAN-FD Tools related software, secondary development examples, and tutorials. It can be connected to the PC or industrial control host via a USB port to realize transceiver control, data analysis, collection and monitoring of CAN/CAN-FD bus network. It is compact in size and easy to use, which can be used for learning and debugging of CAN/CAN-FD bus, as well as for secondary development and integration into various industrial, power communication, and intelligent control applications that require CAN/CAN-FD bus communication. Specifications Product type Industrial grade: USB to CAN-FD interface converter, CAN/CAN-FD bus communication interface card, CAN/CAN-FD protocol data analyzer USB Operating voltage 5 V (directly powered by USB port without external power supply) Connector USB-B CAN/CAN FD interface CAN/CAN FD channel Dual-channel: CAN1 and CAN2 (independent and full-isolated, isolated voltage: 3000 V DC) Connector CAN bus screw terminal (OPEN6 5.08 mm pitch) Terminal resistor Each CAN/CAN-FD channel has two built-in 120Ω terminal resistors, which can be enabled by switch Baud Rate 100Kbps~5Mbps (configurable via software) Protocol Support CAN2.0A, CAN2.0B, and ISO 11898-1 CAN-FD protocol V.1.0 Transfer speed The receiving and sending speed of each CAN/CAN-FD channel can reach 20000 frames/s and 5000 frames/s Transmit buffer 1500 frames receiving buffer and 64 frames sending buffer per channel (automatically retransmit when the transmission fails) Indicators PWR Power indicator SYS System status indicator, normally off; keeps on when there is a bus error CAN1 CAN1 channel indicator (blinking when sending and receiving data) CAN2 CAN2 channel indicator (blinking when sending and receiving data) System support Windows Windows XP/7/8/10/11 (32/64 bits); Does Not support the Linux system now, and the related drivers are under development. Operating temperature −40 to +85°C Case material Aluminum alloy case + 3D flame-retardant insulating sheets on both sides (This design can provide better protection against metal tip discharge, also improves product safety, and extends service life) Dimensions 104 x 70 x 25 mm Included Waveshare USB-CAN-FD USB-A to USB-B cable 4-pin cable Screwdriver Downloads Wiki
This Grove CAN-BUS Module based on GD32E103 adopts a brand-new design, uses the cost-effective and high-performance GD32E103 microcontroller as the main control and cooperates with a firmware we wrote to complete the function of the serial port to CAN FD. Features
Support CAN communication: Implements CAN FD at up to 5 Mb/s
Easy to program: Support AT command which enables simple serial port programming
Grove ecosystem: 20 x 40 x 10 mm small size, 4-pin Grove connector to plug and play, Arduino compatible This Grove CAN-BUS Module supports CAN FD(CAN with Flexible Data-Rate) communication, which is an extension to the original CAN protocol as specified in ISO 11898-1 that responds to increased bandwidth requirements in automotive networks. In CAN FD, the data rate (i.e. number of bits transmitted per second) is increased to be 5 times faster than the classic CAN (5 Mbit/s for the data payload only, the arbitration bit rate is still limited to 1Mbit/s for compatibility). It supports AT command which enables simple serial port programming. This Grove CAN-BUS Module is based on GD32E103 with a frequency up to 120 MHz. It has a flash size from 64 KB to 128 KB and an SRAM size from 20 KB to 32 KB. Applications Car hacking: allows different parts of the vehicle to talk to each other, including the engine, the transmission, and the brakes. Windows, doors, and mirror adjustment. 3D Printers Building automation Lighting control systems Medical instruments and equipment Specifications MCU GD32E103 UART baud rate Up to 115200 (default 9600) CAN FD baud rate Up to 5 Mb/s Indicator TX and RX led Working voltage 3.3 V Grove connector 4-pin Grove connector to plug and play Size 20 x 40 x 10 mm Downloads Datasheet GitHub
Features Implements CAN V2.0B at up to 1 Mb/s Industrial standard 9 pin sub-D connector OBD-II and CAN standard pinout selectable. Changeable chip select pin Changeable CS pin for TF card slot Changeable INT pin Screw terminal that easily to connect CAN_H and CAN_L Arduino Uno pin headers Micro SD card holder 2 Grove connectors (I2C and UART) SPI Interface up to 10 MHz Standard (11 bit) and extended (29 bit) data and remote frames Two receive buffers with prioritized message storage
This PiCAN 2 board provides CAN-Bus capability for the Raspberry Pi 2/3. It uses the Microchip MCP2515 CAN controller with MCP2551 CAN transceiver. Connection are made via DB9 or 3-way screw terminal. This board includes a switch mode power suppler that powers the Raspberry Pi is well.
Easy to install SocketCAN driver. Programming can be done in C or Python.
Not suitable for Raspberry Pi 4, please use PiCAN 3 instead.
Features
CAN v2.0B at 1 Mb/s
High speed SPI Interface (10 MHz)
Standard and extended data and remote frames
CAN connection via standard 9-way sub-D connector or screw terminal
Compatible with OBDII cable
Solder bridge to set different configuration for DB9 connector
120Ω terminator ready
Serial LCD ready
LED indicator
Foot print for two mini push buttons
Four fixing holes, comply with Pi Hat standard
SocketCAN driver, appears as can0 to application
Interrupt RX on GPIO25
5 V/1 A SMPS to power Raspberry Pi and accessories from DB9 or screw terminal
Reverse polarity protection
High efficiency switch mode design
6-20 V input range
Optional fixing screws – select at bottom of this webpage
Downloads
User guide
Schematic Rev B
Writing your own program in Python
Python3 examples in Github
Features ATmega32U4 with Arduino Leonardo bootloader on the board MCP2515 CAN Bus controller and MCP2551 CAN Bus transceiver OBD-II and CAN standard pinout selectable at the sub-D connector Compatible with Arduino IDE Parameter Value MCU ATmega32U4(with Arduino Leonardo bootloader) Clock Speed 16 MHz Flash Memory 32 KB SRAM 2.5 KB EEPROM 1 KB Operate Voltage(CAN-BUS) 9 V - 28 V Operate Voltage (MicroUSB) 5 V Input Interface sub-D Included CANBed PCBA sub-D connector 4PIN Terminal 2 x 4PIN 2.0 Connector 1 x 9x2 2.54 Header 1 x 3x2 2.54 Header
This PiCAN2 Duo board provides two independent CAN-Bus channels for the Raspberry Pi 4. It uses the Microchip MCP2515 CAN controller with MCP2551 CAN transceiver. Connections are made via 4-way screw terminal. This board has a 5 V/3 A SMPS that can power the Raspberry Pi is well via the screw terminal.p
Easy to install SocketCAN driver. Programming can be done in C or Python.
Features
CAN v2.0B at 1 Mb/s
High speed SPI Interface (10 MHz)
Standard and extended data and remote frames
CAN connection screw terminal
120 Ω terminator ready
Serial LCD ready
LED indicator
Four fixing holes, comply with Pi Hat standard
SocketCAN driver, appears as can0 and can1 to application
Interrupt RX on GPIO25 and GPIO24
5 V/3 A SMPS to power Raspberry Pi and accessories from screw terminal
Reverse polarity protection
High efficiency switch mode design
7-24 V input range
Downloads
User guide
Schematic Rev D
Writing your own program in Python
Python3 examples in Github
This PiCAN3 board provides CAN-Bus capability for the Raspberry Pi 4. It uses the Microchip MCP2515 CAN controller with MCP2551 CAN transceiver. Connection are made via DB9 or 3-way screw terminal. This board includes a switch mode power suppler that powers the Raspberry Pi is well.
Easy to install SocketCAN driver. Programming can be done in C or Python.
Features
CAN v2.0B at 1 Mb/s
High speed SPI Interface (10 MHz)
Standard and extended data and remote frames
CAN connection via standard 9-way sub-D connector or screw terminal
Compatible with OBDII cable
Solder bridge to set different configuration for DB9 connector
120Ω terminator ready
Serial LCD ready
LED indicator
Four fixing holes, comply with Pi Hat standard
SocketCAN driver, appears as can0 to application
Interrupt RX on GPIO25
5 V/3 A SMPS to power Raspberry Pi and accessories from DB9 or screw terminal
Reverse polarity protection
High efficiency switch mode design
6-24 V input range
Optional fixing screws – select at bottom of this webpage
RTC with battery backup (battery not included, requires CR1225 cell)
Downloads
User guide
Schematic
Driver installation
Writing your own program in Python
Python3 examples
Mastering the I²C Bus takes you on an exploratory journey of the I²C Bus and its applications. Besides the Bus protocol, plenty of attention is given to the practical applications and designing a stable system. The most common I²C compatible chip classes are covered in detail.
Two experimentation boards are available that allow for rapid prototype development. These boards are completed by a USB to I²C probe and a software framework to control I²C devices from your computer. All samples programs can be downloaded from the 'Attachments/Downloads' section on this page.
Projects built on Board 1:
USB to I²C Interface, PCA 9534 Protected Input, PCA 9534 Protected Output, PCA 9553 PWM LED Controller, 24xxx EEPROM Module, LM75 Temperature Sensor, PCA8563 Real-time Clock with Battery Backup, LCD and Keyboard Module, Bus Power Supply.
Projects built on Board 2:
Protected Input, Protected Output, LM75 Temperature Sensor, PCF8574 I/O Board, SAA1064 LED Display, PCA9544 Bus Expander, MCP40D17 Potentiometer, PCF8591 AD/DA, ADC121 A/D Converter, MCP4725 D/A Converter, 24xxx EEPROM Module.
This CAN Module is based on the CAN bus controller MCP2515 and CAN transceiver TJA1050. With this module, you will easy to control any CAN Bus device by SPI interface with your MCU, such as Arduino Uno and so on. Features Support CAN V2.0B Communication rate up to 1 MB/s Working Voltage: 5 V Working Current: 5 mA Interface: SPI Downloads MCP2515 Datasheet TJA1050 Datasheet
The short-wave technique has a very particular appeal: It can easily bridge long distances. By reflecting short-wave signals off the conductive layers of the ionosphere, they can be received in places beyond the horizon and therefore can reach anywhere on earth. Although technology is striving for ever higher frequencies, and radio is usually listened to on FM, DAB+, satellite or the Internet, modern means of transmission require extensive infrastructure and are extremely vulnerable. In the event of a global power outage, there is nothing more important than the short-wave. Amateur radio is not only a hobby, it’s also an emergency radio system!
Elektor’s SDR-Shield is a versatile shortwave receiver up to 30 MHz. Using an Arduino and the appropriate software, radio stations, morse signals, SSB stations, and digital signals can be received.
In this book, successful author and enthusiastic radio amateur, Burkhard Kainka describes the modern practice of software defined radio using the Elektor SDR Shield. He not only imparts a theoretical background but also explains numerous open source software tools.