pythonraspberry-pikivyusbtouch

touchscreen raspberry pi phantom touch (reset fixes)


I am working on a kivy project to create some control panel for a ship (toggle lights etc). One of the screens I am also working on is a navigation using the kivy_garden.mapview. This is the screen where I have an issue with.

The rest of the raspberry pi, screens, etc all work flawlessly with the touchscreen, but to zoom in/out on the navigation screen it just spaces out and appears to have a phone touch somewhere; Deduced by that a single touchpoint will just zoom in/out instead of required two. Keep in mind, all the other buttons (all single touch actions) work flawlessly. unplugging, and replugging the usb cable fixes the issue.

The map is initialized like so:

self.map = MapView(
  map_source=mapsource,
  zoom=14, 
  lat=52.51677023841208, 
  lon=4.788266954784756,
  pause_on_action=False
)

The touchscreen is wired up hdmi0 on the pi. usb and has its own 5v power connected (did this later and didn't make a difference).

There are two solutions I am thinking on

  1. add code to my application to just "reset the usb connection"
  2. debug even more and figure out why this is precisely happening.

Any help is greatly appreciated as I am lost on this issue.


Solution

  • In the end the solution was to update the .kivy/config.ini file

    [input]
    mouse = none
    touch = hidinput