SOLVED - How to use HSPI in ‘MCP23S08’ library?
Posted: Sat Jun 18, 2022 1:04 am
I have a project which uses a standard TFT Touch Display, SD Card and an MCP23S08 expander chip. All communicating via SPI. The ESP32 is a standard 38 pin devkit module.
The TFT Touch Display and SD Card uses VSPI with three CS pins using TFT_eSPI library and the SD library. As VSPI is the default SPI config, these devices are are all working as expected.
The MCP23S08 using https://github.com/julianschuler/MCP23S08 library is simple to use with default VSPI but I need help getting it to work with HSPI.
I have looked at https://github.com/espressif/arduino-es ... iple_Buses but I do not know if or how this can be implemented in the MCP23S08 library so that the HSPI is used instead of VSPI.
I am familiar with Arduino IDE and VSCode/PlatformIO.
Any code or guidance would be appreciated.
PIN Allocations.
VSPI
Display_SCK 18
Display_MOSI 23
Display_MISO 19
Display_CS 5
Touch_CS 17
SD_CS 16
HSPI
MCP23S08_SCK 14
MCP23S08_MOSI 13
MCP23S08_MISO 12
MCP23S08_CS 15
The TFT Touch Display and SD Card uses VSPI with three CS pins using TFT_eSPI library and the SD library. As VSPI is the default SPI config, these devices are are all working as expected.
The MCP23S08 using https://github.com/julianschuler/MCP23S08 library is simple to use with default VSPI but I need help getting it to work with HSPI.
I have looked at https://github.com/espressif/arduino-es ... iple_Buses but I do not know if or how this can be implemented in the MCP23S08 library so that the HSPI is used instead of VSPI.
I am familiar with Arduino IDE and VSCode/PlatformIO.
Any code or guidance would be appreciated.
PIN Allocations.
VSPI
Display_SCK 18
Display_MOSI 23
Display_MISO 19
Display_CS 5
Touch_CS 17
SD_CS 16
HSPI
MCP23S08_SCK 14
MCP23S08_MOSI 13
MCP23S08_MISO 12
MCP23S08_CS 15