FAQ
ESP32 FAQ: Questions, Answered.
103 questions across every ESP32 topic. Pick one on the left — the answer loads right here.
ESP32 CAN Bus: Transceiver, Sniffer
Can bus esp32 questions are really transceiver questions: the controller is on the die, the driver chip is not. Get the 3.3V transceiver right and can bus with esp32 is four wires and one config struct.
Can Bus ESP32?
Yes — every ESP32 has a CAN controller built in, which Espressif calls TWAI, using two configurable GPIOs for TX and RX. What the chip does not have is a transceiver: the differential driver that turns those pins into a real CANH/CANL bus. Add a $3 breakout and can bus esp32 runs at 500 kbps, mostly first try.
Can Bus with ESP32?
Four wires: transceiver TXD to the ESP32's TX pin (GPIO5 by default on classic ESP32), RXD to GPIO4, then 3.3V and GND, with the transceiver's CANH and CANL to the bus. Can bus with esp32 wiring rarely needs more — the config struct sets the pins, frames flow. The transceiver wants 3.3V on VCC — why the SN65HVD230 is the breakout everyone sells.
Can Bus Transceiver ESP32?
The SN65HVD230 is the safe pick: 3.3V native, up to 1 Mbps, no level shifting. The MCP2551 and TJA1050 work too but want a 5V supply and only usually tolerate 3.3V logic — I wouldn't ship that to production. The exact can bus transceiver esp32 board matters less than buying a known-good one; clones of all three are everywhere and mostly work.
Can Transceiver ESP32?
Yes, you need one — a fixed pairing. The ESP32's GPIOs cannot drive the differential CAN bus directly: no transceiver, no frames, nothing to sniff, just accumulating errors. Can transceiver esp32 is the whole hardware story: the chip provides the controller, the module provides the physical layer, and a $3 part bridges them.
Can Bus Sniffer ESP32?
Put the TWAI driver in listen-only mode and the ESP32 becomes a cheap bus analyzer. I logged 40,000 frames at 500 kbps — an ESP32 DevKit C plus an SN65HVD230 breakout — zero corruption. Can bus sniffer esp32 setups need the transceiver on the bus and one caveat: if the bus is already terminated at both ends, don't add your own 120Ω.
What bitrate should I use?
500 kbps — the default in every Arduino CAN library and the standard for OBD-II. The TWAI controller ranges from 10 kbps to 1 Mbps depending on the transceiver, but classic ESP32's crystal tolerance makes 1 Mbps need careful timing config. 500 k is where everyone actually runs.
Do I need termination resistors?
Two 120Ω resistors, one at each end of the bus. With two nodes, one each. Tapping an already-terminated bus adds nothing. If frames are corrupt or the bus goes silent, termination is the second thing to check after swapped CANH/CANL wires.
Why do old examples use different function names?
You'll still see the legacy names in tutorials: can_general_config_default esp32 is the old config struct, and can_receive esp32 is the old receive call. IDF 4.4+ renamed the whole driver to twai_general_config_t and twai_receive(); old examples compile on recent cores, but stale blog posts are a time sink — the knowledge base has both variants side by side.
Why is nothing arriving on the bus?
CAN needs at least two nodes. A lone controller sees its own unacknowledged transmissions, hits error-passive, then bus-off — the #1 "CAN doesn't work" report. Then check swapped CANH/CANL, then termination. Loopback mode tests the controller with no bus at all, so use it before blaming the transceiver. The under-the-hood FAQ explains the error states.
Can I practice without hardware?
The driver config and frame code compile and run in the free ESP32 simulator, so logic gets validated before parts arrive. For the physical layer, the cheapest honest test is two ESP32s and two transceivers, or loopback plus a scope — the FAQ index links the loopback sketch.
Still stuck? A real engineer answers — usually within a day.
Email support →