Kodi Community Forum

Full Version: GPIO High/Low while playing on RPi
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hello Community,

is there a feature within Kodi to allow setting the GPIO pins on a Raspberry Pi to high while Kodi is Playing a song/music? That GPIO pin shall be set to low after the music has stopped.
I found a little Python script which is exactly doing this with a work-around, but I find that quite useful to have that setup out of Kodi directly.

Marc
As Kodi is multiplatform there is no feature that works on a RPi only. But this is easy to solve if you know how to use python.

Write a simple Kodi service to monitor the events in Kodi. You find some examples in the add-ons. If the play event is triggered execute the GPIO settings.