# Raspberry Pi CM4 HAT
This page is not ready yet...
The board is designed for connecting CAN bus to Raspberry Pi. It gives access to Cyphal (opens new window)/DroneCAN (opens new window) (old name UAVCAN)
# 1. General
# 1.1. Variations
There are two connection options.
RPI CM4 | RPI4 Common |
---|---|
![]() | ![]() |
# 1.2. Main function
# 2. Hardware specification
# 2.1. Features
- CAN to RPI-SPI - MCP2515-I/ST
- FDCAN to RPI_SPI - MCP2517FD-H/SL
- FT1 - RPI_SDCARD
# 2.2. Wire
Connectors
№ | Name | Description |
---|---|---|
1 | CAN1, CAN2 | First CAN port |
2 | CAN3, CAN4 | Second CAN port |
3 | SWD | Serial wire debug from RPI to STM |
4 | DEBUG | SWD |
5 | STM-USB | |
6 | XT30PW-M | Power input |
7 | IR1 | InfraRed UART RX/TX |
8 | SERIAL1 | RPI ttyS0 |
9 | J8,J9 | Bottom connector slot |
10 | RPI1 | RPI4 header |
11 | J1,J2 | Compute Module 4 headers |
12 | RPI-USB | RPI USB Type-C |
13 | FT1 | SD CARD to extend memory of RPI |
14 | J5 | Ethernet RJ45 connected to RPI |
Pin configuration and functions
Pin configuration for RPI
GPIO | Defedition |
---|---|
GPIO25 | SWCLK |
GPIO24 | SWDIO |
GPIO18 | Green led |
GPIO15 | PI_RXI - STM_TX |
GPIO14 | PI_TXO - STM_RX |
GPIO10 | MCP2515_MOSI |
GPIO9 | MCP2515_MISO |
GPIO11 | MCP2515_SCK |
GPIO8 | MCP2515_nCS |
GPIO7 | MCP2515_nCS |
RPI UART map (opens new window)
TXD | RXD | CTS | RTS | Board | Pins | ||
---|---|---|---|---|---|---|---|
uart0 | 14 | 15 | 8 | 10 | |||
uart1 | 14 | 15 | 8 | 10 | |||
uart2 | 0 | 1 | 2 | 3 | 27 | 28 | (I2C) |
uart3 | 4 | 5 | 6 | 7 | 7 | 29 | |
uart4 | 8 | 9 | 10 | 11 | 24 | 21 | (SPI0) |
uart5 | 12 | 13 | 14 | 15 | 32 | 33 | (gpio-fan) |
# 2.3. Specifications
Mechanical
Width, mm | Length, mm | Height, mm | |
---|---|---|---|
Outline | |||
PCB |
Total weight of device is 6.6 g.
You can download 3D model on GrabCAD (opens new window)
Housing
Information about case presented here.
Absolute Maximum Ratings
Parameter | MIN | MAX | UNIT |
---|---|---|---|
Vin (CAN1) | 5.5 | 55* | V |
V (CAN2, CAN3) | 4.5 | 5.5 | V |
I max | A | ||
Operating temperature |
*Noted Voltage should be delivered only with current limitation under 2.5 Amp.
Recommended operating conditions
Parameter | Value | UNIT |
---|---|---|
Vin (CAN3) | 30 | V |
V (CAN1, CAN2) | 5 | V |
I max | A |
ESD ratings
Description | Value | UNIT |
---|---|---|
Human-body model (HBM) | 2000 | V |
Charged-device model (CDM) | 500 | V |
# 2.4. Description
Functional Block Diagram
Connection example diagram
# 2.5. Power Supply Recommendations
Device is designed to operate from an input voltage supply range between 4.5 V and 5.5 V over CAN2 or CAN3 connector, or 5.5 - 30 V from CAN1. This input supply must be able to withstand the maximum input current and maintain a stable voltage. The resistance of the input supply rail should be low enough that an input current transient does not cause a high enough drop that can cause a false UVLO fault triggering and system reset. The amount of bulk capacitance is not critical, but a 47-μF or 100-μF electrolytic capacitor is a typical choice.
# 2. Led indication
- LED1
- PI_LED_nPWR - RED
- GPIO18 - GREEN
- PI_nLED_Activity - BLUE
# Useful links:
- cm4io datasheet (opens new window)
- cm4 datasheet (opens new window)
- waveshare.com/cm4-nano-a.htm (opens new window)
- raspberrypi.stackexchange.com/questions/104464/where-are-the-uarts-on-the-raspberry-pi-4 (opens new window)
# Useful links about RPI:
# Inspired by
- waveshare.com/rs485-can-hat.htm (opens new window)
- waveshare.com/wiki/RS485_CAN_HAT (opens new window)
- waveshare.com/wiki/File:RS485_CAN_HAT_Schematic.pdf (opens new window)
# 2.6. Revision history
version | Description |
---|---|
v |