LIRC and MPC toggle restarts track

Have recently setup Mopidy on a Raspberry Pi and now using LIRC remote control for Spotify playlists.

When using ‘config = mpc toggle’ to play (after pausing) I get a brief (1/2 second) of current track followed by a quiet second then track goes back to beginning.
I have used the same setup on PiMusicbox and it stops and starts track in same place.

Using mpc toggle in Putty works as it should, pauses and plays at same point.

I’ve changed the config file to ‘config = mpc pause’ followed by ‘config = mpc play’ which works, but just wondered what might be causing the problem.

Also I would like to get ‘sudo -u root irexec -d’ to launch on boot, I used to put it in ‘/opt/musicbox/’ but can’t figure out where it would go in Mopidy.


Regarding toggle,can’t help you. If it works in the terminal then I don’t see why it wouldn’t work exactly the same when called by LIRC.

Regarding starting, it doesn’t go anywhere “in” Mopidy. One simple way to start something at boot is to stick it in /etc/rc.local (which is actually where /opt/musicbox/ is called from on PiMusicbox v0.6).

Thanks for the help, I had tried it in /etc/rc.local but it didn’t work and I thought I had the wrong location, I’ve now used ‘sleep 60 sudo -u root irexec -d’ in the same place which works ok, so I’m guessing it was going to early in the boot process.
I don’t reboot very often but it was frustrating having to SSH in to start it each time.

Not sure about the toggle thing - not really a problem now, just a bit frustrating.

Thanks again.