Page 1 of 1

ESP32-WROVER-E and MCP2515 Communication Issues over SPI Bus

Posted: Fri Aug 19, 2022 4:25 pm
by PeterG76
Hello,

We are having problems configuring an MCP2515 (TSSOP) CAN controller from our ESP32 application running on an ESP32-WROVER-E processor.

Our esp32 can driver is not getting the expected response. SPI trace is showing the MISO line to be always low. See attached

We are using the SENSOR_VP pin (GPIO32) on the ESP32-WROVER-E and wondered if there is a known issue with this pin pulling the line low.

Are there recommended configuration settings required for the ESP32-WROVER-E to set up our SPI bus correctly?
MISO_on_SPI_bus.png
MISO_on_SPI_bus.png (70.28 KiB) Viewed 2998 times

Re: ESP32-WROVER-E and MCP2515 Communication Issues over SPI Bus

Posted: Fri Aug 19, 2022 4:29 pm
by PeterG76
The same application works on another board using an MCP2515 (QFN) device and an older ESP32-WROVER processor.

The pin-outs are the same as the ESP32-WROVER-E processor, so we are any configuration differences for SPI bus between the ESP32-WROVER and ES32-WROVER-E processors?

Re: ESP32-WROVER-E and MCP2515 Communication Issues over SPI Bus

Posted: Sat Aug 20, 2022 2:20 am
by ESP_Sprite
No, code should work the same on both modules.

Re: ESP32-WROVER-E and MCP2515 Communication Issues over SPI Bus

Posted: Mon Aug 22, 2022 3:46 am
by ESP_LJH
Could you provide complete schematic? ESP32-WROVER, do you mean module with 1.8 V flash?
I am confused SENSOR_VP is not GPIO32, could you make sure pin assignments.

Re: ESP32-WROVER-E and MCP2515 Communication Issues over SPI Bus

Posted: Tue Aug 23, 2022 8:05 am
by PeterG76
ESP_LJH wrote:
Mon Aug 22, 2022 3:46 am
Could you provide complete schematic? ESP32-WROVER, do you mean module with 1.8 V flash?
I am confused SENSOR_VP is not GPIO32, could you make sure pin assignments.
Sorry, that is a typo. It should be GPIO36

Re: ESP32-WROVER-E and MCP2515 Communication Issues over SPI Bus

Posted: Tue Aug 23, 2022 3:43 pm
by PeterG76
OK, so we have discovered the cause of our issue.

It turns out the crystal module driving OSC1 on the MCP2515 CAN driver was soldered the wrong way round on the PCB. This meant that the MCP2515 device was not responding to requests on the SPI bus.

Having replaced the crystal module in the correct orientation we now see MISO traffic between the ESP32-WROVER-E processor and the MCP2515 chip.

Thank you for your responses everyone. Our ESP32 application does therefore indeed work on both ESP32-WROVER and ESP32-WROVER-E processors.