ST7735 1.8″ TFT Dispay: SPI vs General connection
Intro
I got a ST7735 based lcd from ebay and decided to play with it a bit.
Setup
- Arduino UNO
- 1.8″ TFT LCD from ebay
- Some jumper cables
Code
All the guidelines for connecting the LCD to the Arduino can be found here: http://www.ladyada.net/products/18tftbreakout/, but there is one thing to note. In the tutorial there is a pin called “dc” (Data/Command) (thanks to sza2) (I am not sure what that stands for) , but on my LCD it’s named “RS” (register select). So, to make it work, just ignore the difference in naming.
Display driver library: https://github.com/adafruit/Adafruit-ST7735-Library
And the required graphics library: https://github.com/adafruit/Adafruit-GFX-Library
I am using the demo-sketches from the AdafruitST7735\examples\:
- graphicstest
- graphicstest_highspeed
Comparison itself
In the video you can see the communication protocol speed comparison.
Conclusion
SPI is the way to go 🙂
Posted on July 21, 2012, in Electronics, Projects and tagged 1.8", arduino, LCD, ST7735, test, TFT. Bookmark the permalink. 6 Comments.
DC: Data/Command
Thanks 😉
hi i have a question, i tried to use hardware spi in a arduino uno board for a nokia 5110 lcd. when i used software spi it workd perfectly. but it doesn’t display properly in the hw spi setup. the pixels are all steched out.the crystal in the uno is 8 MHz and can’t get it to view perfectly for any clock devider setting. is there any sollution? thankyou!
Hey,
I’ve heard of people having problems with HW SPI. The problem might be that you need to set it up properly so that it works.
Are you using SparkFun’s LCD? Have you tried using their code? Link to SparkFun’s site: https://www.sparkfun.com/products/10168
thank you for the reply! yes i was trying a similar version, the library available on the arduino site http://playground.arduino.cc/Code/PCD8544 and replaced the shift out code (shiftOut(mosi, clk, MSBFIRST, data);) with the SPI.transfer() method, importing the spi.h library and beginning it. i assume that the problem might be with the clock speed. even though the clock speed was set to the lowest value the problem remains the same.
Hey, have you looked at the arduino’s SPI reference page? The different modes as well as settings for speed are described there. Maybe it will help. Link: http://arduino.cc/en/Reference/SPI