SPI timing problems

I have a small PCB designed for Nano IOT which I want to use now with Nano ESP32:

I used my Code from Nano IOT and compiled it for the Nano ESP32. The LCD (uses SPI) and the SD card did not work :disappointed:. After some hours I found a good post:
https://forum.arduino.cc/t/microsd-lessons-and-a-mystery/1191051
@VeloSteve suggestet that the SPI timing is too fast and this seems to be my problem too. I tried the LCD code with software SPI (instead of hardware SPI) and it worked :slightly_smiling_face:. Next I tried #include "SdFat.h" instead of #include <SD.h> and the SD card worked too :smiley:.

So my question: is there a possibillty to overwrite the original SPISettings with better version? I have no idea ...

Thanks in advance

Please de

I can say yes as that is a subjective question. Please define what a better version is.

If you are sure that the speed of the hardware SPI is too high why not just reduce it with the command SPI.setClockDivider ( SPI_CLOCK_DIV8 ); // Nano and ESP8266 with 2, 4, 8, 16, 32, 64 or 128 )?

A better version is a working version :wink:
With the Nano IOT I used "SPISettings spi_lcd(1000000, MSBFIRST, SPI_MODE3); " and it was fine. But with the ESP32 this does not work although it should.

From the reference: "This function should not be used in new projects. Use SPISettings."
And 128 is still not enough. For 240 MHz, 256 would be required.