touchscreen tsc2004 android not working

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

touchscreen tsc2004 android not working

2,165件の閲覧回数
pravverma
Contributor III

We are using imx_7.1.2 Android Nougat release for our custom board.

In the custom board tsc2004(12 bit ADC) based touchscreen is used. Screen resolution is 480x272.
So, I have performed the calibration using tslib.

I am able to read the calibrated touch coordinates using getevent(as shown below), but at android GUI, there is no action performing on touching. I am using the tsc2004.c driver came with the kernel release and performing the callibration in driver before sending the coordinates to userspace.


sabresd_6dq:/ # getevent -lp /dev/input/event0
add device 1: /dev/input/event0
name: "TSC200X"
events:

(Touchscreen Top Left value)
KEY (0001): BTN_TOUCH*
ABS (0003):

ABS_X :                   value 13, min 0, max 4095, fuzz 4, flat 0, resolution 0
ABS_Y :                   value 15, min 0, max 4095, fuzz 7, flat 0, resolution 0
ABS_PRESSURE : value 336, min 0, max 2048, fuzz 2, flat 0, resolution 0
input props:
<none>

(Touchscreen Top Right Value)
sabresd_6dq:/ # getevent -lp /dev/input/event0
add device 1: /dev/input/event0
name: "TSC200X"
events:
KEY (0001): BTN_TOUCH*
ABS (0003):

ABS_X :                   value 464, min 0, max 4095, fuzz 4, flat 0, resolution 0
ABS_Y :                   value 14, min 0, max 4095, fuzz 7, flat 0, resolution 0
ABS_PRESSURE :  value 399, min 0, max 2048, fuzz 2, flat 0, resolution 0
input props:
<none>

(Touchscreen Bottom Right Value)
sabresd_6dq:/ # getevent -lp /dev/input/event0
add device 1: /dev/input/event0
name: "TSC200X"
events:
KEY (0001): BTN_TOUCH*
ABS (0003):

ABS_X :             value 462, min 0, max 4095, fuzz 4, flat 0, resolution 0
ABS_Y :             value 250, min 0, max 4095, fuzz 7, flat 0, resolution 0
ABS_PRESSURE : value 307, min 0, max 2048, fuzz 2, flat 0, resolution 0
input props:
<none>

(Touchscreen Bottom Left Value)
sabresd_6dq:/ # getevent -lp /dev/input/event0
add device 1: /dev/input/event0
name: "TSC200X"
events:
KEY (0001): BTN_TOUCH*
ABS (0003):

ABS_X : value 8, min 0, max 4095, fuzz 4, flat 0, resolution 0
ABS_Y : value 247, min 0, max 4095, fuzz 7, flat 0, resolution 0
ABS_PRESSURE : value 299, min 0, max 2048, fuzz 2, flat 0, resolution 0
input props:
<none>

Idc file:

======

sabresd_6dq:/ # cat /system/usr/idc/TSC200X.idc
touch.deviceType = touchScreen
touch.orientationAware = 1

touch.size.calibration = none
touch.orientation.calibration = none


Please help.

Thanks,

Praveen

ラベル(4)
タグ(3)
0 件の賞賛
返信
4 返答(返信)

1,494件の閲覧回数
赵振业
Contributor I

Hi praveen verma :

           I met same issue, Could you tell how to reslove this please.thanks

0 件の賞賛
返信

1,494件の閲覧回数
pravverma
Contributor III

Hi,

There were two things, I found to make it work:

1. No need to callibrate the touchscreen in linux driver. Although driver is sending touch coordinates(0-4096). Android will handle the coordinates accordingly and map the touchscreen to the display resolution.

2. I found that touchscreen was rotated by 90 degree(top left corned cordinates are (0,90) in place of (0,0)). So I modified the driver to correct the coordinate before passing to the userspace.

1,494件の閲覧回数
赵振业
Contributor I

Hi praveen verma :

      Thanks very much,It is helpful for me.

    I made it work now.

0 件の賞賛
返信

1,494件の閲覧回数
diegoadrian
NXP Employee
NXP Employee

Hello,

You can see the below community discussions. Probably some of the information located there can help you.

tsc2004 touchscreen driver on Jelly Bean(JB) jb4.2.1_1.0.0-alpha 

https://community.nxp.com/thread/293210 

I hope some of that information can help you.

Best regards,

Diego.

0 件の賞賛
返信