In this tutorial we are going to change the ST7735 SPI LCD Backlight brightness using a potentiometer & Arduino.
Watch the video!
Step 1: What You Will Need
- Arduino UNO (Or any other Arduino)
- LCD Display TFT 7735
- Potentiometer module
- 68 ohm Resistor (LCD Backlight draws around 30mA)
- Jumper wires
- Visuino program: Download Visuino
Step 2: Brought by PCBWay
Thank you PCBWay for supporting this tutorial and helping users learn more about electronics.
What I like about the PCBWay is that you can get 10 boards for approximately $5 which is really cost effective for professional made boards, not to mention how much time you save!
Go check them out here. They also offer a lot of other stuff in case you might need it like assembly, 3D printing, CNC machining and a lot more.
Step 3: The Circuit
LCD TFT ST7735
- Arduino PWM Digital PIN  to 68ohm Resistor
- 1.8 TFT Display PIN [LED] to 68ohm Resistor
- 1.8 TFT Display PIN [SCK] to Arduino PIN 
- 1.8 TFT Display PIN [SDA] to Arduino PIN 
- 1.8 TFT Display PIN [A0 or DC] to Arduino PIN 
- 1.8 TFT Display PIN [RESET] to Arduino PIN 
- 1.8 TFT Display PIN [CS] to Arduino PIN 
- 1.8 TFT Display PIN [GND] to Arduino PIN [GND]
- 1.8 TFT Display PIN [VCC] to Arduino PIN [5V]
NOTE: Some Arduino boards have different SPI pins so make sure you check your board documentation.
- Connect potentiometer pin [DTA] to arduino analog pin [A0]
- Connect potentiometer pin [VCC] to arduino pin [5V]
- Connect potentiometer pin [GND] to arduino pin [GND]
Step 4: Start Visuino, and Select the Arduino UNO Board Type
The Visuino: https://www.visuino.eu also needs to be installed. Download Free version or register for a Free Trial.
Start Visuino as shown in the first picture Click on the “Tools” button on the Arduino component (Picture 1) in Visuino When the dialog appears, select “Arduino UNO” as shown on Picture 2
Step 5: In Visuino Add & Set Components
- Add “TFT Color Display ST7735” component
Note: In case the display would not work try changing the Type under the properties window
- Double click on the “Display1” and in the “Elements” window
- Drag “Draw Text” to the left side and in the properties window set “Size to 3, “Text” to HELLO and “Y” to 20
- Drag “Draw Bitmap” to the left side and in the properties window set “Y” to 50 and select “Bitmap” and click on the 3 dots button
- In the “Bitmap Editor” click on the “Load” button and load the bitmap file in this case it was Visuino-logo.png
- Click “Ok” button to Close the “Bitmap Editor” window
- Close the “Elements” window
Step 6: In Visuino Connect Components
- Connect “Display1” component pin [Out] to Arduino pin SPI [In]
- Connect “Display1” component pin [Chip Select] to Arduino Digital pin
- Connect “Display1” component pin [Reset] to Arduino Digital pin
- Connect “Display1” component pin [Register Select] to Arduino Digital pin
- Connect Arduino Analog pin  to Arduino digital pin 
Step 7: Generate, Compile, and Upload the Arduino Code
In Visuino, at the bottom click on the “Build” Tab, make sure the correct port is selected, then click on the “Compile/Build and Upload” button.
Step 8: Play
If you power the Arduino UNO module, and change the potentiometer the LCD will start to change its brightness.
Congratulations! You have completed your project with Visuino. Also attached is the Visuino project, that I created for this Instructable, you can download it here and open it in Visuino: https://www.visuino.eu