This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

PROCESSOR-SDK-AM437X: 5-wire touchscreen issue

Part Number: PROCESSOR-SDK-AM437X
Other Parts Discussed in Thread: AM4379

Hi,

We connect touchscreen 5 pins to AM4379 ADC0 5 input  channels as following:

AIN0-XP, AIN1-XN, AIN2-YP, AIN3-YN, AIN4-WIPER

Then  modified tscadc in DT file as:

&tscadc {
    status = "okay";
    tsc {
         ti,wires = <5>;
         ti,x-plate-resistance = <80000>;
         ti,coordinate-readouts = <5>;
         ti,wire-config =  <0x00 0x11 0x22 0x33>;
         ti,charge-delay = <0xf000000>;
   };
   adc {
         ti,adc-channels = <5 6 7>;
   };

};
When click the screen, the cursor position can move following the click with ts_test. but it can sometimes give a false cursor position except the click position(one click, give two positions, as if quickly click two times).

If click the screen quickly , it give the false position more often. It appear about 1 false position every 40 times click under normal  click operation with above tscadc setting.

We change the x-plate-resistance from 300 to 100000 and chrge-delay from 800 to f00000, but we can not get a desired result.

We test the touchscren  with USB driver, it is stable..

Our SDK is sdk-05.01.00.11. linux version is 4.14.67,

Best Regards,

Dudechao

  • Hello Dudechao,

    Could you clarify what you mean by "false position"? Do you see this issue when using a stylus, or only when using a finger?

    Regards,

    Nick

  • Hello Nick,

    "false position" I mean when I click the screen once, the cursor moved to  two or more  other positions except the pointed position. the other positions I called the false position.

     For example, when I click the screen in position A, the cursor appear in position B, then return to position A.  the B is different with A and not clicked there. the position B I called the false position.

    No matter whether I using a stylus or a finger, the phenomenon is the same.

    Best Regards!

    Dudechao

  • Hello Nick,

    Can you help us debug the 5-wire touchscreen which is beyond our capacity? We can do any test as you need.

     I'm look forward to your help!

    Best Regards!

    Dudechao

  • Hello Dudechao,

    I apologize for the delayed response. I am checking with the developers now.

    "We test the touchscreen  with USB driver, it is stable" - Do you mean that a USB mouse works as expected? Or do you mean something else?

    Regards,

    Nick

  • Hello Nick,

    Thank you for your response!

    "We Test the touchscreen with USB driver, it is stable", I only verifiy  that the touchscreen is correct with USB. and judge the problem is in the tscadc mouse driver, not the touchscreen self.

    USB mouse works as expected.   

    Best Regards,

    Dudechao

  • Hello Nick,

    We are still waitting for your support.

    We are using  USB mouse without the 5-wire touch driver now, but it need a hardware driver and occupy a   extra space which is not suitable for our product.

    We can do any test as you need for the 5-wire touch driver.

    Thank you.

    Best Regard,

    Dudechao.

  • Hello Dudechao,

    From a hardware standpoint:
    Are the digital lines of the LCD on a separate strip from the analog lines of the touchscreen? (the digital and analog lines should not be close to each other)
    Is the touchscreen firmly mounted?

    Could you attach logs of touch coordinates using ts_test? Printing ts_test log to the console adds to the system load, so it is better to redirect the capture to a log file.

    Regards,

    Nick

  • Hello Nick,

    The touchscreen and the displayer are two   separate strips to our board, the touchscreen is 5 analog lines strip to our board and is firmly mounted.

    We attach 4 log files with ts_test:

    1) ts_test_1point.log: click touchscreen only once, this is ok;

    2)ts_test_1point_2cursor.log:click touchscreen only once, but a false cursor appear;

    3)ts_test_always_press.log: press the touchscreen a position and stay there for a moment;

    4)ts_test_four-corners-center.log: click the touchscreen 4 corners and its center(not exactly).

    In 1) 4) cursor are correct ; In 2), the cursor appear two positions with one click; In 3), the cursor is not steady.   

    Best Regards,

    Dudechao

    root@am437x-evm:~# ./ts_test 
    1592976978.524154:    352    403    231
    1592976978.611502:    352    403      0
    ^Csignal 2 caught
    root@am437x-evm:~# 
    
    
    [BEGIN] 2020/6/24 13:40:34
    
    root@am437x-evm:~# 
    root@am437x-evm:~# ./ts_test 
    
    1592977326.366923:    233    609    435
    1592977326.455944:    824    656     11
    1592977326.543303:    824    656      0
    ^Csignal 2 caught
    root@am437x-evm:~# 
    [END] 2020/6/24 13:42:08
    
    [BEGIN] 2020/6/24 13:38:55
    ./ts_test 
    1592977234.563035:    800    202    101
    1592977234.651973:    800    199    136
    1592977234.740986:    800    198    180
    1592977234.829960:    800    198    192
    1592977234.918946:    800    197    147
    1592977235.007942:    800    197    167
    1592977235.096933:    800    198    165
    1592977235.185900:    800    197    168
    1592977235.274889:    800    197    170
    1592977235.363894:    800    198    154
    1592977235.452879:    800    198    134
    1592977235.541878:    799    198    129
    1592977235.630863:    800    197    175
    1592977235.719850:    800    197    176
    1592977235.808846:    799    197    125
    1592977235.897836:    800    197    175
    1592977235.986827:    800    197    127
    1592977236.164802:    799    198    249
    1592977236.253805:    800    198    243
    1592977236.342788:    800    198    156
    1592977236.431781:    800    198    165
    1592977236.520775:    800    198     74
    1592977236.609758:    800    198     34
    1592977236.698756:    800    197     75
    1592977236.787745:    800    197     88
    1592977236.876728:    799    197    131
    1592977236.965741:    800    197    171
    1592977237.054728:    800    197    190
    1592977237.143725:    800    197    158
    1592977237.232710:    800    197    111
    1592977237.321703:    800    197     95
    1592977237.410706:    800    197     77
    1592977237.499693:    800    197    158
    1592977237.588686:    800    197    192
    1592977237.677670:    800    197    175
    1592977237.766663:    800    197    220
    1592977237.855700:    799    197    234
    1592977237.944691:    800    197    218
    1592977238.033691:    800    197    168
    1592977238.122693:    800    197    135
    1592977238.211681:    800    197    247
    1592977238.300670:    800    197    178
    1592977238.389661:    800    197    173
    1592977238.478648:    800    197    225
    1592977238.567640:    800    197    175
    1592977238.656634:    800    197    174
    1592977238.745626:    800    197    179
    1592977238.834618:    800    197    147
    1592977238.923608:    800    197    247
    1592977239.012599:    800    197    275
    1592977239.101589:    800    197    245
    1592977239.190577:    800    197    192
    1592977239.279563:    800    197    107
    1592977239.368544:    800    197     67
    1592977239.457549:    800    197     38
    1592977239.546545:    800    197     74
    1592977239.635508:    800    197    160
    1592977239.724497:    800    197    262
    1592977239.813459:    800    197    194
    1592977239.902452:    800    197    267
    1592977239.991443:    800    197    352
    1592977240.080434:    800    197    264
    1592977240.169424:    800    197    263
    1592977240.258415:    800    197    217
    1592977240.345775:    800    198      0
    ^Csignal 2 caught
    root@am437x-evm:~# 
    [END] 2020/6/24 13:40:27
    
    [BEGIN] 2020/6/24 13:36:56
    ./ts_test 
    1592977096.090765:     20     62    133
    1592977096.179746:     17     62    338
    1592977096.267084:     15     62      0
    1592977097.160598:    991     74    355
    1592977097.249585:    991     74    183
    1592977097.336944:    991     74      0
    1592977098.036505:   1007    745    268
    1592977098.125457:   1007    746    356
    1592977098.212817:   1007    746      0
    1592977099.071811:      0    732    143
    1592977099.160794:      0    730    138
    1592977099.248162:      0    729      0
    1592977099.960544:    493    346     52
    1592977100.049537:    490    345    287
    1592977100.136892:    488    344      0
    ^Csignal 2 caught
    root@am437x-evm:~# 
    [END] 2020/6/24 13:38:06
    

  • Hello Dudechao,

    I am guessing that for 2), the correct location was (233,609) and the false cursor was at (824, 656)? Do the false cursor positions always have a relatively small pressure value?

    Regards,

    Nick

  • Hello Nick,

    Yes, the correct location was (233,609), (824,656) is the false cursor position.

    We do the test for the false cursor appear several times, it is  true that the false cursor position have a relatively small pressures value.

    Best Regards

    Dudechao

  • Hello Dudechao,

    Please take a look at tslib's filters to see if any of them are of use. E.g., small pressure values could be filtered out with https://github.com/libts/tslib#module-pthres . There are a couple of other filters (like debounce) that might be helpful.

    Regards,

    Nick

  • Hello Nick,

    Many thanks for your support.

    We filter out some values with tslib and it works as expected.

    Regards,

    Dudechao