USB HDMI touch screen with Raspberry Pi.

345 views
Skip to first unread message

cjoo...@gmail.com

unread,
Apr 24, 2017, 9:18:25 AM4/24/17
to Kivy users support
Hi, guys.

I just purchased a 7" touch screen from China, which is very similar with Waveshare's.

I installed Kivy on RPi and setting input providers like below:

[input]
mouse = mouse
mtdev_%(name)s = probesysfs,provider=mtdev
hid_%(name)s = probesysfs,provider=hidinput

If I execute sample kivy app, touch screen does not work..

pi@raspberrypi:~ $ python kivy/examples/demo/pictures/main.py
[INFO   ] [Logger      ] Record log in /home/pi/.kivy/logs/kivy_17-04-24_11.txt
[INFO   ] [Kivy        ] v1.9.2.dev0, git-e8f7f3e, 20170424
[INFO   ] [Python      ] v2.7.9 (default, Sep 17 2016, 20:26:04)
[GCC 4.9.2]
[INFO   ] [Factory     ] 194 symbols loaded
[INFO   ] [Image       ] Providers: img_tex, img_dds, img_sdl2, img_pil, img_gif                                                                                                           (img_ffpyplayer ignored)
[INFO   ] [Window      ] Provider: egl_rpi
[INFO   ] [GL          ] Using the "OpenGL ES 2" graphics system
[INFO   ] [GL          ] Backend used <gl>
[INFO   ] [GL          ] OpenGL version <OpenGL ES 2.0>
[INFO   ] [GL          ] OpenGL vendor <Broadcom>
[INFO   ] [GL          ] OpenGL renderer <VideoCore IV HW>
[INFO   ] [GL          ] OpenGL parsed version: 2, 0
[INFO   ] [GL          ] Shading version <OpenGL ES GLSL ES 1.00>
[INFO   ] [GL          ] Texture max size <2048>
[INFO   ] [GL          ] Texture max units <8>
[INFO   ] [Shader      ] fragment shader: <Compiled>
[INFO   ] [Shader      ] vertex shader: <Compiled>
[INFO   ] [Window      ] virtual keyboard not allowed, single mode, not docked
[INFO   ] [GL          ] NPOT texture support is available
[INFO   ] [Text        ] Provider: sdl2
[INFO   ] [GL          ] Unpack subimage support is available
[INFO   ] [OSC         ] using <multiprocessing> for socket
[INFO   ] [ProbeSysfs  ] device match: /dev/input/event0
[INFO   ] [MTD         ] Read event from </dev/input/event0>
[INFO   ] [ProbeSysfs  ] device match: /dev/input/event1
[INFO   ] [MTD         ] Read event from </dev/input/event1>
[INFO   ] [ProbeSysfs  ] device match: /dev/input/event0
[INFO   ] [HIDInput    ] Read event from </dev/input/event0>
[INFO   ] [ProbeSysfs  ] device match: /dev/input/event1
[INFO   ] [HIDInput    ] Read event from </dev/input/event1>
[INFO   ] [Base        ] Start application main loop
[INFO   ] [MTD         ] </dev/input/event0> range position X is 0 - 4095
[INFO   ] [MTD         ] </dev/input/event0> range position Y is 0 - 4095
[INFO   ] [MTD         ] </dev/input/event0> range touch major is 0 - 0
[INFO   ] [MTD         ] </dev/input/event1> range position X is 0 - 1024
[INFO   ] [MTD         ] </dev/input/event0> range touch minor is 0 - 0
[INFO   ] [MTD         ] </dev/input/event1> range position Y is 0 - 600
[INFO   ] [HIDMotionEvent] using <ADS7846 Touchscreen>
[INFO   ] [MTD         ] </dev/input/event0> range pressure is 0 - 255
[INFO   ] [MTD         ] </dev/input/event1> range touch major is 0 - 0
[INFO   ] [HIDMotionEvent] <ADS7846 Touchscreen> range ABS X position is 0 - 409                                                                                                          5
[INFO   ] [HIDMotionEvent] using <深圳市全动电子技术有限公司 ByQDtech 触控USB鼠                                                                                                          标>
[INFO   ] [MTD         ] </dev/input/event0> axes invertion: X is 0, Y is 0
[INFO   ] [MTD         ] </dev/input/event1> range touch minor is 0 - 0
[INFO   ] [HIDMotionEvent] <ADS7846 Touchscreen> range ABS Y position is 0 - 409                                                                                                          5
[INFO   ] [MTD         ] </dev/input/event0> rotation set to 0
[INFO   ] [HIDMotionEvent] <深圳市全动电子技术有限公司 ByQDtech 触控USB鼠标> ran                                                                                                          ge ABS X position is 0 - 1024
[INFO   ] [MTD         ] </dev/input/event1> range pressure is 0 - 255
[INFO   ] [HIDMotionEvent] <ADS7846 Touchscreen> range ABS pressure is 0 - 65535
[INFO   ] [HIDMotionEvent] <深圳市全动电子技术有限公司 ByQDtech 触控USB鼠标> ran                                                                                                          ge ABS Y position is 0 - 600
[INFO   ] [MTD         ] </dev/input/event1> axes invertion: X is 0, Y is 0
[INFO   ] [HIDMotionEvent] <深圳市全动电子技术有限公司 ByQDtech 触控USB鼠标> ran                                                                                                          ge position X is 0 - 1024
[INFO   ] [MTD         ] </dev/input/event1> rotation set to 0
[INFO   ] [HIDMotionEvent] <深圳市全动电子技术有限公司 ByQDtech 触控USB鼠标> ran                                                                                                          ge position Y is 0 - 600
 Exception in thread Thread-4:
 Traceback (most recent call last):
   File "/usr/lib/python2.7/threading.py", line 810, in __bootstrap_inner
     self.run()
   File "/usr/lib/python2.7/threading.py", line 763, in run
     self.__target(*self.__args, **self.__kwargs)
   File "/usr/local/lib/python2.7/dist-packages/kivy/input/providers/hidinput.py                                                                                                          ", line 683, in _thread_run
     data = fd.read(struct_input_event_sz)
 IOError: [Errno 19] No such device

Sometimes it works without this error above, and sometimes error occurs.

What is the correct configuration value for this touch screen?

Please help me.

Reply all
Reply to author
Forward
0 new messages