Teensy 3.6 + Audio Card + ILI9341 display - display not working

Status
Not open for further replies.

DerekR

Well-known member
I am migrating my projects to the 3.6 from the 3.2 with the same basic hardware setup: Teensy with audio board, and 2.8" ILI9341 touch screen display. Everything is working fine, except that the screen is blank (but lit).

To handle SPI conflicts I am using the modified SPI assignments as described in the PJRC store when using the audio card and ILI9341 with the ILI9341_t3 library
Code:
//
#define TFT_DC      20
#define TFT_CS      21
#define TFT_RST    255  // 255 = unused, connect to 3.3V
#define TFT_MOSI     7
#define TFT_SCLK    14
#define TFT_MISO    12
ILI9341_t3 tft = ILI9341_t3(TFT_CS, TFT_DC, TFT_RST, TFT_MOSI, TFT_SCLK, TFT_MISO);
Just a blank screen. I know the graphics code is running underneath because all my Serial.print debug stuff is giving appropriate timing for graphics intensive work, even though it is not showing. I just copied the code from my 3.2 versions - including DSP and real-time code and it is all working. Similarly graphicstest.ino is giving appropriate timing info.

I know the wiring is correct because I wrote a modified "blink.ino" to put out a 1kHz square wave on any designated pin, and used a scope to trace signals on the above pins all the way from the 3.6 to the appropriate physical pins on the display. Everything seems good. All voltages on the 3.6 are what they should be.

I've tried slowing down the processor speed.

The graphics board is good and works fine when I pop it back into my 3.2 setup. The system uses a Tindie 64 pin breakout, with the audio board piggy-backed on the processor. The 3.6, audio board and ILI9341 are all socketed.

I can see data bursts on the lines when graphics code is running.

I'm wondering if the SPI handling needs to be different for the 3.6 when the Audio Board is used? Any suggestions on how to debug further would be welcomed. Thanks...
 
Update: Spent all day yesterday trying to work out what the problem is. I took the display and 3.6 from the hard-wired board and put them on a breadboard where I could play with the SPI pin assignments with jumpers. I could also simply change out the processors: 3.6 or 3.2 (they use the same physical pins)
Results: The graphics worked fine with the 3.2 but not at all with the 3.6. All non-graphics code ran perfectly on both processors. The graphicstest.ino Serial.print() output made perfect sense in both cases.

I tested digitalWrite() and digitalRead() on all the SPI pins. They worked perfectly.

I resoldered all accessible pins on the Tindie breakout board.

My conclusion is that I have a bad 3.6. This was a brand new one. I have just ordered two more...
 
I think I may have found the problem! I have been looking at the signals on the SPI pins for the 3.6 and the 3.2. The only difference is the clock rate: on the T3.2 it is 24 MHz, but on the T3.6 it is 30 MHz.

I've looked on the web. It seems that there is a wide variation of maximum speeds for the ILI9341. Some people claim up to 48 MHz, others have observed much lower, and ILI rate it way down around 10 MHz.

The question I have is whether mine is crapping out at 30 MHz, and if so how do I go about changing the SCLK frequency? Do I have to mess with SPI.h?
 
Status
Not open for further replies.
Back
Top