Tested on:RPi3; Raspbian Jessie; Kivy v1.9.1
Prerequisites:Raspberry Pi with Raspbian Jessie and internet connection (see steps 1-7 in the Introduction)
Kivy on a Raspberry Pi: Control light color with a touch interface

Kivy on the Raspberry Pi Bugfix: prevent KeyError: ‘y’ crash

Kivy is an amazing Python framework for building touch applications and works well with the Raspberry Pi.
However, it sometimes crashes while outputting KeyError: 'y'. I guess the issue will be fixed in the next version, but for now, you can use the following workaround.

Full error message

Fix the Keyerror
Open the file mtdev.py with


and replace it with

That’s it!

Tutorial Kivy for Touchscreen Applications: http://www.knight-of-pi.org/kivy-on-a-raspberry-pi-control-light-color-with-a-touch-interface/

Knight of Pi

Johannes Bergs aka Knight of Pi. Diploma in Bioinformatics, some Webdesign and Python coding then. Living in the beautiful city of Vienna.


Time limit is exhausted. Please reload CAPTCHA.