Dual SPI on same pins - ESP32-S3

RS_Solver
Posts: 2
Joined: Mon Jan 24, 2022 8:05 pm

Dual SPI on same pins - ESP32-S3

Postby RS_Solver » Tue Jun 20, 2023 8:26 am

I have a custom board with an ESP32-S3 Wroom. Furthermore I have a display and a pressure sensor connected to a SPI bus. When routing the board I made a mistake and mixed up MISO and MOSI on the display.
So I had the idea to use a second SPI bus with MISO and MOSI swapped. With this I could solve my hardware problem by software.
But I think I can't use a second SPI bus which has the same pins as the first one.
Example Code SCK = 11, MISO = 12, MOSI = 13
  1. DisplaySpi = new SPIClass(FSPI);
  2. DisplaySpi->begin(11,13,12,CS_DISPLAY);
  3.  
  4. BaroSpi = new SPIClass(HSPI);
  5. BaroSpi->begin(11, 12, 13, CS_BARO);
Did I just write my code wrong or is it not possible to use two separate SPI buses with the same pins (just swapped)?
The SPI that was created last works without problems but the one that was created first does not work.

Who is online

Users browsing this forum: Bing [Bot] and 106 guests