Where to find N900's touch coordinate data?
Hi, does anyone know where to find N900's touch panel's coordinate data? I know N900 uses TSC2005 as its touch panel controller. And I run below command to get some hints. If I want to access the coordinate data in user space, what is the exact file and path? Thanks!
Code:
Nokia-N900:/sys/class/input/input3# dmesg | grep TSC2005 |
Re: Where to find N900's touch coordinate data?
The touch coordinate data should be in file /dev/input/event3, I used below command to show it.
Code:
cat /dev/input/event3 |
Re: Where to find N900's touch coordinate data?
Quote:
e: for example Code:
cat /dev/input/event3 > events.log |
Re: Where to find N900's touch coordinate data?
The values are in a binary format.
Look for input event struct. A simple python script to read and decode the data: Code:
import struct |
Re: Where to find N900's touch coordinate data?
Quote:
|
Re: Where to find N900's touch coordinate data?
Quote:
Hi Nicolai, thank you! Now I can show it correctly. Although I am not familiar with python, but I got hint from your code. |
Re: Where to find N900's touch coordinate data?
Does that report the calibrated or the raw coordinates? (I've read that the N900 watches where you click and notices when you click near but not exactly on a GUI element and then actually hits it and uses that data to correct for any deformations in the input)
|
Re: Where to find N900's touch coordinate data?
Quote:
Hi, I don't know whether it is calibrated or not. The data I got is as below. For the first 3 pairs of data, they seem to be wrong. And the rest ones seem to be right. The bottom-left corner of the screen seems to be the origin of coordinate. Nokia-N900:~# ./catch_touch /dev/input/event3 Reading From : /dev/input/event3 (TSC2005 touchscreen) x = 459 y = 1090665992 x = 459 y = 1090665992 x = 475 y = 1090665992 x = 475 y = 460 x = 475 y = 476 x = 477 y = 476 x = 477 y = 476 x = 3630 y = 476 x = 3630 y = 476 x = 3628 y = 476 x = 3628 y = 3262 x = 3628 y = 3262 |
All times are GMT. The time now is 01:18. |
vBulletin® Version 3.8.8