Electronics > Projects, Designs, and Technical Stuff
ESP32 and CAN 2.0 - Does it really exist?
(1/1)
skyjumper:
Hi All, I'm trying to build a little board that can stream data from a CAN bus over WiFi and/or BT and ran across the ESP32. The data sheet says it has a CAN 2.0 peripheral, but that's all it says about CAN. There is no label for CAN on the pinout and no indication if this is controller or controller and transceiver.
So my question is, does the ESP32 really have a CAN 2.0 controller and, if so, how do I get to it?
Thanks!
jleg:
--- Quote from: skyjumper on February 27, 2019, 06:44:01 am ---Hi All, I'm trying to build a little board that can stream data from a CAN bus over WiFi and/or BT and ran across the ESP32. The data sheet says it has a CAN 2.0 peripheral, but that's all it says about CAN. There is no label for CAN on the pinout and no indication if this is controller or controller and transceiver.
--- End quote ---
first google hit:
https://docs.espressif.com/projects/esp-idf/en/latest/api-reference/peripherals/can.html
"The CAN controller does not contain a internal transceiver and therefore requires an external transceiver to operate."
"The CAN controller’s interface consists of 4 signal lines known as TX, RX, BUS-OFF, and CLKOUT. These four signal lines can be routed through the GPIO Matrix to GPIOs."
IDEngineer:
--- Quote from: jleg on February 28, 2019, 03:44:05 pm ---"The CAN controller’s interface consists of 4 signal lines known as TX, RX, BUS-OFF, and CLKOUT.
--- End quote ---
I wonder what CLKOUT is for. CAN doesn't have a separate clock signal, not even between the transceiver and PHY chip. TX and RX go into the PHY chip and CAN-H and CAN-L come out. Hmmm....
sokoloff:
--- Quote from: IDEngineer on February 28, 2019, 05:13:58 pm ---
--- Quote from: jleg on February 28, 2019, 03:44:05 pm ---"The CAN controller’s interface consists of 4 signal lines known as TX, RX, BUS-OFF, and CLKOUT.
--- End quote ---
I wonder what CLKOUT is for. CAN doesn't have a separate clock signal, not even between the transceiver and PHY chip. TX and RX go into the PHY chip and CAN-H and CAN-L come out. Hmmm....
--- End quote ---
MCP2515 (a common CAN transceiver) has a CLKOUT pin...
IDEngineer:
--- Quote from: sokoloff on February 28, 2019, 05:19:46 pm ---MCP2515 (a common CAN transceiver) has a CLKOUT pin...
--- End quote ---
Yes, but it's not related to CAN. It's so you can let the chip optionally generate the clock for your MCU or other hardware. Basically sharing one crystal/oscillator for multiple purposes.
Maybe that's what the OP's "CLKOUT" is for too, but it seems odd to be lumped together with the CAN signals. Perhaps his hardware uses an MCP2515-type device and the "designer" didn't understand CAN, so they just brought out every signal just in case.
Navigation
[0] Message Index
Go to full version