Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Mobile and Embedded
  4. Tslib with dirverless usb touch module
Forum Updated to NodeBB v4.3 + New Features

Tslib with dirverless usb touch module

Scheduled Pinned Locked Moved Mobile and Embedded
9 Posts 3 Posters 5.4k Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • D Offline
    D Offline
    DasBasti
    wrote on last edited by
    #1

    Hi,

    I have a 'driverless' USB capacitive touch module. On a PC I plug it in and it works under Linux and Windows. It also works on my embedded device (i.MX6) under xorg, but not under QT with -qws

    The touchscreen behaves like a mouse and I have no Idea how to fix it.

    1 Reply Last reply
    0
    • R Offline
      R Offline
      RyderQt
      wrote on last edited by
      #2

      hi DasBasti,

      Does you configure enviroment for Tslib working correctly?
      you should check what your device(touch screen) are recognized by linux PC ? and configure for tslib can understand. By using command ls /dev/input

      In my case, that is event0.

      @export QWS_MOUSE_PROTO=tslib:/dev/input/event0
      export TSLIB_CONSOLEDEVICE=none
      export TSLIB_TSEVENTTYPE=INPUT
      export PATH=/sbin:/usr/sbin:/bin:/usr/bin
      export TSLIB_FBDEVICE=/dev/fb0
      export TSLIB_TSDEVICE=/dev/input/event0
      export TSLIB_PLUGINDIR=usr/lib/ts
      export TSLIB_CONFFILE=/etc/ts.conf
      export TSLIB_CALIBFILE=/etc/pointercal
      export LD_LIBRARY_PATH=/opt/qt-arm/lib:$LD_LIBRARY_PATH@

      Try it and give response :)
      happy coding with Qt

      1 Reply Last reply
      0
      • SGaistS Offline
        SGaistS Offline
        SGaist
        Lifetime Qt Champion
        wrote on last edited by
        #3

        Hi and welcome to devnet,

        What version of Qt are you using ?

        Did you setup tslib properly ?

        Do you have any error message when starting your application ?

        Interested in AI ? www.idiap.ch
        Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

        1 Reply Last reply
        0
        • D Offline
          D Offline
          DasBasti
          wrote on last edited by
          #4

          hi RyderQt

          I tried to use your configuration values. ls /dev/input gave me two event inputs (0 and 1) The USB tochpanel is connected to event1.

          So I have changed QWS_MOUSE_PROTO to "tslib:/dev/input/event1 Auto" to get it back working at all.

          The behaviour si still the same. The Touchpad behaves lke a trackpad or like a mouse. I can move the Cursor back and forth but the curser moves way faster than the finger on the tocuhpad. I think there is something wrong with calibration maybe?

          when I run ts_calibrate I get the error that the device is not a touchscreen, but it does calibrate something
          @
          tslib: Selected device is not a touchscreen (must support BTN_TOUCH events)
          Took 4 samples...
          Top left : X = 358242660 Y = 358053162
          Took 4 samples...
          Top right : X = 358242660 Y = 358053162
          Took 4 samples...
          Bot right : X = 358242660 Y = 358053162
          Took 4 samples...
          Bot left : X = 358242660 Y = 358053162
          Took 4 samples...
          Center : X = 358242660 Y = 358053162
          1.093728 -0.022001 0.022014
          0.220848 -0.016542 0.016552
          Calibration constants: 71678 -1441 1442 14473 -1084 1084 65536
          @

          tslib 1.0 is installed
          qt 4.7.4 is installed
          no errors at start of "fluidlauncher -qws" for example

          1 Reply Last reply
          0
          • SGaistS Offline
            SGaistS Offline
            SGaist
            Lifetime Qt Champion
            wrote on last edited by
            #5

            What kernel module is loaded to handle this device ?

            Interested in AI ? www.idiap.ch
            Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

            1 Reply Last reply
            0
            • D Offline
              D Offline
              DasBasti
              wrote on last edited by
              #6

              I'm not sure this is the correct information but I Hink the driver is usbhid
              @
              /: Bus 01.Port 1: Dev 1, Class=root_hub, Driver=fsl-ehci/1p, 480M
              |__ Port 1: Dev 2, If 0, Class=HID, Driver=usbhid, 12M
              |__ Port 1: Dev 2, If 1, Class=HID, Driver=usbhid, 12M
              @

              1 Reply Last reply
              0
              • R Offline
                R Offline
                RyderQt
                wrote on last edited by
                #7

                Hi DasBasti,

                SGaist wanted to know about your linux kernel version to handle usb touch device. Not infomation you gave us.

                1 Reply Last reply
                0
                • D Offline
                  D Offline
                  DasBasti
                  wrote on last edited by
                  #8

                  ok, linux kernel vesion is 3.0.35

                  1 Reply Last reply
                  0
                  • R Offline
                    R Offline
                    RyderQt
                    wrote on last edited by
                    #9

                    Hi DasBasti,

                    I have same case with you, but i can modify driver of touch screen controller and compile it again.

                    Because you said that your device is "driverless" so i think you should ask your supplier of usb touch screen.

                    hope this help

                    1 Reply Last reply
                    0

                    • Login

                    • Login or register to search.
                    • First post
                      Last post
                    0
                    • Categories
                    • Recent
                    • Tags
                    • Popular
                    • Users
                    • Groups
                    • Search
                    • Get Qt Extensions
                    • Unsolved