Cirkit Designer Logo
Cirkit Designer
Your all-in-one circuit design IDE
Home / 
Component Documentation

How to Use 1.54'' TFT Display 240x240 spi ST7789: Examples, Pinouts, and Specs

Image of 1.54'' TFT Display 240x240 spi ST7789
Cirkit Designer LogoDesign with 1.54'' TFT Display 240x240 spi ST7789 in Cirkit Designer

Introduction

The 1.54-inch TFT display is a compact, high-resolution screen with a resolution of 240x240 pixels. It uses the ST7789 driver and communicates via the SPI (Serial Peripheral Interface) protocol. This display is ideal for applications requiring a vibrant and colorful interface in a small form factor, such as smartwatches, IoT devices, handheld instruments, and embedded systems.

Explore Projects Built with 1.54'' TFT Display 240x240 spi ST7789

Use Cirkit Designer to design, explore, and prototype these projects online. Some projects support real-time simulation. Click "Open Project" to start designing instantly!
ESP32-Powered 1.3 inch TFT Display Module for Visual Data Output
Image of ESP32+ST7789: A project utilizing 1.54'' TFT Display 240x240 spi ST7789 in a practical application
This circuit connects an ESP32 microcontroller to a 1.3 inch TFT display module (ST7789). The ESP32 provides power and control signals to the display, enabling it to show graphical data.
Cirkit Designer LogoOpen Project in Cirkit Designer
ESP32-C6 and ST7735S Display: Wi-Fi Controlled TFT Display Module
Image of ESP32-C6sm-ST7735: A project utilizing 1.54'' TFT Display 240x240 spi ST7789 in a practical application
This circuit features an ESP32-C6 microcontroller interfaced with a China ST7735S 160x128 TFT display. The ESP32-C6 controls the display via SPI communication, providing power, ground, and control signals to render graphics and text on the screen.
Cirkit Designer LogoOpen Project in Cirkit Designer
Arduino Nano Controlled TFT Display with Multiple Pushbuttons
Image of rey: A project utilizing 1.54'' TFT Display 240x240 spi ST7789 in a practical application
This circuit features an Arduino Nano microcontroller connected to a ST7735 128x128 1.44 TFT I2C Color display and multiple pushbuttons. The display is interfaced with the Arduino via digital pins for control signals and SPI pins for data transfer. The pushbuttons are connected to various digital and analog input pins on the Arduino, likely intended for user input to control the display or other functions within the code.
Cirkit Designer LogoOpen Project in Cirkit Designer
ESP32C3-Based Thermal Imaging Camera with TFT Display
Image of MLX90640-XIAO-ESP32-1.3: A project utilizing 1.54'' TFT Display 240x240 spi ST7789 in a practical application
This circuit connects a 1.3 inch TFT Module 240×240 ST7789 display, a GY-MCU90640 thermal camera module, and a XIAO ESP32C3 microcontroller to create a thermal imaging system. The ESP32C3 microcontroller is programmed to read temperature data from the thermal camera, process it, and display a visual representation of the temperature distribution on the TFT screen. The circuit is designed for applications requiring thermal monitoring, such as detecting heat sources or monitoring temperature variations in an environment.
Cirkit Designer LogoOpen Project in Cirkit Designer

Explore Projects Built with 1.54'' TFT Display 240x240 spi ST7789

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+ST7789: A project utilizing 1.54'' TFT Display 240x240 spi ST7789 in a practical application
ESP32-Powered 1.3 inch TFT Display Module for Visual Data Output
This circuit connects an ESP32 microcontroller to a 1.3 inch TFT display module (ST7789). The ESP32 provides power and control signals to the display, enabling it to show graphical data.
Cirkit Designer LogoOpen Project in Cirkit Designer
Image of ESP32-C6sm-ST7735: A project utilizing 1.54'' TFT Display 240x240 spi ST7789 in a practical application
ESP32-C6 and ST7735S Display: Wi-Fi Controlled TFT Display Module
This circuit features an ESP32-C6 microcontroller interfaced with a China ST7735S 160x128 TFT display. The ESP32-C6 controls the display via SPI communication, providing power, ground, and control signals to render graphics and text on the screen.
Cirkit Designer LogoOpen Project in Cirkit Designer
Image of rey: A project utilizing 1.54'' TFT Display 240x240 spi ST7789 in a practical application
Arduino Nano Controlled TFT Display with Multiple Pushbuttons
This circuit features an Arduino Nano microcontroller connected to a ST7735 128x128 1.44 TFT I2C Color display and multiple pushbuttons. The display is interfaced with the Arduino via digital pins for control signals and SPI pins for data transfer. The pushbuttons are connected to various digital and analog input pins on the Arduino, likely intended for user input to control the display or other functions within the code.
Cirkit Designer LogoOpen Project in Cirkit Designer
Image of MLX90640-XIAO-ESP32-1.3: A project utilizing 1.54'' TFT Display 240x240 spi ST7789 in a practical application
ESP32C3-Based Thermal Imaging Camera with TFT Display
This circuit connects a 1.3 inch TFT Module 240×240 ST7789 display, a GY-MCU90640 thermal camera module, and a XIAO ESP32C3 microcontroller to create a thermal imaging system. The ESP32C3 microcontroller is programmed to read temperature data from the thermal camera, process it, and display a visual representation of the temperature distribution on the TFT screen. The circuit is designed for applications requiring thermal monitoring, such as detecting heat sources or monitoring temperature variations in an environment.
Cirkit Designer LogoOpen Project in Cirkit Designer

Common Applications and Use Cases

  • Smartwatches and wearable devices
  • IoT dashboards and status displays
  • Portable gaming consoles
  • Industrial control panels
  • DIY electronics projects with microcontrollers (e.g., Arduino, Raspberry Pi)

Technical Specifications

Key Technical Details

Parameter Value
Display Type TFT (Thin-Film Transistor)
Resolution 240x240 pixels
Driver IC ST7789
Communication Protocol SPI (4-wire)
Operating Voltage 3.3V (logic and backlight)
Backlight LED
Display Colors 65K (16-bit RGB)
Viewing Angle Wide
Operating Temperature -20°C to 70°C
Dimensions 1.54 inches (diagonal)

Pin Configuration and Descriptions

Pin Name Pin Number Description
VCC 1 Power supply input (3.3V recommended)
GND 2 Ground connection
SCL 3 SPI clock line (SCK)
SDA 4 SPI data line (MOSI)
RES 5 Reset pin (active low)
DC 6 Data/Command control pin
BLK 7 Backlight control (connect to 3.3V for always on)

Usage Instructions

How to Use the Component in a Circuit

  1. Power Supply: Connect the VCC pin to a 3.3V power source and the GND pin to ground.
  2. SPI Communication: Connect the SCL (SPI clock) and SDA (SPI 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.
    • Connect the DC pin to a GPIO pin to toggle between data and command modes.
  4. Backlight: Connect the BLK pin to 3.3V for constant backlight or to a PWM-capable GPIO pin for brightness control.

Important Considerations and Best Practices

  • Voltage Levels: Ensure all logic signals are 3.3V. If using a 5V microcontroller (e.g., Arduino UNO), use level shifters to avoid damaging the display.
  • SPI Speed: The ST7789 supports high SPI clock speeds, but start with a moderate speed (e.g., 4 MHz) to ensure stable communication.
  • Initialization: The display requires specific initialization commands to configure the ST7789 driver. Use a compatible library to simplify this process.
  • Backlight Control: Use PWM to adjust the backlight brightness for power savings and better user experience.

Example Code for Arduino UNO

Below is an example of how to use the 1.54'' TFT display with an Arduino UNO using the Adafruit ST7789 library.

#include <Adafruit_GFX.h>    // Core graphics library
#include <Adafruit_ST7789.h> // ST7789 driver library
#include <SPI.h>             // SPI library

// Define pins for the display
#define TFT_CS    10  // Chip select pin (not used, tie to GND)
#define TFT_RST   9   // Reset pin
#define TFT_DC    8   // Data/Command pin

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

void setup() {
  // Initialize serial communication for debugging
  Serial.begin(9600);
  Serial.println("TFT Display Test");

  // Initialize the display
  tft.init(240, 240); // Initialize with 240x240 resolution
  tft.setRotation(0); // Set display orientation

  // Fill the screen with a color
  tft.fillScreen(ST77XX_BLACK);
  tft.setTextColor(ST77XX_WHITE);
  tft.setTextSize(2);
  tft.setCursor(10, 10);
  tft.println("Hello, World!");
}

void loop() {
  // Add your code here to update the display
}

Notes:

  • Install the Adafruit GFX and Adafruit ST7789 libraries via the Arduino Library Manager before running the code.
  • Adjust the TFT_CS, TFT_RST, and TFT_DC pin definitions to match your wiring.

Troubleshooting and FAQs

Common Issues and Solutions

  1. Display Not Turning On:

    • Verify the power connections (VCC and GND).
    • Ensure the backlight pin (BLK) is connected to 3.3V or a PWM signal.
  2. No Output on the Screen:

    • Check the SPI connections (SCL and SDA) and ensure they are correctly wired.
    • Confirm that the RES and DC pins are connected to the correct GPIO pins.
    • Ensure the display initialization code matches the ST7789 driver requirements.
  3. Flickering or Unstable Display:

    • Reduce the SPI clock speed in your code.
    • Check for loose or poor-quality connections.
  4. Incorrect Colors or Artifacts:

    • Verify that the display is initialized in 16-bit color mode.
    • Ensure the data being sent to the display matches the expected format.

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: How do I control the backlight brightness?
A: Connect the BLK pin to a PWM-capable GPIO pin on your microcontroller and use PWM to adjust the brightness.

Q: Is this display compatible with Raspberry Pi?
A: Yes, the display can be used with Raspberry Pi. Use the SPI interface and configure the ST7789 driver in your software.

Q: Can I daisy-chain multiple displays?
A: No, the ST7789 does not support daisy-chaining. Each display requires a separate SPI connection.