Mopidy extension for GPIO input on a Raspberry Pi
Install by running:
pip install Mopidy-Raspberry-GPIO
Or, if available, install the Debian/Ubuntu package from apt.mopidy.com.
Before starting Mopidy, you must add configuration for Mopidy-Raspberry-GPIO to your Mopidy configuration file:
[raspberry-gpio] enabled = true bcm5 = play_pause,active_low,150 bcm6 = volume_down,active_low,150 bcm16 = next,active_low,150 bcm20 = volume_up,active_low,150
Each bcmN entry corresponds to the BCM pin of that number.
You must assign an event, mode and bouncetime (ms) to your desired pins.
- active_low - configures the pin with a pull-up and triggers when it reads 0/low (RECOMMENDED)
- active_high - configures the pin as a pull-down and triggers when it reads 1/high