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

How to Use 2" LCD: Examples, Pinouts, and Specs

Image of 2" LCD
Cirkit Designer LogoDesign with 2" LCD in Cirkit Designer

Introduction

The Waveshare 2" LCD, powered by the ST7789V driver, is a compact liquid crystal display designed for visual output in electronic devices. With its vibrant color rendering and high resolution, this display is ideal for applications requiring a small yet high-quality screen. It is commonly used in projects such as portable devices, IoT displays, gaming consoles, and embedded systems.

Explore Projects Built with 2" LCD

Use Cirkit Designer to design, explore, and prototype these projects online. Some projects support real-time simulation. Click "Open Project" to start designing instantly!
Arduino UNO I2C LCD Display Tester with 12V Battery and Step-Down Converter
Image of nigga: A project utilizing 2" LCD in a practical application
This circuit features an Arduino UNO connected to an I2C LCD 16x2 Screen for display purposes. The Arduino is powered by a 12V battery through a step-down converter that reduces the voltage to 5V. The Arduino runs an I2C scanner code to detect devices on the I2C bus, which is used for communication with the LCD.
Cirkit Designer LogoOpen Project in Cirkit Designer
Arduino Nano Controlled LCD Interface with Pushbutton Inputs
Image of MacroDisplay: A project utilizing 2" LCD in a practical application
This circuit features a Nano 3.0 ATmega328P microcontroller connected to a 16x2 I2C LCD display for output. Two pushbuttons, each with a 10k Ohm pull-down resistor, are connected to digital pins D2 and D3 of the microcontroller for input. The LCD and pushbuttons are powered by the 5V output from the microcontroller, and all components share a common ground.
Cirkit Designer LogoOpen Project in Cirkit Designer
Arduino UNO with I2C LCD and Bluetooth Control
Image of Copy of circuit diagram: A project utilizing 2" LCD in a practical application
This circuit features an Arduino UNO connected to an I2C LCD screen for display and an HC-05 Bluetooth module for wireless data communication. It includes flex resistors potentially used for sensing applications, with pull-up resistors to maintain signal integrity.
Cirkit Designer LogoOpen Project in Cirkit Designer
Arduino UNO and 16x2 I2C LCD Display Interface for Data Visualization
Image of lcd: A project utilizing 2" LCD in a practical application
This circuit consists of an Arduino UNO microcontroller connected to a 16x2 I2C LCD display. The Arduino UNO provides power and I2C communication to the LCD, allowing it to display information controlled by the Arduino.
Cirkit Designer LogoOpen Project in Cirkit Designer

Explore Projects Built with 2" LCD

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 nigga: A project utilizing 2" LCD in a practical application
Arduino UNO I2C LCD Display Tester with 12V Battery and Step-Down Converter
This circuit features an Arduino UNO connected to an I2C LCD 16x2 Screen for display purposes. The Arduino is powered by a 12V battery through a step-down converter that reduces the voltage to 5V. The Arduino runs an I2C scanner code to detect devices on the I2C bus, which is used for communication with the LCD.
Cirkit Designer LogoOpen Project in Cirkit Designer
Image of MacroDisplay: A project utilizing 2" LCD in a practical application
Arduino Nano Controlled LCD Interface with Pushbutton Inputs
This circuit features a Nano 3.0 ATmega328P microcontroller connected to a 16x2 I2C LCD display for output. Two pushbuttons, each with a 10k Ohm pull-down resistor, are connected to digital pins D2 and D3 of the microcontroller for input. The LCD and pushbuttons are powered by the 5V output from the microcontroller, and all components share a common ground.
Cirkit Designer LogoOpen Project in Cirkit Designer
Image of Copy of circuit diagram: A project utilizing 2" LCD in a practical application
Arduino UNO with I2C LCD and Bluetooth Control
This circuit features an Arduino UNO connected to an I2C LCD screen for display and an HC-05 Bluetooth module for wireless data communication. It includes flex resistors potentially used for sensing applications, with pull-up resistors to maintain signal integrity.
Cirkit Designer LogoOpen Project in Cirkit Designer
Image of lcd: A project utilizing 2" LCD in a practical application
Arduino UNO and 16x2 I2C LCD Display Interface for Data Visualization
This circuit consists of an Arduino UNO microcontroller connected to a 16x2 I2C LCD display. The Arduino UNO provides power and I2C communication to the LCD, allowing it to display information controlled by the Arduino.
Cirkit Designer LogoOpen Project in Cirkit Designer

Common Applications and Use Cases

  • Portable electronic devices
  • IoT dashboards and status displays
  • Wearable technology
  • DIY gaming consoles
  • Educational and prototyping projects
  • Arduino and Raspberry Pi-based projects

Technical Specifications

The following table outlines the key technical details of the Waveshare 2" LCD:

Specification Details
Display Type TFT LCD
Driver IC ST7789V
Screen Size 2 inches
Resolution 240 x 320 pixels
Color Depth 65K/262K colors
Interface SPI (4-wire)
Operating Voltage 3.3V
Backlight LED
Viewing Angle Wide-angle
Dimensions 40.4mm x 34.8mm
Operating Temperature -20°C to 70°C

Pin Configuration and Descriptions

The Waveshare 2" LCD features an 8-pin interface. Below is the pinout and description:

Pin Name Description
1 GND Ground connection
2 VCC Power supply (3.3V)
3 SCL Serial Clock Line (SPI clock input)
4 SDA Serial Data Line (SPI data input)
5 RES Reset pin (active low)
6 DC Data/Command control pin
7 BL Backlight control (active high)
8 CS Chip Select (active low)

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 Interface: 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 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 the display.
  4. Backlight: The BL pin can be connected to 3.3V or controlled via PWM for adjustable brightness.

Important Considerations and Best Practices

  • Voltage Levels: Ensure all input signals are 3.3V logic. Use level shifters if your microcontroller operates at 5V.
  • SPI Speed: Configure the SPI clock speed according to the ST7789V datasheet to avoid communication errors.
  • Reset Sequence: Always perform a reset sequence during initialization to ensure proper operation.
  • Backlight Control: Use a current-limiting resistor or PWM to control the backlight brightness and extend its lifespan.

Example Code for Arduino UNO

Below is an example of how to interface the Waveshare 2" LCD with an Arduino UNO using the Adafruit GFX and Adafruit ST7789 libraries:

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

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

// Initialize the display object
Adafruit_ST7789 tft = Adafruit_ST7789(TFT_CS, TFT_DC, TFT_RST);

void setup() {
  // Initialize serial communication for debugging
  Serial.begin(9600);
  Serial.println("Initializing display...");

  // Initialize the display
  tft.init(240, 320); // Initialize with 240x320 resolution
  tft.setRotation(1); // Set display orientation (1 = landscape)

  // Fill the screen with a color
  tft.fillScreen(ST77XX_BLUE);

  // Display a message
  tft.setTextColor(ST77XX_WHITE);
  tft.setTextSize(2);
  tft.setCursor(10, 10);
  tft.println("Hello, World!");
}

void loop() {
  // Add your code here for dynamic updates
}

Note: Install the Adafruit GFX and Adafruit ST7789 libraries via the Arduino Library Manager before running the code.

Troubleshooting and FAQs

Common Issues and Solutions

  1. No Display Output:

    • Verify all connections, especially power (VCC and GND) and SPI pins.
    • Ensure the CS pin is correctly toggled to enable the display.
    • Check the reset sequence in your code.
  2. Flickering or Distorted Graphics:

    • Reduce the SPI clock speed to improve signal integrity.
    • Ensure proper grounding and minimize noise in the circuit.
  3. Backlight Not Working:

    • Confirm the BL pin is connected to 3.3V or a PWM signal.
    • Check for a faulty backlight LED.
  4. Incorrect Colors or Orientation:

    • Verify the initialization code and ensure the correct rotation is set.
    • Check the color format (RGB565) used in your graphics library.

FAQs

Q: Can I use this display with a 5V microcontroller?
A: Yes, but you must use level shifters to convert 5V logic to 3.3V for the SPI and control pins.

Q: What is the maximum SPI clock speed supported?
A: The ST7789V supports SPI clock speeds up to 15 MHz. However, lower speeds may be required for longer cables or noisy environments.

Q: Can I control the backlight brightness?
A: Yes, you can use a PWM signal on the BL pin to adjust the brightness.

Q: Is this display compatible with Raspberry Pi?
A: Yes, the display can be used with Raspberry Pi via the SPI interface. Use libraries like luma.lcd or ST7789-python for easier integration.