Cirkit Designer Logo
Cirkit Designer
Your all-in-one circuit design IDE
Home / 
Component Documentation

How to Use Adafruit CAN Pal Breakout: Examples, Pinouts, and Specs

Image of Adafruit CAN Pal Breakout
Cirkit Designer LogoDesign with Adafruit CAN Pal Breakout in Cirkit Designer

Introduction

The Adafruit CAN Pal Breakout (Manufacturer Part ID: 5708) is a compact and versatile breakout board designed for interfacing with CAN (Controller Area Network) devices. It features an onboard CAN transceiver, making it ideal for reliable communication in automotive, industrial, and embedded systems. The breakout simplifies the process of integrating CAN communication into your projects, offering a robust and user-friendly solution.

Explore Projects Built with Adafruit CAN Pal Breakout

Use Cirkit Designer to design, explore, and prototype these projects online. Some projects support real-time simulation. Click "Open Project" to start designing instantly!
Dual Raspberry Pi 2B CAN BUS Communication Interface with Pushbutton Interaction
Image of BSP4: A project utilizing Adafruit CAN Pal Breakout in a practical application
This circuit features two Raspberry Pi 2B microcontrollers connected to separate CAN BUS modules, forming a CAN network for data exchange. A pushbutton is included for user interaction, interfaced with GPIO pins on both Raspberry Pis.
Cirkit Designer LogoOpen Project in Cirkit Designer
Raspberry Pi Pico W CAN Bus Interface with USB-CAN Adapter
Image of can: A project utilizing Adafruit CAN Pal Breakout in a practical application
This circuit connects a Raspberry Pi Pico W microcontroller to a USB-CAN adapter, enabling the microcontroller to interface with a CAN bus. The connections include grounding the USB-CAN adapter and linking the CAN_H and CAN_L lines to the appropriate pins on the Raspberry Pi Pico W.
Cirkit Designer LogoOpen Project in Cirkit Designer
Wi-Fi Controlled Servo System with ESP32 and Arduino
Image of robosort vison system 2: A project utilizing Adafruit CAN Pal Breakout in a practical application
This circuit controls multiple servos using an Adafruit PCA9685 PWM Servo Breakout, which is powered by a 5V adapter and managed by an Arduino UNO. An ESP32-CAM and an IR sensor are also integrated, likely for remote control and obstacle detection functionalities.
Cirkit Designer LogoOpen Project in Cirkit Designer
Arduino Mega 2560 Controlled Servo Motor with IR Remote and PWM Control
Image of project: A project utilizing Adafruit CAN Pal Breakout in a practical application
This circuit consists of an Arduino Mega 2560 microcontroller interfaced with an Adafruit PCA9685 PWM Servo Breakout to control a servo motor. The Arduino communicates with the PWM breakout via I2C (SDA and SCL lines) and provides power and ground connections. The PWM breakout then controls the servo motor by providing the necessary pulse signals.
Cirkit Designer LogoOpen Project in Cirkit Designer

Explore Projects Built with Adafruit CAN Pal Breakout

Use Cirkit Designer to design, explore, and prototype these projects online. Some projects support real-time simulation. Click "Open Project" to start designing instantly!
Image of BSP4: A project utilizing Adafruit CAN Pal Breakout in a practical application
Dual Raspberry Pi 2B CAN BUS Communication Interface with Pushbutton Interaction
This circuit features two Raspberry Pi 2B microcontrollers connected to separate CAN BUS modules, forming a CAN network for data exchange. A pushbutton is included for user interaction, interfaced with GPIO pins on both Raspberry Pis.
Cirkit Designer LogoOpen Project in Cirkit Designer
Image of can: A project utilizing Adafruit CAN Pal Breakout in a practical application
Raspberry Pi Pico W CAN Bus Interface with USB-CAN Adapter
This circuit connects a Raspberry Pi Pico W microcontroller to a USB-CAN adapter, enabling the microcontroller to interface with a CAN bus. The connections include grounding the USB-CAN adapter and linking the CAN_H and CAN_L lines to the appropriate pins on the Raspberry Pi Pico W.
Cirkit Designer LogoOpen Project in Cirkit Designer
Image of robosort vison system 2: A project utilizing Adafruit CAN Pal Breakout in a practical application
Wi-Fi Controlled Servo System with ESP32 and Arduino
This circuit controls multiple servos using an Adafruit PCA9685 PWM Servo Breakout, which is powered by a 5V adapter and managed by an Arduino UNO. An ESP32-CAM and an IR sensor are also integrated, likely for remote control and obstacle detection functionalities.
Cirkit Designer LogoOpen Project in Cirkit Designer
Image of project: A project utilizing Adafruit CAN Pal Breakout in a practical application
Arduino Mega 2560 Controlled Servo Motor with IR Remote and PWM Control
This circuit consists of an Arduino Mega 2560 microcontroller interfaced with an Adafruit PCA9685 PWM Servo Breakout to control a servo motor. The Arduino communicates with the PWM breakout via I2C (SDA and SCL lines) and provides power and ground connections. The PWM breakout then controls the servo motor by providing the necessary pulse signals.
Cirkit Designer LogoOpen Project in Cirkit Designer

Common Applications and Use Cases

  • Automotive systems (e.g., ECU communication, diagnostics)
  • Industrial automation and control
  • Robotics and sensor networks
  • IoT devices requiring CAN communication
  • Data logging and monitoring systems

Technical Specifications

The Adafruit CAN Pal Breakout is built to meet the demands of modern CAN-based systems. Below are its key technical details:

Key Technical Details

  • Operating Voltage: 3.3V or 5V logic levels (selectable)
  • CAN Transceiver: MCP25625 (integrated CAN controller and transceiver)
  • Communication Protocol: SPI (Serial Peripheral Interface)
  • CAN Bus Speed: Up to 1 Mbps
  • Operating Temperature: -40°C to +125°C
  • Dimensions: 25.4mm x 25.4mm (1" x 1")
  • Mounting: Standard 0.1" header pins for breadboard compatibility

Pin Configuration and Descriptions

The breakout board features a total of 8 pins. Below is the pinout and description:

Pin Name Description
1 VIN Power input (3.3V or 5V). Supplies power to the board.
2 GND Ground connection.
3 SCK SPI Clock. Used for synchronizing data transfer.
4 MISO SPI Master-In-Slave-Out. Data sent from the CAN Pal to the microcontroller.
5 MOSI SPI Master-Out-Slave-In. Data sent from the microcontroller to the CAN Pal.
6 CS Chip Select. Used to enable communication with the CAN Pal.
7 INT Interrupt pin. Signals when a CAN message is received or an error occurs.
8 RST Reset pin. Resets the MCP25625 CAN controller.

Usage Instructions

The Adafruit CAN Pal Breakout is straightforward to use in a variety of projects. Below are the steps and best practices for integrating it into your circuit.

How to Use the Component in a Circuit

  1. Power the Board: Connect the VIN pin to a 3.3V or 5V power source, and connect GND to the ground of your circuit.
  2. Connect SPI Pins:
    • Connect SCK, MISO, MOSI, and CS to the corresponding SPI pins on your microcontroller.
    • Ensure the SPI clock speed is compatible with the MCP25625 (typically up to 10 MHz).
  3. Interrupt and Reset:
    • Connect the INT pin to a GPIO pin on your microcontroller to handle interrupts.
    • Optionally, connect the RST pin to a GPIO pin for resetting the CAN controller.
  4. CAN Bus Connection:
    • Use the onboard screw terminals to connect the CAN High (CANH) and CAN Low (CANL) lines to your CAN bus.
    • Ensure proper termination resistors (120Ω) are present at both ends of the CAN bus.

Important Considerations and Best Practices

  • Logic Level Selection: Ensure the microcontroller logic level matches the breakout board's logic level (3.3V or 5V).
  • Termination Resistors: If the breakout board is at the end of the CAN bus, add a 120Ω resistor across CANH and CANL.
  • SPI Configuration: Configure your microcontroller's SPI settings to match the MCP25625 requirements (Mode 0 or Mode 3).
  • Interrupt Handling: Use the INT pin to efficiently handle incoming CAN messages or errors.

Example Code for Arduino UNO

Below is an example of how to use the Adafruit CAN Pal Breakout with an Arduino UNO. This code initializes the CAN bus and sends a test message.

#include <SPI.h>
#include <Adafruit_MCP2515.h> // Library for MCP25625 CAN controller

// Create an MCP2515 instance
Adafruit_MCP2515 CAN(10); // CS pin connected to pin 10 on Arduino UNO

void setup() {
  Serial.begin(115200);
  while (!Serial); // Wait for Serial Monitor to open

  // Initialize the CAN controller
  if (!CAN.begin(MCP_ANY, CAN_500KBPS, MCP_8MHZ)) {
    Serial.println("CAN initialization failed!");
    while (1);
  }
  Serial.println("CAN initialized successfully!");

  // Set the CAN controller to normal mode
  CAN.setMode(MCP_NORMAL);
  Serial.println("CAN controller set to normal mode.");
}

void loop() {
  // Create a CAN message
  CANMessage message;
  message.id = 0x100; // Standard ID
  message.extended = false; // Standard frame
  message.len = 8; // Data length
  message.data[0] = 0x01; // Example data
  message.data[1] = 0x02;
  message.data[2] = 0x03;
  message.data[3] = 0x04;
  message.data[4] = 0x05;
  message.data[5] = 0x06;
  message.data[6] = 0x07;
  message.data[7] = 0x08;

  // Send the CAN message
  if (CAN.sendMessage(&message)) {
    Serial.println("Message sent successfully!");
  } else {
    Serial.println("Error sending message.");
  }

  delay(1000); // Wait 1 second before sending the next message
}

Troubleshooting and FAQs

Common Issues and Solutions

  1. CAN Initialization Fails:

    • Cause: Incorrect SPI connections or mismatched logic levels.
    • Solution: Double-check the wiring and ensure the logic level matches the microcontroller.
  2. No Communication on CAN Bus:

    • Cause: Missing or incorrect termination resistors.
    • Solution: Ensure 120Ω resistors are present at both ends of the CAN bus.
  3. Interrupts Not Triggering:

    • Cause: INT pin not connected or not configured in the microcontroller.
    • Solution: Verify the INT pin connection and configure the GPIO pin as an input.
  4. Data Corruption or Errors:

    • Cause: Noise or incorrect baud rate.
    • Solution: Use shielded cables for the CAN bus and ensure the baud rate matches all devices on the bus.

FAQs

  • Can I use this breakout with a 3.3V microcontroller? Yes, the breakout supports both 3.3V and 5V logic levels. Ensure the VIN pin is supplied with the appropriate voltage.

  • What is the maximum CAN bus length? The maximum length depends on the baud rate. For example, at 1 Mbps, the maximum length is approximately 40 meters.

  • Do I need external libraries for Arduino? Yes, you need the Adafruit_MCP2515 library, which can be installed via the Arduino Library Manager.

  • Can I use multiple CAN Pal Breakouts on the same SPI bus? Yes, but each breakout must have a unique CS pin connection to the microcontroller.

This concludes the documentation for the Adafruit CAN Pal Breakout. For further assistance, refer to the official Adafruit guide or community forums.