Qt 4.8.4 tslib trouble (tslib version?)

  • Hello, I'm new to both Qt and Linux Embedded. I'm trying to get tslib working with Qt on a TI arm AM1808, Embest development board, and I'm struggling a fair bit.

    The target is running prebuilt Angstrom Linux without any modification from my side. tslib version 0.0 0.1.1 is already installed and is working standalone. I copied tslib files from target to build environment, and compiled qt 4.8.4 with this config:

    @./configure -prefix /opt/qt-embedded-e3/ -embedded arm -platform qws/linux-x86-g++ -xplatform qws/linux-arm-AM1808-g++ -depths 16,24,32 -no-mmx -no-3dnow -no-sse -no-sse2 -no-glib -no-cups -no-largefile -no-accessibility -no-openssl -no-gtkstyle -qt-mouse-pc -qt-mouse-linuxtp -qt-mouse-linuxinput -plugin-mouse-linuxtp -plugin-mouse-pc -fast -no-opengl -qt-mouse-tslib -no-webkit -opensource
    mkspec: (rest of mkspec from TI guide++)
    QMAKE_INCDIR += /home/prt/work/tslib/tslib_embest/include/
    QMAKE_LIBDIR += /home/prt/work/tslib/tslib_embest/lib/
    QMAKE_LIBS += -lts

    Compared to cross compile fromtslib v 1.0 /inc /lib have these differences;
    1.0: /lib/pkconfig/ tslib-1.0.pc and tslib.pc
    0.0: /lib/pkconfig/ tslib-0.0.pc

    • I did not copy /etc and /bin folder (0.0) from target to build environment.

    @root@sbc8018:~# sh qtenv
    Qt specific environment variables:
    QWS_SIZE =
    QWS_MOUSE_PROTO = Tslib:/dev/input/touchscreen0

    Tslib specific environment variables:
    TSLIB_FBDEVICE = /dev/fb0
    TSLIB_TSDEVICE = /dev/input/touchscreen0
    TSLIB_CONFFILE = /etc/ts.conf
    TSLIB_CALIBFILE = /etc/pointercal
    TSLIB_PLUGINDIR = /lib/ts/

    With these and default environment variables ts_test and ts_calibrate is working standalone. (touchscreen0 is symlink to event1, both of them generates data from touchscreen)

    Running mousecalibrate example:
    root@sbc8018:~# ./mousecalibration -qws
    area # = 0
    QWSTslibMouseHandlerPrivate: ts_open() failed with error: 'Cannot allocate memory'
    Please check your tslib installation!
    QSocketNotifier: Invalid socket 10 and type 'Read', disabling...
    yesterday i also got this error:

    @tps6507x 1-0048: schedule failedQWSTslibMouseHandlerPrivate: ts_open() failed with error: 'Cannot all'
    Please check your tslib installation!
    QSocketNotifier: Invalid socket 10 and type 'Read', disabling...

    After executing ./mousecalibration with error, I get this or similar error when executing ts_test++ standalone, and have to reboot:

    @root@sbc8018:~# ts_test
    /dev/input/touchscreen0: Cannot allocate memory

    I would appreciate I anyone could point me in the right direction.

    What I want to try out is to build qt with tslib 1.0 and deploy tslib 1.0.

    Question 1) Is Qt (4.8.4) dependent on 1.0 tslib version to work?)

    If the tslib version is ok, I'm not shure what could be wrong.
    I have experimented with and checked Environment variables, mkspec, ts.conf and it "should" be correct, I can try to drop other mouse modules in the qt config, or try -L and -I options, if this would help?

    With my lack of Linux experience I can't see if this error is Linux configuration. (again ts_test binaries run standalone)

    Thanks for your time!

  • Update:

    Crosscompiled tslib1.0 from git and did a new build of Qt with similar setting, except that I exluded all other mouse configurations.

    ts_test/config running fine.

    ./mousecalibrate -qws gives common error "segment fault", I have not figured what the cause of this error is.

    Other ordinary qt applications run fine, touch is working.

    I have still no clue of why tslib 0.0.so.0.1.1 did not work. (Version depricated, build/config error from my side)

  • Try adding '-plugin-mouse-tslib' option after '-qt-mouse-tslib'.

    I found that when configuring multiple options intended for runtime selection, the '-plugin' version of the option needed to be included.

    Set QT_DEBUG_PLUGINS=1 as device env var to see tracers of plugin loading details.

Log in to reply

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.