So i have a little touchscreen ripped out of an old palm zire 32(broken) PDA, It Has 4 Tiny Wires.
I know the basics of using it, You Put 5V to One side off the touch screen, and measure voltage on the other end, For both X and Y Coordinates.
But that is not as easy as it sounds, So what i ask is, Is there any library/Example/ Some way to accurately calculate an X Y coordinate from the 0-1000(it wasn't 1000 its a bit more) that is returned from analogread for the X and Y coordinates?
Thanks
I know nothing on your touchscreen, but just use a multimeter to see how the output of a pin changes when you apply voltage to another and then move your finger? If it works as a simple voltage divider, connecting the output pins to the analog ports on the Arduino should do the job.
And if you don't get a response in these forums, it's usually because people don't know it!
the more information you post the more likely you are to get an answer. post some pictures, some measurements, anything. give us some more to work with. also, please dont act like you deserve an answer. alot of good people here donate their personal time to help others. try to be more patient and appreciative.
the more information you post the more likely you are to get an answer. post some pictures, some measurements, anything. give us some more to work with. also, please dont act like you deserve an answer. alot of good people here donate their personal time to help others. try to be more patient and appreciative.
Sorry about that...I tend to be a little impatient at times...
I know nothing on your touchscreen, but just use a multimeter to see how the output of a pin changes when you apply voltage to another and then move your finger? If it works as a simple voltage divider, connecting the output pins to the analog ports on the Arduino should do the job.
And if you don't get a response in these forums, it's usually because people don't know it!
Good point, Thanks, I will try that, The problem is...I don't have a multimeter(at the moment...)
Anyways, i think i got it figured out.
What i could do is put 5V on both ends of the touchscreen(corners) and measure the input with analog read(other corners), and then map it to a lower value, say 0-256, and use it that way for both X and Y.
Before I respond to your post, may I ask your age?
You can solder wires directly to the TS connector by using an exacto type knife and cutting between the leads/wires. See the following image for an example:
I made myself this for guidance, the touchscreen pin-out is specific to the one i have, and can be determined very easily.
Edit: Picture moved to previous post...Its looks better in a gray background
Oops my bad XD i forgot the pull up(or is that drop down?) resistors too.
I'll fix it later...
Well actually that part(the second image without the resistors that are needed if i do it that way) is optional, it is just that way to not have to recalibrate the screen too much...
There's an AVR application note which you might find interesting if you want to understand what you're doing. Google for
AVR341: Four and five-wire Touch Screen Controller
The note is pretty technical, and the example code for the ATmega88 which is in the zipfile is downright scary. Be brave.
Sorry no that is wrong. You don't need resistors. Did you read the links?
Umm yes i know...I guess i read too fast, Nevermind the last 2 Images, I have an other idea that should work, in theory.
x1 to 5V
x2 to analog 0
y1 to 5v
y2 to analog 1
but i would need pull-down resistors.
I could use the Internal Pull-up resistors and do it this way
x1 to gnd
x2 to analog 0+Using Built in pull-up resistors
y1 to gnd
y2 to analog0+using Built in pull-up resistors
Like so:
then map the 1023-0 values to 0-1023 and then map that to 640,480(or whatever the screen resolution may be, But it would have to be calibrated, my finding the maximum x and y value, and mapping it by that).
Simple i guess...
I'm not too sure if i explained it right...