Try to use Elegoo TFT 2.8 Display with Arduino MKR1000

I’m trying to use theElegoo TFT 2.8 Display with Arduino MKR1000.

I have connected both in this way:

Pin VCC    TFT CON1 3V3
Pin GND     TFT Con1 GND
Pin 7  => TFT LCD_CS  (Chip Select pin)
Pin 6  => TFT LCD_RS  (Data/Command pin)
Pin 5  => TFT LCD_RST (Reset pin)
Pin 8  => TFT SD_DI   (MOSI pin)
Pin 9  => TFT SD_SCK  (SCK pin)           
Pin 10 => TFT SD_DO   (MISO pin)          

And I run the following code:

#include <Adafruit_GFX.h>
#include <Adafruit_ILI9341.h>

// Define the pins and Connections.
// Pin VCC    TFT CON1 3V3
//Pin GND     TFT Con1 GND

#define TFT_CS   7  // Chip Select pin   TFT LCD_CS
#define TFT_DC   6  // Data/Command pin  TFT LCD_RS
#define TFT_RST  5  // Reset pin         TFT LCD_RST
#define TFT_MOSI 8  // MOSI pin          TFT SD_DI
#define TFT_SCK  9  // SCK pin           TFT SD_SCK
#define TFT_MISO 10 // MISO pin          TFT SD_DO

// Constructor with all pins specified
Adafruit_ILI9341 tft = Adafruit_ILI9341(TFT_CS, TFT_DC, TFT_MOSI, TFT_SCK, TFT_RST, TFT_MISO);

void setup() {
  tft.begin();
  tft.setRotation(1);
  tft.fillScreen(ILI9341_BLACK);
  tft.setCursor(10, 10);
  tft.setTextSize(3);
  tft.setTextColor(ILI9341_WHITE);
  tft.println("It works!");

  Serial.begin(115200);
  Serial.println(F("TFT LCD test"));
  Serial.println(F("Elegoo 2.8\" TFT Screen"));
}

void loop() {
  
}

But I got only a white screen and nothing displayed.

Somebody can Help me?

With no link to the actual display or a schematic or pictures of wiring provided, it's hard to say with 100% certainty, but I would be concerned about the following bit of your hookup for a start.

Think about those connections for a minute and see if they still make sense if you're trying to communicate with the display rather than a potential SD card.

Oh, and out of curiosity, why on earth are you using software SPI when you've got a perfectly good hardware SPI interface on the same pins???

Edit: I have the sinking feeling that you're trying to use a shield display, in which case there isn't an SPI interface to the display at all. Had you provided a link to the display you're using, we'd know one way or the other...

Thanks for you answer van_der_decken.

Yes I’m using The Elegoo TFT Shield. I supposed with the SPI interface you can select the Display or the SD.

This is the display pinout:

There is any way to use this shield with arduino MKR?

Thanks again.

Thanks

No. The SPI interface is for the SD card only. The interface to the LCD is 8 bit parallel.

It's certainly possible. I've used one with an rPi Pico. After adding support for my chosen pinout to MCUFRIEND_kbv. You would have to do something similar to add support for whatever pinout you choose on your MKR.

But, and I can't emphasize this enough, that pinout will use the 8 bit parallel interface to the LCD and will take up almost all of the available I/O on the MKR.

Yor answers were very helfull. Thanks s lot!