remote control mocp?

Does mocp (2.3.2) have any facilities for remote control?

I took an old p2-400 256mb laptop w/wireless card, put a basic (no X) Fedora Core 4 on it, then added SlimServer ( and MOC (rolled my own RPM) and jacked an audio cable from the laptop to the stereo. It works fantastically, I have the laptop shoved under the stereo system and play all my MP3 streams right there controlled via webbrowser. Adding an external USB drive today to store local music, add Samba/NFS for management and I'm done. Project time: 1 day. :)

So, I have MOC running in a shell listening to http://localhost:9000/stream.mp3, detached into the background. I really don't have to touch mocp except to adjust the volume every now and then when a random station jacks up their volume or something. What I'd like to do is build some sort of web-able control (SlimServer plugin maybe?) that could interface with MOC on the localhost, maybe sending it commands for this and that (basic stuff, nothing fancy - adjust volume, stop/play).

Hence the question -- is there anything in the code floating around that I could utilize? I haven't started digging into it, thought I'd float the question first here.


Wouldn't be enough to run commands like mocp --next, --mocp --pause etc. from a CGI or PHP script? If the user running MOC and the user running CGI or PHP scripts are not the same, take a look at -M option.

For volume control you can use any other command line tool, like amixer, MOC can't change the volume with command line.
Damian Pietras - MOC developer