Setup
- Kivy 1.11.1
- Flask 1.1.1
- Python 2.7.13
Issue
I have an issue running together a Kivy app and Flask as thread on a RPi2 with a touchscreen. It is similar to the issue mentioned in this post Issues with Kivy on Raspberry Pi 3 with 3.5 in Touchscreen with the difference the touch screen works when running the Kivy app only with no Flask in the background. The Kivy+Flask app for the touch screen works on my notebook but when launching it on the RPi2, just hangs forever. No window pops up, nothing.
To exit I have to continuously press CTRL+C and the app loads step by step till finally launch the Kivy app of the touch as supposed.
As one reason I have checked the input interface issue mentioned in this post but I guess does not apply to my case.
UPDATE -> Output of the notebook:
[INFO ] [Base ] Leaving application in progress...
(py2) parovelb@Latitude-E6510:~/Desktop/Python2$ python cs_flask_tft_20191219.py
[INFO ] [Logger ] Record log in /home/parovelb/.kivy/logs/kivy_19-12-19_1.txt
[INFO ] [Kivy ] v1.10.1
[INFO ] [Python ] v2.7.15rc1 (default, Nov 12 2018, 14:31:15)
[GCC 7.3.0]
[INFO ] [Factory ] 194 symbols loaded
[INFO ] [Image ] Providers: img_tex, img_dds, img_sdl2, img_pil, img_gif (img_ffpyplayer ignored)
[INFO ] [Text ] Provider: sdl2
Starting Flask app...
(20301) wsgi starting up on http://0.0.0.0:5000
[INFO ] [Window ] Provider: sdl2(['window_egl_rpi'] ignored)
[INFO ] [GL ] Using the "OpenGL" graphics system
[INFO ] [GL ] Backend used <gl>
[INFO ] [GL ] OpenGL version <3.3 (Compatibility Profile) Mesa 19.0.8>
[INFO ] [GL ] OpenGL vendor <nouveau>
[INFO ] [GL ] OpenGL renderer <NVA8>
[INFO ] [GL ] OpenGL parsed version: 3, 3
[INFO ] [GL ] Shading version <3.30>
[INFO ] [GL ] Texture max size <8192>
[INFO ] [GL ] Texture max units <16>
[INFO ] [Window ] auto add sdl2 input provider
[INFO ] [Window ] virtual keyboard not allowed, single mode, not docked
[INFO ] [Base ] Start application main loop
[INFO ] [GL ] NPOT texture support is available
Output of the RPi2:
[INFO ] [Logger ] Record log in /home/pi/.kivy/logs/kivy_19-12-19_5.txt
[INFO ] [Kivy ] v1.11.1
[INFO ] [Kivy ] Installed at "/home/pi/.virtualenvs/py2/local/lib/python2.7/site-packages/kivy/__init__.pyc"
[INFO ] [Python ] v2.7.13 (default, Sep 26 2018, 18:42:22)
[GCC 6.3.0 20170516]
[INFO ] [Python ] Interpreter at "/home/pi/.virtualenvs/py2/bin/python"
[WARNING] [Deprecated ] Python 2 Kivy support has been deprecated. The Kivy release after 1.11.0 will not support Python 2 anymore
[INFO ] [Factory ] 184 symbols loaded
[INFO ] [Image ] Providers: img_tex, img_dds, img_pil, img_gif (img_sdl2, img_ffpyplayer ignored)
[INFO ] [Text ] Provider: sdl2(['text_pango'] ignored)
Starting Flask app...
(2950) wsgi starting up on http://0.0.0.0:5000
[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 ] [Window ] virtual keyboard not allowed, single mode, not docked
[INFO ] [ProbeSysfs ] device match: /dev/input/event5
[INFO ] [MTD ] Read event from </dev/input/event5>
[INFO ] [ProbeSysfs ] device match: /dev/input/event3
[INFO ] [MTD ] Read event from </dev/input/event3>
[INFO ] [ProbeSysfs ] device match: /dev/input/event1
[INFO ] [MTD ] Read event from </dev/input/event1>
[INFO ] [ProbeSysfs ] device match: /dev/input/event4
[INFO ] [MTD ] Read event from </dev/input/event4>
[INFO ] [ProbeSysfs ] device match: /dev/input/event2
[INFO ] [MTD ] Read event from </dev/input/event2>
[INFO ] [ProbeSysfs ] device match: /dev/input/event0
[INFO ] [MTD ] Read event from </dev/input/event0>
[INFO ] [ProbeSysfs ] device match: /dev/input/event5
[INFO ] [HIDInput ] Read event from </dev/input/event5>
[INFO ] [ProbeSysfs ] device match: /dev/input/event3
[INFO ] [HIDInput ] Read event from </dev/input/event3>
[INFO ] [ProbeSysfs ] device match: /dev/input/event1
[INFO ] [HIDInput ] Read event from </dev/input/event1>
[INFO ] [ProbeSysfs ] device match: /dev/input/event4
[INFO ] [HIDInput ] Read event from </dev/input/event4>
[INFO ] [ProbeSysfs ] device match: /dev/input/event2
[INFO ] [HIDInput ] Read event from </dev/input/event2>
[INFO ] [ProbeSysfs ] device match: /dev/input/event0
[INFO ] [HIDInput ] Read event from </dev/input/event0>
[INFO ] [Base ] Start application main loop
[INFO ] [MTD ] </dev/input/event5> range position X is 0 - 0
[INFO ] [MTD ] </dev/input/event5> range position Y is 0 - 0
[INFO ] [MTD ] </dev/input/event5> range touch major is 0 - 0
[INFO ] [MTD ] </dev/input/event5> range touch minor is 0 - 0
[INFO ] [MTD ] </dev/input/event5> range pressure is 0 - 255
[INFO ] [MTD ] </dev/input/event5> axes invertion: X is 0, Y is 0
[INFO ] [MTD ] </dev/input/event5> rotation set to 0
Any ideas? GIL?