<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[T-Display-S3 (touch version) trouble to connect SD card reader (SPI)]]></title><description><![CDATA[<p dir="auto">Hi,<br />
I try to connect a SD reader via SPI to the T-Display-S3 touch version - sadly without success.<br />
From reading other comments/websites it seems I can freely define the pins for a secondary (HSPI) SPI bus.<br />
This is what I tried:</p>
<pre><code>#include "FS.h"
#include "SD.h"
#include "SPI.h"

SPIClass spiSD(HSPI);
#define SDSPEED 27000000

// SPI port #2: SD Card Adapter
#define SD_CLK 21 //yellow
#define SD_MISO 18 //brown
#define SD_MOSI 17 //orange
#define SD_CS 16 //green
</code></pre>
<p dir="auto">in setup I have:</p>
<pre><code>Serial.begin(9600);

spiSD.begin(SD_CLK, SD_MISO, SD_MOSI, SD_CS); //SCK,MISO,MOSI,cs

if (!SD.begin(SD_CS, spiSD, SDSPEED)) {
Serial.println("Card Mount Failed!");
return;
} else {
Serial.println("Card Mount Successful!");
}
</code></pre>
<p dir="auto">but all I get is "Card Mount failed" - I have multiple reader modules, but I get the same result with all of them, so i assume the issue is with my setup/pins/code...</p>
<p dir="auto">any help would be highly appreciated - thanks in advance <img src="https://www.community.lilygo.cc/assets/plugins/nodebb-plugin-emoji/emoji/android/1f642.png?v=5rta56507n5" class="not-responsive emoji emoji-android emoji--slightly_smiling_face" title=":)" alt="🙂" /></p>
]]></description><link>https://www.community.lilygo.cc/topic/154/t-display-s3-touch-version-trouble-to-connect-sd-card-reader-spi</link><generator>RSS for Node</generator><lastBuildDate>Sat, 16 May 2026 05:16:00 GMT</lastBuildDate><atom:link href="https://www.community.lilygo.cc/topic/154.rss" rel="self" type="application/rss+xml"/><pubDate>Thu, 05 Jan 2023 21:47:45 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to T-Display-S3 (touch version) trouble to connect SD card reader (SPI) on Sun, 09 Jun 2024 03:01:07 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="https://www.community.lilygo.cc/uid/2595">@llsummer</a> <img src="/assets/uploads/files/1717901961011-screenshot-2024-06-08-at-10.59.03-pm-resized.png" alt="Screenshot 2024-06-08 at 10.59.03 PM.png" class=" img-responsive img-markdown" /></p>
<p dir="auto">You have to do more self-research. SD on ESP32 is not easy, but it can be done.<br />
There are many many SD memories that cannot be used.</p>
<p dir="auto">No, I will not elaborate.</p>
]]></description><link>https://www.community.lilygo.cc/post/1816</link><guid isPermaLink="true">https://www.community.lilygo.cc/post/1816</guid><dc:creator><![CDATA[teastain2]]></dc:creator><pubDate>Sun, 09 Jun 2024 03:01:07 GMT</pubDate></item><item><title><![CDATA[Reply to T-Display-S3 (touch version) trouble to connect SD card reader (SPI) on Sun, 09 Jun 2024 02:59:04 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="https://www.community.lilygo.cc/uid/612">@teastain2</a> Thanks.<br />
not work.</p>
<p dir="auto">The example/SD  just define 3 pins, and I didn't find any where mentioned SD_CS, can be a problem?</p>
<p dir="auto">I used SD card reader with 6 pins.</p>
]]></description><link>https://www.community.lilygo.cc/post/1815</link><guid isPermaLink="true">https://www.community.lilygo.cc/post/1815</guid><dc:creator><![CDATA[llsummer]]></dc:creator><pubDate>Sun, 09 Jun 2024 02:59:04 GMT</pubDate></item><item><title><![CDATA[Reply to T-Display-S3 (touch version) trouble to connect SD card reader (SPI) on Sun, 09 Jun 2024 01:42:00 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="https://www.community.lilygo.cc/uid/2595">@llsummer</a> You should have no trouble with either.<br />
Try this official sketch:<br />
<a href="https://github.com/Xinyuan-LilyGO/T-Display-S3/tree/main/examples/sd" rel="nofollow ugc">https://github.com/Xinyuan-LilyGO/T-Display-S3/tree/main/examples/sd</a></p>
]]></description><link>https://www.community.lilygo.cc/post/1814</link><guid isPermaLink="true">https://www.community.lilygo.cc/post/1814</guid><dc:creator><![CDATA[teastain2]]></dc:creator><pubDate>Sun, 09 Jun 2024 01:42:00 GMT</pubDate></item><item><title><![CDATA[Reply to T-Display-S3 (touch version) trouble to connect SD card reader (SPI) on Sun, 09 Jun 2024 01:23:17 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="https://www.community.lilygo.cc/uid/612">@teastain2</a> said in <a href="/post/1812">T-Display-S3 (touch version) trouble to connect SD card reader (SPI)</a>:</p>
<blockquote>
<p dir="auto">What exact board do you have?</p>
</blockquote>
<p dir="auto">Thanks.<br />
I have T-Display S3 basic + SD card.<br />
I heard that the Touch version more difficulty to work with SD?</p>
]]></description><link>https://www.community.lilygo.cc/post/1813</link><guid isPermaLink="true">https://www.community.lilygo.cc/post/1813</guid><dc:creator><![CDATA[llsummer]]></dc:creator><pubDate>Sun, 09 Jun 2024 01:23:17 GMT</pubDate></item><item><title><![CDATA[Reply to T-Display-S3 (touch version) trouble to connect SD card reader (SPI) on Sun, 09 Jun 2024 00:38:18 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="https://www.community.lilygo.cc/uid/2595">@llsummer</a> What problem are you having?<br />
What exact board do you have?</p>
]]></description><link>https://www.community.lilygo.cc/post/1812</link><guid isPermaLink="true">https://www.community.lilygo.cc/post/1812</guid><dc:creator><![CDATA[teastain2]]></dc:creator><pubDate>Sun, 09 Jun 2024 00:38:18 GMT</pubDate></item><item><title><![CDATA[Reply to T-Display-S3 (touch version) trouble to connect SD card reader (SPI) on Sun, 09 Jun 2024 00:20:48 GMT]]></title><description><![CDATA[<p dir="auto">any thing new for now?<br />
I tested the code above not luck.</p>
]]></description><link>https://www.community.lilygo.cc/post/1811</link><guid isPermaLink="true">https://www.community.lilygo.cc/post/1811</guid><dc:creator><![CDATA[llsummer]]></dc:creator><pubDate>Sun, 09 Jun 2024 00:20:48 GMT</pubDate></item><item><title><![CDATA[Reply to T-Display-S3 (touch version) trouble to connect SD card reader (SPI) on Tue, 29 Aug 2023 05:56:56 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="https://www.community.lilygo.cc/uid/612">@teastain2</a></p>
<p dir="auto">Thanks for the heads up Terry, I just had my T-Display-S3 Touch delivered on Friday, I will be jumping on it very soon, I need to resolve an issue with the none touch unit....I posted that topic tonight.</p>
<p dir="auto">Thank you again.</p>
]]></description><link>https://www.community.lilygo.cc/post/1053</link><guid isPermaLink="true">https://www.community.lilygo.cc/post/1053</guid><dc:creator><![CDATA[eflorea]]></dc:creator><pubDate>Tue, 29 Aug 2023 05:56:56 GMT</pubDate></item><item><title><![CDATA[Reply to T-Display-S3 (touch version) trouble to connect SD card reader (SPI) on Thu, 24 Aug 2023 19:28:25 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="https://www.community.lilygo.cc/uid/1090">@eflorea</a> The "Touch pins" are an ESP32 Espressif use of the pins as analog sensing for a home brew touch interface.<br />
The Touch Screen on the LilyGO T-Display S3 Touch is I2C thus:<br />
<img src="/assets/uploads/files/1692905100441-screenshot-2023-08-24-at-3.22.27-pm.png" alt="Screenshot 2023-08-24 at 3.22.27 PM.png" class=" img-responsive img-markdown" width="508" height="1012" /><br />
<a href="https://github.com/Xinyuan-LilyGO/T-Display-S3/blob/main/image/T-DISPLAY-S3-TOUCH.png" rel="nofollow ugc">https://github.com/Xinyuan-LilyGO/T-Display-S3/blob/main/image/T-DISPLAY-S3-TOUCH.png</a><br />
So the touch vesion uses up 4 GPIO that the standard model could use  GPIO !!!<br />
You should have no trouble.<br />
-Terry</p>
]]></description><link>https://www.community.lilygo.cc/post/1000</link><guid isPermaLink="true">https://www.community.lilygo.cc/post/1000</guid><dc:creator><![CDATA[teastain2]]></dc:creator><pubDate>Thu, 24 Aug 2023 19:28:25 GMT</pubDate></item><item><title><![CDATA[Reply to T-Display-S3 (touch version) trouble to connect SD card reader (SPI) on Thu, 24 Aug 2023 16:56:05 GMT]]></title><description><![CDATA[<p dir="auto">Hi Stefan, I was curious if you using the SPI port had any interference with the touch functionality.</p>
<p dir="auto">I noticed that in the pinout the SPI pins 10-13 are also connected to some of the touch pins ?</p>
<p dir="auto">I'm still waiting on my device to arrive but I hope there is no issue there.</p>
<p dir="auto">Thank you.</p>
]]></description><link>https://www.community.lilygo.cc/post/999</link><guid isPermaLink="true">https://www.community.lilygo.cc/post/999</guid><dc:creator><![CDATA[eflorea]]></dc:creator><pubDate>Thu, 24 Aug 2023 16:56:05 GMT</pubDate></item><item><title><![CDATA[Reply to T-Display-S3 (touch version) trouble to connect SD card reader (SPI) on Fri, 06 Jan 2023 20:20:39 GMT]]></title><description><![CDATA[<p dir="auto">I found the solution on my own with some help of Google.<br />
In the end I only had to add one more line of code to make it work (switching the CS Pin to output...):</p>
<pre><code>pinMode(SD_CS,OUTPUT);
</code></pre>
<p dir="auto">so the complete code-part looks like this:</p>
<pre><code>void setup() {

  Serial.begin(9600);

  spiSD.begin(SD_CLK, SD_MISO, SD_MOSI, SD_CS);  //SCK,MISO,MOSI,cs
  pinMode(SD_CS,OUTPUT);

  if (!SD.begin(SD_CS, spiSD, SDSPEED)) {
    Serial.println("Card Mount Failed!");
    return;
  } else {
    Serial.println("Card Mount Successful!");
  }
}
</code></pre>
]]></description><link>https://www.community.lilygo.cc/post/377</link><guid isPermaLink="true">https://www.community.lilygo.cc/post/377</guid><dc:creator><![CDATA[Stefan]]></dc:creator><pubDate>Fri, 06 Jan 2023 20:20:39 GMT</pubDate></item></channel></rss>