I created a script that basically plays whatever song is currently playing in MM on a Squeezbox OR SoftSqeeze running on a PC(which I am using). It does this via the Slimserver CLI (telnet command line) with a scriptable free telnet .dll you have to install called w3Sockets.
I just created it tonight, let me know if it works for anyone else.
telnet dll (w3sockets):
http://www.dimac.net/default3.asp?M=Fre ... sstart.asp
slimserver:
http://www.slimdevices.com/su_downloads.html
softsqeeze:
http://softsqueeze.sourceforge.net/
Code: Select all
' MediaMonkey Script
' NAME: SqueezeBox Controller
' Author: Todd Nemeth /revel
' Date first started: 09/26/2007
' INSTALL: Copy to Scripts\Auto\
' REQUIREMENTS:
'- You need w3Sockets installed and registered from here:
'http://www.dimac.net/default3.asp?M=FreeDownloads/'Menu.asp&P=FreeDownloads/FreeDownloadsstart.asp
'-You will also need SlimServer installed and running.
Sub OnStartup
Call Script.RegisterEvent(SDB,"OnPlay","Event_OnPlay")
Call Script.RegisterEvent(SDB,"OnPause","Event_OnPause")
Call Script.RegisterEvent(SDB,"OnStop","Event_OnStop")
Call Script.RegisterEvent(SDB,"OnShutdown","Event_OnShutdown")
End Sub
Sub Event_OnPlay
Set objCurSong = SDB.Player.CurrentSong
strPath = objCurSong.Path
'MsgBox strPath
strPlayerCmd = "playlist play " & strPath
'MsgBox strPlayerCmd
Dim oSocket
Set oSocket = CreateObject("Socket.TCP")
oSocket.DoTelnetEmulation = True
oSocket.TelnetEmulation = "TTY"
oSocket.Host = "localhost:9090"
oSocket.Open
oSocket.SendLine strPlayerCmd
oSocket.Close
End Sub
Sub Event_OnStop
strPlayerCmd = "stop"
Dim oSocket
Set oSocket = CreateObject("Socket.TCP")
oSocket.DoTelnetEmulation = True
oSocket.TelnetEmulation = "TTY"
oSocket.Host = "localhost:9090"
oSocket.Open
oSocket.SendLine strPlayerCmd
oSocket.Close
End Sub
Sub Event_OnShutdown
strPlayerCmd = "stop"
Dim oSocket
Set oSocket = CreateObject("Socket.TCP")
oSocket.DoTelnetEmulation = True
oSocket.TelnetEmulation = "TTY"
oSocket.Host = "localhost:9090"
oSocket.Open
oSocket.SendLine strPlayerCmd
oSocket.Close
End Sub
Sub Event_OnPause
strPlayerCmd = "pause"
Dim oSocket
Set oSocket = CreateObject("Socket.TCP")
oSocket.DoTelnetEmulation = True
oSocket.TelnetEmulation = "TTY"
oSocket.Host = "localhost:9090"
oSocket.Open
oSocket.SendLine strPlayerCmd
oSocket.Close
End Sub