Success ! Using SPI2 on Blackpill to driver TFT espi

All good now - I had the wrong driver selected !
///////////////////////////////////////////////////////////
Hi,

I have been using Bodmer's TFT eSPI library with great success on STM32F401 - now I'm migrating my code to a Blackpill F411 and need to use SPI2 (SPI1 is used for a W5500 ethernet connection).

I've edited Setup29_ILI9341_stm32.h and can see signals on the correct pins for SPI2 as per below

#define TFT_SPI_PORT 2 // SPI 2 maximum clock rate is 27MHz
#define TFT_MOSI PB15
#define TFT_MISO PB14  // was pc2
#define TFT_SCLK PB13

#define TFT_CS   PB10 // Chip select control pin to TFT CS
#define TFT_DC   PB4 // Data Command control pin to TFT DC (may be labelled RS = Register Select)
#define TFT_RST  PB5 // Reset pin to TFT RST (or RESET)

Any ideas / suggestions ?

I'm using Arduino IDE 2.2.1 and TFT eSPI 2.5.31

Regards Tim

You can use the same SPI for more than one device

By the way
If you need to mark the topic as solved - you don't need to edit the title - just check the "Solution" mark under a most usefull post in the topic

Hi,
I had looked into daisy chaining both the display and ethernet cards but wasn't convinced it would be viable with the parts I'm using.
I'll maybe revisit that approach later.

I'll mark the thread as solved as you suggest - thanks.

1 Like

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.