Cirkit Designer LogoCirkit DesignerYour all-in-one circuit design IDE Launch Cirkit Designer App

How to Use 1.8 TFT SPI display : Examples, Pinouts, and Specs

Image of 1.8 TFT SPI display Design with 1.8 TFT SPI display in Cirkit Designer

Introduction

The 1.8-inch TFT SPI Display (Manufacturer: SIP, Part ID: 128*160 V1.1) is a compact, high-resolution thin-film transistor (TFT) display module designed for use in embedded systems. It features a 128x160 pixel resolution and supports 65K colors, making it ideal for displaying vibrant graphics, images, and text. The display communicates via the Serial Peripheral Interface (SPI), which ensures fast and efficient data transfer while minimizing the number of required pins.

Explore Projects Built with 1.8 TFT SPI display

Use Cirkit Designer to design, explore, and prototype these projects online. Some projects support real-time simulation. Click "Open Project" to start designing instantly!
Image of ESP32-S3 Controlled ILI9488 TFT LCD Display Interface: A project utilizing 1.8 TFT SPI display  in a practical application
ESP32-S3 Controlled ILI9488 TFT LCD Display Interface

This circuit connects an ESP32-S3 microcontroller to an ILI9488 TFT LCD display for graphical output. The ESP32-S3 uses SPI communication to send data to the display, with additional GPIOs for control signals like reset, data/command selection, and touch panel control. The provided code initializes the display and demonstrates basic drawing functions such as text, lines, rectangles, and circles.

Open Project in Cirkit Designer

Common Applications and Use Cases

Technical Specifications

Below are the key technical details for the 1.8-inch TFT SPI Display:

Parameter Value
Display Type TFT (Thin-Film Transistor)
Resolution 128 x 160 pixels
Color Depth 65K colors (16-bit RGB)
Communication Protocol SPI (Serial Peripheral Interface)
Operating Voltage 3.3V (logic)
Backlight Voltage 3.3V to 5V
Current Consumption ~50mA (with backlight on)
Dimensions 1.8 inches (diagonal)
Controller IC ST7735

Pin Configuration and Descriptions

The display module has the following pinout:

Pin Name Pin Number Description
GND 1 Ground connection
VCC 2 Power supply (3.3V or 5V for backlight)
SCL 3 Serial Clock (SPI clock input)
SDA 4 Serial Data (SPI data input)
RES 5 Reset pin (active low, used to reset the display)
DC 6 Data/Command pin (used to distinguish between data and command instructions)
CS 7 Chip Select (active low, enables communication with the display)
BLK 8 Backlight control (connect to GND to turn off or VCC to turn on the backlight)

Usage Instructions

How to Use the Component in a Circuit

  1. Power Supply: Connect the VCC pin to a 3.3V or 5V power source and the GND pin to ground.
  2. SPI Communication: Connect the SCL (clock) and SDA (data) pins to the corresponding SPI pins on your microcontroller.
  3. Control Pins:
    • Connect the RES pin to a GPIO pin on your microcontroller for resetting the display.
    • Use the DC pin to toggle between data and command modes.
    • Connect the CS pin to a GPIO pin to enable or disable communication with the display.
  4. Backlight: Connect the BLK pin to VCC to enable the backlight or to GND to disable it.

Important Considerations and Best Practices

Example Code for Arduino UNO

Below is an example of how to use the 1.8-inch TFT SPI Display with an Arduino UNO:

#include <Adafruit_GFX.h>      // Core graphics library
#include <Adafruit_ST7735.h>   // Library for ST7735 display

// Define pin connections
#define TFT_CS     10  // Chip Select pin
#define TFT_RST    9   // Reset pin
#define TFT_DC     8   // Data/Command pin

// Create an instance of the display
Adafruit_ST7735 tft = Adafruit_ST7735(TFT_CS, TFT_DC, TFT_RST);

void setup() {
  // Initialize the display
  tft.initR(INITR_BLACKTAB);  // Initialize with ST7735 Black Tab configuration
  tft.fillScreen(ST77XX_BLACK);  // Clear the screen with black color

  // Display a message
  tft.setTextColor(ST77XX_WHITE);  // Set text color to white
  tft.setTextSize(2);              // Set text size
  tft.setCursor(10, 10);           // Set cursor position
  tft.println("Hello, World!");    // Print text to the display
}

void loop() {
  // Add your code here
}

Troubleshooting and FAQs

Common Issues and Solutions

  1. No Display Output:

    • Verify all connections, especially the SPI pins (SCL, SDA, CS, DC, and RES).
    • Ensure the display is powered correctly (check VCC and GND connections).
    • Confirm that the initialization code matches the display's configuration.
  2. Flickering or Distorted Graphics:

    • Check the SPI clock speed. Reduce the speed if necessary.
    • Ensure proper grounding to avoid noise interference.
  3. Backlight Not Working:

    • Verify the BLK pin connection. It should be connected to VCC for the backlight to turn on.
    • Check the power supply voltage to ensure it meets the display's requirements.
  4. Partial or Incorrect Display:

    • Ensure the correct initialization sequence is used for the ST7735 controller.
    • Verify that the DC pin is toggled correctly between data and command modes.

FAQs

Q: Can I use this display with a 5V microcontroller?
A: Yes, but you must use level shifters to convert the 5V logic signals to 3.3V to avoid damaging the display.

Q: What is the maximum SPI clock speed supported by the display?
A: The display typically supports SPI clock speeds up to 15 MHz, but 4 MHz is a safe starting point for most applications.

Q: Can I control the backlight brightness?
A: Yes, you can use a PWM signal from your microcontroller to control the brightness of the backlight.

Q: Is this display compatible with Raspberry Pi?
A: Yes, the display is compatible with Raspberry Pi. You can use libraries like luma.lcd or ST7735 for Python-based development.