diff --git a/DEV_NOTES.md b/DEV_NOTES.md index 8ba36ff..dfe12ee 100644 --- a/DEV_NOTES.md +++ b/DEV_NOTES.md @@ -1,5 +1,39 @@ # Notes while working on Kivy +## Setup of Kivy +- Went with pip install setup on Ubuntu 15.10 x86-64: + 1. Fork and clone the Kivy repo: + 1. Create a virtualenv + 1. Installed the following dependencies: + ```sudo apt-get install libjpeg-dev libgl1-mesa-dev libgles2-mesa-dev libsdl2-dev libsdl2-image-dev \ + libsdl2-mixer-dev libsdl2-ttf-dev zlib1g-dev``` + 1. `pip install -e .` + 1. `make test` to verify working setup. + + +## Linux Device Issues: +- Running into device permission errors, mostly like caused by the touchscreen or touchpad: + +``` + [INFO ] [GL ] NPOT texture support is available + Exception in thread Thread-1: + 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 "/home/dorian.pula/pycon_sprints/kivy/kivy/input/providers/mtdev.py", line 219, in _thread_run + _device = Device(_fn) + File "/home/dorian.pula/pycon_sprints/kivy/kivy/lib/mtdev.py", line 143, in __init__ + self._fd = os.open(filename, os.O_NONBLOCK | os.O_RDONLY) + OSError: [Errno 13] Permission denied: '/dev/input/event7' + + [INFO ] [Base ] Leaving application in progress... +``` + +- Adding user to `input` device did not work. +- This *may* work: https://puredata.info/docs/faq/how-can-i-set-permissions-so-hid-can-read-devices-in-gnu-linux + ## Tutorial Improvements: - [Adding Ball Animation](https://kivy.org/docs/tutorials/pong.html#adding-ball-animation) - Add in placeholder variable to describe the random direction of the ball. @@ -11,4 +45,5 @@ ## Kivy language - [Documentation for Kv language](https://kivy.org/docs/guide/lang.html) - Documentation on language does not have an explicit section on adding comments. -- Nice to have tips for syntax-highlighting inside Kv files for PyCharm. +- Nice to have tips for syntax-highlighting inside Kv files for PyCharm + - Thanks @kjell for pointing out [PyCharm settings](https://github.com/kivy/kivy/wiki/Setting-Up-Kivy-with-various-popular-IDE's#kv-lang-auto-completion-and-highlighting) diff --git a/README.md b/README.md new file mode 100644 index 0000000..b9a3d4f --- /dev/null +++ b/README.md @@ -0,0 +1,8 @@ +# Kivy Gamecamp - Pong Tutorial + +Work from the [Game Camp, run by the fine folks at Learn Leap Fly](https://github.com/learnleapfly/gamecamp) + +## Install Kivy + +https://kivy.org/docs/contribute.html#code-workflow +