Getting Started

These following instructions will help you to install and run the project on the ESP32 for development and testing purposes.

Prerequisites

Which hardware components and software are needed and how to install them

Hardware components

  • ESP32 by Espressif
  • CAN-Transceiver
  • cables
  • D-SUB connector (male)

Software

Connecting the hardware

Connect the following Pins from the ESP32 with the specified Pins of the CAN-Transceiver

ESP32 CAN-Transceiver
3.3 Volt 3V3 3V3
Ground GND GND
CTX GPIO5 CTX
CRX GPIO4 CRX

Connect the following Pins from the CAN-Transceiver with the specified Pins of the D-SUB connector

CAN-Transceiver D-SUB connector
CAN High CANH Pin 7
CAN Low CANL Pin 2

Install and configure the Arduino IDE

  1. Download and install the Arduino IDE
  2. Open Preferences in the Arduino IDE ( File -> Preferences )
  3. Include https://dl.espressif.com/dl/packageesp32index.json under Additional Boards Manager URLs
  4. Open the Board Manager ( Tools -> Board -> Boards Manager… )
  5. Search for esp32 and install the esp32 by Espressif Systems
  6. Finish! The installation should be completed in a few seconds

Upload the Project to the ESP32

Connect the ESP32 via USB with a Computer and follow the instructions

  1. Open the Arduino IDE
  2. Choose a ESP32 Board ( Tools -> Board -> ESP32 Arduino)
  3. Choose the used port ( Tools -> Port: -> COMx )
  4. Download the Project and open the “CAN_Interface.ino” ( File -> Open…)
  5. Press the Upload Button in the Arduino IDE
  6. If everything went as expected a “Done uploading.” message should appear