* 1.8-inch SPI serial screen with backplane module, requires at least 4 IO drivers
* Size: 1.8 inch SPI serial bus
* Resolution: 128*160
* Driver IC: ST7735
* The features of this module:
* 1. Support Arduino various MCU in-line without any wiring
* 2. Integrated voltage regulator IC, support 5V or 3.3V power supply
* 3. Onboard level shifting scheme, truly compatible with 5V/3.3V IO level. Support a variety of microcontroller IO connections
* 4. Integrated SD card expansion circuit,
* 5. Reserve SPI FLASH font circuit to facilitate extended application
I found this pinout table :
Number
Pin Label
Description
1
VCC
5V/3.3V power input
2
GND
Ground
3
CS
LCD chip select signal, low level enable
5
A0
LCD register / data selection signal, high level: register, low level: data
6
SDA
SPI bus write data signal
7
SCK
SPI bus clock signal
8
LED
Backlight control, high level lighting, if not controlled, connect 3.3V always bright
I also tried the following code with ESPHome but the screen remains white:
# Display stuff
# SPI and ST7735 160x80 display
# https://esphome.io/components/display/st7735.html
spi:
clk_pin: D5
mosi_pin: D7
display:
- platform: st7735
model: "INITR_BLACKTAB"
reset_pin: D4
cs_pin: D1
dc_pin: D2
rotation: 0
device_width: 160
device_height: 80
col_start: 0
row_start: 0
eight_bit_color: True
use_bgr: True
update_interval: 5s
lambda: |-
// it.print(10, 10, id(mono8), "Hello World!");
// Draw a line from [0,0] to [100,50]
it.line(0, 0, 100, 50);
// Draw the outline of a rectangle with the top left at [50,60], a width of 30 and a height of 42
it.rectangle(50, 60, 30, 42);
// Draw the same rectangle, but this time filled.
it.filled_rectangle(50, 60, 30, 42);
// Circles! Let's draw one with the center at [25,25] and a radius of 10
it.circle(25, 25, 10);
// ... and the same thing filled again
it.filled_circle(25, 25, 10);
As indicated in my post I have the 1.8 Inch TFT Color Screen LCD.
I confirm that this same screen works correctly with an Arduino Nano W module so it’s either a wiring problem on my ESP module or a problem in my configuration.
Adding my own experience for this thread, using a very similar 1.8" 128x160 TFT display. I’ve been trying to get it working using various MCUs, perhaps my experience will help others keep their sanity…
Wemos D1 Mini (original or V3.0.0): display works using ST7735 config (detailed above) but couldn’t get it to work with ILI9xxx. BUT… D1 mini reboots every time I try and read logs (using ESPHome facility) OR send a Wifi command (turn status LED on/off).
Wemos D1 Mini (V4.0.0): can’t get reliable WiFi connection under ESPHome (with/without display config), seems a common problem as detailed under other threads which I wish I’d found days ago .
ESP32-C3mini: display works using ILI9xxx platform config.
My ESP32-C3mini config is “out of the box”, with display sections of config below:
time:
- platform: homeassistant
id: homeassistant_time
spi:
clk_pin: GPIO4 # SCK on display
mosi_pin: GPIO6 # SDA on display
font:
- file: "fonts/RobotoCondensed-Regular.ttf"
id: font_r
size: 12
display:
- platform: ili9xxx
# 1.8" TFT display (red board) 128x160
model: ST7735
invert_colors: false
show_test_card: False
reset_pin: GPIO1 # Reset on display
cs_pin: GPIO2 # CS on display
dc_pin: GPIO0 # A0 on display
rotation: 0
update_interval: 5s
lambda: |-
auto black = Color(0, 0, 0);
auto red = Color(255, 0, 0);
auto green = Color(0, 255, 0);
auto blue = Color(0, 0, 255);
auto white = Color(255, 255, 255);
// Write some text
it.print(10, 10, id(font_r), "Hello World!");
it.strftime(100, 10, id(font_r), "%H:%M", id(homeassistant_time).now());
// Draw a circle in the middle of the display
it.filled_circle(it.get_width() / 2, it.get_height() / 2, 20, red);