How to find out which Linux driver is hogging my GPIO

On the Boundary Devices kernel, and maybe others, you can use cat /sys/kernel/debug/gpio to get a list of the mapped gpios, their states, and name given when it was allocated. You can grep the kernel source for the name and find out what module grabbed it. root@nitrogen6x:/opt# cat /sys/kernel/debug/gpio GPIOs 0-31, platform/209c000.gpio, 209c000.gpio: gpio-2 (flexcan-trx-stby … Read more

Sphinx: how to exclude imports in automodule?

There is no way to tell Sphinx to exclude some imports. When using autodoc, all documented modules must be cleanly importable. You might be able to work around the problem by doing some mocking. Here is an article describing the solution to a problem that seems quite similar to yours: http://blog.rtwilson.com/how-to-make-your-sphinx-documentation-compile-with-readthedocs-when-youre-using-numpy-and-scipy/. Here is a small … Read more

Docker Access to Raspberry Pi GPIO Pins

On a Linux host, there are three possible ways to get access to the GPIO pins from within a Docker container. 1. Running Docker with the “–privileged” option Starting a container like this will give the container full access to the host’s devices, including GPIO: $ docker run –privileged -d whatever Check the Docker documentation … Read more

tech