Bought a TFT display from Electrodragon. Electrodragon sells 2 versions, a 1.8″ and a 2.2″ version. I got the 2.2 inch version, it costs only 7.2$. It’s a colour (QVGA) display with 240×320 pixels. The display uses an ILI9341 driver chip. I found the datasheet of the ILI9341 here. The chip works at 3.3V, so I used one of my own boards with an ATmega328 running at 3.3V to test the display. On the back of the display there is also an SD card reader.
The display can be used with an Arduino, I’ve found 2 Arduino libraries that support this display.
I first tried out the library provided by Adafruit, you can download it on Github. This library uses hardware SPI to communicate with the driver chip. SPI pins for an Arduino Duemilanove/Nano/Uno are 10 (SS), 11 (MOSI), 12 (MISO), 13 (SCK). The driver chip needs another 2 pins, D/C and a reset pin (RST).
Back view of the display showing the connection pins:
I connected the display to an Atmega328 and uploaded the “graphicstest” example sketch.
I also found another library that supports this display, the UTFT library. This library supports a number of 8bit, 16bit and serial graphic displays including the ILI9341 driver chip. You can find the library and more information about it here. This library is a little bit more difficult to make it work but it comes with a manual that explains most things. This library does not use the same pins as the Adafruit library. I couldn’t figure out how to connect the display to my ATmega328. So I emailed the programmer of the library and I received a prompt reply how to connect my new display.
These are the connections I made:
DO (MISO) -> Not used by UTFT
SCK -> pin 8
SDI (MOSI) -> pin 9
D/C -> pin 10
RESET -> pin 11
CS -> pin 12
In the sketch you then need to use this constructor to define the type of display and the pins:
UTFT myGLCD(TFT01_22SP,9,8,12,11,10);
I then uploaded the example sketch and it worked, see next video:
I then successfully wrote a simple sketch to display a jpg on the display. The library comes with a tool to convert images files to .c files. That way you can store the image in progmem and show it on the display. But be warned it’s easy to fill the complete memory of an ATmega328 with one image file.
Hello,
Thanks for the review. Have you tried to use the SD card reader ?
Not yet, but it shouldn’t be a problem to make it work.
[…] ها : https://github.com/gmtii/ili9341-arduino https://github.com/stanleyhuangyc/MultiLCD 2.2 inch TFT display | Bajdi.com 2.8'' TFT Touch Shield V2.0 – […]
Hi
I have managed to operate this display with the UTFT library using software SPI (it does not support hardware SPI) but it is too slow.
I’m using an Arduino mega2560 for the tests.
Do you know of a good library that I can use Hardware SPI with the arduino mega2560 and this display ?
I tried the adafruit lib but it did not work with my setup.
I only know of the Adafruit and UTFT library…
You were lucky to get your goods from this company. Despite documentary proof from Courier company of non-delivery and return of goods – they will not send goods, or refund. Look like Scammers to me.
Sorry for your loss but I only have very good experiences with Electrodragon. In the last 6 months I have received 4 packages from them. Each one arrived in less then 2 weeks after ordering.
Best regards;
What UTFT myGLCD stands for (TFT01_22SP, 9, 8, 12, 11, 10); or how do I determine these numbers in Nodemcu? Thank you
Those numbers are the pins the lcd is connected to. Please read the documentation of the library. I have no experience with Nodemcu.