Hi
Guys, trying to figue out for few days now,i have a display with resistive touch, problem is, that display is working fine, i`m using hardware mega spi pins, and utouch library for touch.
The problem is that i only receiving through serial coordinates x319, y 239.
Does any one came across any other library that might work with XPT2046, or is there any way i can use utouch?? tried calibration etc nothing works, i thought that this is hardware fault, but tried allready 3 different displays with the same chip and problem seems to be permanent.
My basic code to check touch:
#include <UTouch.h>
UTouch myTouch( 14,15,16,17,18);
int x, y;
void setup()
{
Serial.begin(9600);
myTouch.InitTouch();
myTouch.setPrecision(PREC_LOW);
}
void loop()
{
while(true)
{
if (myTouch.dataAvailable())
{
myTouch.read();
x=myTouch.getX();
y=myTouch.getY();
Serial.print("x: ");
Serial.print(x);
Serial.print(" y: ");
Serial.println(y);
delay(100);
}
}
}
Also found this library, but don`t know how to use is as there is no examples for it.
Someone suggest to use ADS7846
thanks for any help.