Professional Documents
Culture Documents
4-Wire Touch Screen Interfacing With Arduino _ 3 Steps - Instructables
4-Wire Touch Screen Interfacing With Arduino _ 3 Steps - Instructables
4-Wire Touch Screen Interfacing With Arduino _ 3 Steps - Instructables
This tutorial shows How to interface 4-wire touch screen using Arduino. This tutorial is useful for all
microcontrollers to know how to interface Reisistive Touchscreen
Resistive touchscreen displays are composed of multiple layers that are separated by thin spaces.
Pressure applied to the surface of the display by a finger or stylus causes the layers to touch, which
completes electrical circuits and tells the device where the user is touching.
Step 1: Components Required and Connections
Components Required:
1. Touchscreen
2. Arduino UNO R3
3. Connecting wires
Tools Required:
Make Connections:
1. Connect X1 to A0 of arduino
2. Connect X2 to A1 of arduino
3. Connect Y1 to A2 of arduino
4. Connect Y2 to A3 of arduino
Visit my blog.circuits4you.com for step by step guide and more sensors interfacing with arduino
Step 2: How It Works ? and Programming
It works in 2 steps
pinMode(Y1,INPUT);
b. Make Y2 Tristate
pinMode(Y2,INPUT);
digitalWrite(Y2,LOW);
pinMode(X1,OUTPUT); digitalWrite(X1,HIGH);
pinMode(X2,OUTPUT); digitalWrite(X2,LOW);
X = (analogRead(Y1))/(1024/XYresolution);
pinMode(X1,INPUT);
b. Make X2 Tristate
pinMode(X2,INPUT);
digitalWrite(X2,LOW);
pinMode(Y1,OUTPUT);
digitalWrite(Y1,HIGH);
pinMode(Y2,OUTPUT);
digitalWrite(Y2,LOW);
Y = (analogRead(X1))/(1024/Yresolution);
Load the code in arduino and See the results in Serial Monitor