I would rather something more similar to number 2 as in terms of two physical buttons and a small lcd.
Thanks for your help!
Looking forward to make my project a reality
Hey! I assembled my pi into an old radio and already connected the buttons to a piface. However, i didn’t have time to programm the stuff necessary for controlling mopidy (and I never coded python before)
Mopidy-Touchscreen
It can be used to control mopidy from a touchscreen. I am working to work also with GPIO buttons in case the TFT has no touch.
Mopidy-TTSGPIO
This one is to control with a keyboard or GPIO buttons. The idea is to use TTS to replace any kind of display. Something similar to 3rd generation Ipod shuffle control.
Maybe you can use one of this extensions or check the code on github to make your own extension.
@9and3r : thanks for creating these! I’m having a play with Mopidy-TTSGPIO, and I could use your help. I want to make a headless music server for my kids.
I’ve got pimusicbox running, installed your plugin, edited config, got modipy running as root, hooked up the buttons to the GPIO (e.g. 24 for ‘Next’) and… nothing.
Just wondering if you’re able to help with debugging in any way? I’ve no idea where to start.
Hi,
How can I run pi musicbox and mopidy-ttsgpio in simultaneous?
I just want 5 buttons on to play pre-memorize radio stations.
I have no programming experience.
Tanks in advance.
Then you must run mopidy as sudo. In musicbox edit file /etc/init.d/mopidy and change
DAEMON_USER = mopidy
to
DAEMON_USER = root
Currently mopidy-ttsgpio can be used to choose playlists. I am not sure if it is possible to make a playlist with radio stations (In general I use mopidy to play spotify songs).
I’m struggling to get the Mopidy-TTSGPIO working, am i right in thinking if I am playing a song, in Musicbox, hit my button wired up to pin 17 it should pause the track, as i cant seem to get it working?
The module seems to be loading as i can see it in Enabled extensions, and i’ve written a little test python script to make sure the button is working, but i cant see to get it to control the playback.
Am i likley to be missing any dependences, and is there any way to get some debug info out of the plugin?
Check if the message “TTSGPIO: Not enough permission to use GPIO. GPIO input will not work” is on the log. If it doesn’t appear the extension should be loading correctly.
If you have internet connection you should also hear the track name when it starts playing.
Remember that the connection must be PINX- Button- Ground (You don’t have to use 3.3v or 5v).
The only dependence that is needed is RPi.GPIO but it should be there by default.
Cant see that message in the log, I’ve kind of ended up writing my own prototype now anyway as I wanted to use a rotary controller on my project as well.
Hi Guys,
Sorry I kind of left this thread but I am interested again. I am new to GPIO on raspberry pi. If I was to install TTS-GPIO what gpio buttons do i use? can you point me to some? So do I just connect GND - Button then the pin specified for say Play/Pause. Thanks!
Turns out I had the settings in the wrong part of the config. (it was in the Audio Settings section) I moved it up, under the spotify/soundcloud/etc settings and it seems to be working.
That capacitive buttons seem to work in a different way. So in your case pin- button- ground is not valid.
I have almost 0 knowledge in hardware .
I have made a small python script to test how ttsgpio detects the buttons. (I could not test it on my raspberry pi. Hope it works)
To use it simply copy to raspberry pi and run sudo python gpio_input_tester.py
You should see “X button pressed” when pushing and “X button released: Long/press” when you release it.
My first idea is that maybe that the bouncetime is not adequate for that type of touchpad. So try changing the value of the bouncetime in the script.
The second thing could be that those pads does not need any pull up resistor, so you could also try without.
For example change GPIO.setup(pins['pin_button_previous'], GPIO.IN, pull_up_down=GPIO.PUD_UP)
to GPIO.setup(pins['pin_button_previous'], GPIO.IN)
Just let me know how it goes. If it is working I will update the extension to support them.