If your shield looks like this, you have the original 1.8" TFT shield which does not have a helper seesaw chip
The shield uses the "Classic Arduino" SPI wiring and will perform best with Atmega 328-based Arduinos such as the Uno. It can work with other Arduinos but not very well.
Load up the shieldtest demo
If you are using an Arduino UNO, Duemilanove or compatible with the ATmega328 chipset, you don't have to do anything! If you're using a Mega, Leonardo, Due or other non-ATmega328 chipset, you'll have to make a modification
To use with the shield, modify the example code pin definitions as follows.
Find these lines:
// Option 1 (recommended): must use the hardware SPI pins // (for UNO thats sclk = 13 and sid = 11) and pin 10 must be // an output. This is much faster - also required if you want // to use the microSD card (see the image drawing example) Adafruit_ST7735 tft = Adafruit_ST7735(TFT_CS, TFT_DC, TFT_RST); // Option 2: use any pins but a little slower! #define TFT_SCLK 13 // set these to be whatever pins you like! #define TFT_MOSI 11 // set these to be whatever pins you like! //Adafruit_ST7735 tft = Adafruit_ST7735(TFT_CS, TFT_DC, TFT_MOSI, TFT_SCLK, TFT_RST);
The Example code has 2 options for defining the display object. Uno, Duemilanove and other Atmega 328-based processors can use the "Option 1" version of the constructor for best performance:
Adafruit_ST7735 tft = Adafruit_ST7735(TFT_CS, TFT_DC, TFT_RST);
Mega and Leonardo users should use the "Option 2" version of the constructor for compatibility:
Adafruit_ST7735 tft = Adafruit_ST7735(TFT_CS, TFT_DC, TFT_MOSI, TFT_SCLK, TFT_RST);
Be sure to select only one option and comment out the other with a pair of //'s.
Now upload the sketch to see the graphical display!
Text editor powered by tinymce.