Three Node CAN System on a Breadboard with ESP32 and Arduino Microcontrollers

Three Node CAN System on a Breadboard with ESP32 and Arduino Microcontrollers

Overview of the CAN Bus Project

Introduction to the Project

  • The presenter, Josh, introduces himself as an embedded software engineer and outlines his goal to wrap up a CAN bus project on a breadboard.
  • He mentions previous demonstrations involving the ESP32 and TJA 1050 CAN transceiver, highlighting compatibility with different voltage levels (3.3V for ESP32 and 5V for the transceiver).

Setup Description

  • The bench setup includes two ESP32 devices: one acting as a CAN receiver and another as a CAN transceiver, along with an Eligo Uno connected to an MCP2515 CAN module.
  • All three microcontrollers are connected to the same CAN bus, facilitating data transmission and reception.

Code Walkthrough

Receiver Configuration

  • The code for the left-side ESP32 is set up as a CAN receiver with a bitrate of 250 kbps, continuously looping to wait for incoming data.

Sender Configuration

  • The Arduino using MCP2515 is configured to send messages in reverse order (8 down to 1), while the other ESP32 sends messages from 1 to 8. Both use ASCII values for these numbers.

Data Transmission Demonstration

Observations from Serial Monitor

  • In the serial monitor, both transmitting nodes successfully send their respective sequences while the receiving node logs them accurately.
  • The receiver confirms it receives data from both transmitters with matching CAN IDs (0x12 and 0xF6), demonstrating effective communication across the network.

Conclusion and Further Learning Resources

Closing Remarks

  • Josh expresses satisfaction with achieving a fully functional CAN system on a breadboard and encourages viewers interested in replicating this project.
  • Additional resources are mentioned for learning about specific components like the ESP32, TJA 1050 transceiver, Arduino Uno, MCP2515 module, voltage levels on a CAN bus, and general theory behind CAN systems.
Video description

In this video, I create a CAN bus on a breadboard with 3 devices. Two 3.3V ESP32s with TJA1050 CAN transceivers and a 5V Arduino Uno with MCP2515 CAN SPI module. This video is the summation of some of my previous videos, if you'd like to learn more about this system in detail, check out: [CAN Bus on a Breadboard with two ESP32s] https://www.youtube.com/watch?v=ZH_CCs12ptg [MCP2515 CAN Bus Module with Arduino] https://www.youtube.com/watch?v=GA-KNEuAR9w [CAN Bus Oscilloscope Measurements] https://www.youtube.com/watch?v=Krsgd1UEpHw [CAN Protocol Theory] https://www.youtube.com/watch?v=WikQ5n1QXQs