Logitech Media Server

Topics (not sure which fora)
when not sure where to post, post here and mods will move it to right forum.

Moderators: leecollings, remb0

User avatar
cyberclwn
Posts: 103
Joined: Thursday 20 August 2015 22:53
Target OS: Raspberry Pi / ODroid
Domoticz version: beta
Location: The Netherlands
Contact:

Re: Logitech Media Server

Post by cyberclwn »

By the way:

I have also made custom logo's for the Squeezebox. Not sure if they are uploaded to the googledrive (from the wiki) yet.
If anyone is interested let me know, and i'll try to make them available in another way.

Also, not sure if it was clear/obvious, but in my scripts i assume that the virtual switch in Domoticz is named with "Sq" followed bij the device name in LMS.
So In Domoticz i have switch "SqWoonkamer" which controls the LMS player "Woonkamer". Mostly important for the cron-script that checks the powerstate.
3xPi 2B (Domoticz "live", Domoticz "sandbox", PhotoFrame)
RFXCom433(E), KaKu, Oregon Scientific, Keyes 2-relay, Logitech Media Server, MiLight, Smartwares heating controller(2x), IR Send/Receive, Keyes PIR, XH-M131 DuskSensor, DHT22/11
Eduard
Posts: 139
Joined: Monday 19 January 2015 9:14
Target OS: -
Domoticz version:

Re: Logitech Media Server

Post by Eduard »

Sneak Preview :lol:
SneakPreview.png
SneakPreview.png (68.46 KiB) Viewed 4047 times
pvm
Posts: 550
Joined: Tuesday 17 June 2014 22:14
Target OS: NAS (Synology & others)
Domoticz version: 4.10538
Location: NL
Contact:

Re: Logitech Media Server

Post by pvm »

Nice
Synology NAS, slave PI3, ZWave (Fibaro), Xiaomi zigbee devices, BTLE plant sensor, DzVents, Dashticz on tablet, Logitech Media Server
rron
Posts: 223
Joined: Sunday 30 March 2014 15:24
Target OS: Linux
Domoticz version: Beta
Location: Waterland
Contact:

Re: Logitech Media Server

Post by rron »

Very nice :D
Is it also possible to see the web page with all the information?
Rpi, RFXcom, klikaan klikuit switch,thermosmart, z-wave, espeasy, smartevse
Eduard
Posts: 139
Joined: Monday 19 January 2015 9:14
Target OS: -
Domoticz version:

Re: Logitech Media Server

Post by Eduard »

rron wrote:Very nice :D
Is it also possible to see the web page with all the information?
Which webpage do you mean?
rron
Posts: 223
Joined: Sunday 30 March 2014 15:24
Target OS: Linux
Domoticz version: Beta
Location: Waterland
Contact:

Re: Logitech Media Server

Post by rron »

Eduard wrote:
rron wrote:Very nice :D
Is it also possible to see the web page with all the information?
Which webpage do you mean?
I'm controlling my squeezbox classic with a web application on my ipad and this application is showing information about the music like albumcovers. Is that also possible?
Rpi, RFXcom, klikaan klikuit switch,thermosmart, z-wave, espeasy, smartevse
Eduard
Posts: 139
Joined: Monday 19 January 2015 9:14
Target OS: -
Domoticz version:

Re: Logitech Media Server

Post by Eduard »

rron wrote: I'm controlling my squeezbox classic with a web application on my ipad and this application is showing information about the music like albumcovers. Is that also possible?
No, not at the moment. Currently basic control off the SqueezeBoxes is possible: on/off & play-control (see screenshot remote)
I'm near future i want to add timers so you can schedule playlist on certain day/time etc.
Also want to implement notifications so you can see those on the SB's display...
pvm
Posts: 550
Joined: Tuesday 17 June 2014 22:14
Target OS: NAS (Synology & others)
Domoticz version: 4.10538
Location: NL
Contact:

Re: Logitech Media Server

Post by pvm »

It is possible to retrieve an image url (mind it is not identical for web radio stream and local file) from the Logitech server. I have an implementation in php and JavaScript. This might also be a future extension
Synology NAS, slave PI3, ZWave (Fibaro), Xiaomi zigbee devices, BTLE plant sensor, DzVents, Dashticz on tablet, Logitech Media Server
rron
Posts: 223
Joined: Sunday 30 March 2014 15:24
Target OS: Linux
Domoticz version: Beta
Location: Waterland
Contact:

Re: Logitech Media Server

Post by rron »

I'm looking forward to it and all those new functions.
Thx
Rpi, RFXcom, klikaan klikuit switch,thermosmart, z-wave, espeasy, smartevse
Eduard
Posts: 139
Joined: Monday 19 January 2015 9:14
Target OS: -
Domoticz version:

Re: Logitech Media Server

Post by Eduard »

pvm wrote:It is possible to retrieve an image url (mind it is not identical for web radio stream and local file) from the Logitech server. I have an implementation in php and JavaScript. This might also be a future extension
That's the fun of open source; you're free to alter and extend the features :P
User avatar
cyberclwn
Posts: 103
Joined: Thursday 20 August 2015 22:53
Target OS: Raspberry Pi / ODroid
Domoticz version: beta
Location: The Netherlands
Contact:

Re: Logitech Media Server

Post by cyberclwn »

Looks good, Eduard.

Keep up the good work :)
3xPi 2B (Domoticz "live", Domoticz "sandbox", PhotoFrame)
RFXCom433(E), KaKu, Oregon Scientific, Keyes 2-relay, Logitech Media Server, MiLight, Smartwares heating controller(2x), IR Send/Receive, Keyes PIR, XH-M131 DuskSensor, DHT22/11
Eduard
Posts: 139
Joined: Monday 19 January 2015 9:14
Target OS: -
Domoticz version:

Re: Logitech Media Server

Post by Eduard »

Testversion is available!!

Follow the wiki http://www.domoticz.com/wiki/Installing ... rom_Source to install Domoticz by compiling from source, but use

Code: Select all

git clone -b lms https://github.com/EddyK69/domoticz.git dev-domoticz
instead.

Have fun & please let me know any bugs ;) . I will create a new pull-request at the end of this week to add it to the latest beta.

PS.: Currently only models SqueezeBox3 supported; that's the one i have and i can test... Please provide the JSON result of a 'Serverstatus' request to have your player added...
User avatar
cyberclwn
Posts: 103
Joined: Thursday 20 August 2015 22:53
Target OS: Raspberry Pi / ODroid
Domoticz version: beta
Location: The Netherlands
Contact:

Re: Logitech Media Server

Post by cyberclwn »

Great !

I just got the test-version and have the "Logitech Media Server" in the Hardware list.
But, what port do i need to configure ? The port of the webinterface ? or the port for the CLI ?

And i can't find the layout of a "JSON Serverstatus" request anywhere.
The JSON-request for a switch is known to me, but can you specify what you mean by this ?

I guess the players should come up in the "Devices" list under the hardware/settings of the LMS.
They are not there, so i guess they aren't found (i tried both the port's i know of, in LMS).

So there must be something wrong somewhere :)

ps. I have some SqueezeBox Radio's and a Touch
3xPi 2B (Domoticz "live", Domoticz "sandbox", PhotoFrame)
RFXCom433(E), KaKu, Oregon Scientific, Keyes 2-relay, Logitech Media Server, MiLight, Smartwares heating controller(2x), IR Send/Receive, Keyes PIR, XH-M131 DuskSensor, DHT22/11
Eduard
Posts: 139
Joined: Monday 19 January 2015 9:14
Target OS: -
Domoticz version:

Re: Logitech Media Server

Post by Eduard »

cyberclwn wrote: But, what port do i need to configure ? The port of the webinterface ? or the port for the CLI ?
You have to use the IP from your LMS-server and the webserver-port (default 9000)
And i can't find the layout of a "JSON Serverstatus" request anywhere.
The JSON-request for a switch is known to me, but can you specify what you mean by this ?
Try

Code: Select all

curl 'http://<SERVER-IP>:9000/jsonrpc.js' --data-binary '{"id":1,"method":"slim.request","params":["",["serverstatus","0","999"]]}'
and you get all your player-info like model etc.
I guess the players should come up in the "Devices" list under the hardware/settings of the LMS.
Correct!
So there must be something wrong somewhere :)
ps. I have some SqueezeBox Radio's and a Touch
I think thats the problem for now; i don't have these so i only support Squeezebox3. If you can provide the JSON-result, i can enable your models too...

Thanx for testing ;)
Last edited by Eduard on Monday 21 September 2015 20:44, edited 1 time in total.
User avatar
cyberclwn
Posts: 103
Joined: Thursday 20 August 2015 22:53
Target OS: Raspberry Pi / ODroid
Domoticz version: beta
Location: The Netherlands
Contact:

Re: Logitech Media Server

Post by cyberclwn »

Hey again :)

The result of this command

Code: Select all

curl 'http://<ip>:9090/jsonrpc.js' --data-binary '{"id":1,"method":"slim.request","params":["",["serverstatus","0","999"]]}'
is

Code: Select all

POST %2Fjsonrpc.js HTTP%2F1.1
User-Agent%3A curl%2F7.26.0
Host%3A <ip>%3A9090
Accept%3A *%2F*
Content-Length%3A 73
Content-Type%3A application%2Fx-www-form-urlencoded
Port 9090 is my CLI port (LMS runs on a NAS)

But i don't think you can find any usefull information from that. And also the CLI won't support JSON, so let's try the web-port:

Code: Select all

curl 'http://<ip>:9001/jsonrpc.js' --data-binary '{"id":1,"method":"slim.request","params":["",["serverstatus","0","999"]]}'
and i get this:

Code: Select all

{"params":["",["serverstatus","0","999"]],"method":"slim.request","id":1,"result":{"other player count":0,"info total albums":1420,"player count":5,"version":"7.9.0","players_loop":[{"seq_no":"12","playerid":"00:04:20:2a:94:c9","displaytype":"none","connected":1,"ip":"<ip>:55660","model":"baby","name":"Badkamer","uuid":"<uuid>","isplayer":1,"canpoweroff":1,"power":0},{"seq_no":0,"playerid":"7c:dd:90:87:b2:d0","displaytype":"none","connected":1,"ip":"<ip>:50346","model":"squeezelite","name":"SqueezePi","uuid":null,"isplayer":1,"canpoweroff":1,"power":"1"},{"seq_no":"48","playerid":"00:04:20:22:99:ab","displaytype":"none","connected":1,"ip":"<ip>:45107","model":"fab4","name":"Woonkamer","uuid":"<uuid>","isplayer":1,"canpoweroff":1,"power":0},{"seq_no":"42","playerid":"00:04:20:28:7c:1d","displaytype":"none","connected":1,"ip":"<ip>:57268","model":"baby","name":"Slaapkamer","uuid":"<uuid>","isplayer":1,"canpoweroff":1,"power":0},{"seq_no":"13","playerid":"00:04:20:27:a0:c2","displaytype":"none","connected":1,"ip":"<ip>:34826","model":"baby","name":"Keuken","uuid":"<uuid>","isplayer":1,"canpoweroff":1,"power":0}],"uuid":"<uuid>","sn player count":0,"info total artists":4018,"info total songs":19374,"lastscan":"1442648245","info total genres":201}}
This looks like it can be usefull.
So i guess the Radio is called "baby", the touch is a "fab4" and the software-version is "squeezelite". Sweet :)
3xPi 2B (Domoticz "live", Domoticz "sandbox", PhotoFrame)
RFXCom433(E), KaKu, Oregon Scientific, Keyes 2-relay, Logitech Media Server, MiLight, Smartwares heating controller(2x), IR Send/Receive, Keyes PIR, XH-M131 DuskSensor, DHT22/11
User avatar
cyberclwn
Posts: 103
Joined: Thursday 20 August 2015 22:53
Target OS: Raspberry Pi / ODroid
Domoticz version: beta
Location: The Netherlands
Contact:

Re: Logitech Media Server

Post by cyberclwn »

Btw,

I found this on another website:

Code: Select all

my %models = (
	slimp3      => {		modelName => 'SliMP3',	},
	Squeezebox  => {		modelName => 'Squeezebox 1',	},
	squeezebox2 => {		modelName => 'Squeezebox 2',	},
	squeezebox3 => {		modelName => 'Squeezebox 3',	},
	transporter => {		modelName => 'Transporter',	},
	receiver    => {		modelName => 'Squeezebox Receiver',	},
	boom        => {		modelName => 'Squeezebox Boom',	},
	softsqueeze => {		modelName => 'Softsqueeze',	},
	controller  => {		modelName => 'Squeezebox Controller',	},
	squeezeplay => {		modelName => 'SqueezePlay',	},
	baby        => {		modelName => 'Squeezebox Radio',	},
	fab4        => {		modelName => 'Squeezebox Touch',	},
);
Maybe usefull in the future, or when someone has another device like mentioned above.


And on a different note, did the "Raspberry's GPIO port" go missing in the dev-build ?
It's not in the hardwarelist when i start the dev-one. When i start the "normal" beta, it's still there.
Last edited by cyberclwn on Monday 21 September 2015 20:53, edited 1 time in total.
3xPi 2B (Domoticz "live", Domoticz "sandbox", PhotoFrame)
RFXCom433(E), KaKu, Oregon Scientific, Keyes 2-relay, Logitech Media Server, MiLight, Smartwares heating controller(2x), IR Send/Receive, Keyes PIR, XH-M131 DuskSensor, DHT22/11
Eduard
Posts: 139
Joined: Monday 19 January 2015 9:14
Target OS: -
Domoticz version:

Re: Logitech Media Server

Post by Eduard »

cyberclwn wrote:And also the CLI won't support JSON, so let's try the web-port:

Code: Select all

curl 'http://<ip>:9001/jsonrpc.js' --data-binary '{"id":1,"method":"slim.request","params":["",["serverstatus","0","999"]]}'
and i get this:

Code: Select all

{"params":["",["serverstatus","0","999"]],"method":"slim.request","id":1,"result":{"other player count":0,"info total albums":1420,"player count":5,"version":"7.9.0","players_loop":[{"seq_no":"12","playerid":"00:04:20:2a:94:c9","displaytype":"none","connected":1,"ip":"<ip>:55660","model":"baby","name":"Badkamer","uuid":"<uuid>","isplayer":1,"canpoweroff":1,"power":0},{"seq_no":0,"playerid":"7c:dd:90:87:b2:d0","displaytype":"none","connected":1,"ip":"<ip>:50346","model":"squeezelite","name":"SqueezePi","uuid":null,"isplayer":1,"canpoweroff":1,"power":"1"},{"seq_no":"48","playerid":"00:04:20:22:99:ab","displaytype":"none","connected":1,"ip":"<ip>:45107","model":"fab4","name":"Woonkamer","uuid":"<uuid>","isplayer":1,"canpoweroff":1,"power":0},{"seq_no":"42","playerid":"00:04:20:28:7c:1d","displaytype":"none","connected":1,"ip":"<ip>:57268","model":"baby","name":"Slaapkamer","uuid":"<uuid>","isplayer":1,"canpoweroff":1,"power":0},{"seq_no":"13","playerid":"00:04:20:27:a0:c2","displaytype":"none","connected":1,"ip":"<ip>:34826","model":"baby","name":"Keuken","uuid":"<uuid>","isplayer":1,"canpoweroff":1,"power":0}],"uuid":"<uuid>","sn player count":0,"info total artists":4018,"info total songs":19374,"lastscan":"1442648245","info total genres":201}}
This looks like it can be usefull.
So i guess the Radio is called "baby", the touch is a "fab4" and the software-version is "squeezelite". Sweet :)
Sorry, i was wrong about the port :oops: is has to be the webserver-port indeed; i changed my previous post...

Can you change the code in LogitechMediaServer.cpp (line 352) and test it with your models (baby & fab4)?
Eduard
Posts: 139
Joined: Monday 19 January 2015 9:14
Target OS: -
Domoticz version:

Re: Logitech Media Server

Post by Eduard »

cyberclwn wrote:Btw,

I found this on another website:

Code: Select all

my %models = (
	slimp3      => {		modelName => 'SliMP3',	},
	Squeezebox  => {		modelName => 'Squeezebox 1',	},
	squeezebox2 => {		modelName => 'Squeezebox 2',	},
	squeezebox3 => {		modelName => 'Squeezebox 3',	},
	transporter => {		modelName => 'Transporter',	},
	receiver    => {		modelName => 'Squeezebox Receiver',	},
	boom        => {		modelName => 'Squeezebox Boom',	},
	softsqueeze => {		modelName => 'Softsqueeze',	},
	controller  => {		modelName => 'Squeezebox Controller',	},
	squeezeplay => {		modelName => 'SqueezePlay',	},
	baby        => {		modelName => 'Squeezebox Radio',	},
	fab4        => {		modelName => 'Squeezebox Touch',	},
);
Maybe usefull in the future, or when someone has another device like mentioned above.
Thanks!!
And on a different note, did the "Raspberry's GPIO port" go missing in the dev-build ?
It's not in the hardwarelist when i start the dev-one. When i start the "normal" beta, it's still there.
Strange, it is a complete fork of the domoticz/master branch. Will test this on my dev machine
User avatar
cyberclwn
Posts: 103
Joined: Thursday 20 August 2015 22:53
Target OS: Raspberry Pi / ODroid
Domoticz version: beta
Location: The Netherlands
Contact:

Re: Logitech Media Server

Post by cyberclwn »

Yay,

There they are.
Nice list of the players, greyed out if turned off, in color when turned on (altho the wrong icon, windows mediaplayer icon, not squeezebox, :lol: )
I can see what's playing, volume buttons/mute play/pause works too :)

I like it a lot, so far :)
3xPi 2B (Domoticz "live", Domoticz "sandbox", PhotoFrame)
RFXCom433(E), KaKu, Oregon Scientific, Keyes 2-relay, Logitech Media Server, MiLight, Smartwares heating controller(2x), IR Send/Receive, Keyes PIR, XH-M131 DuskSensor, DHT22/11
Eduard
Posts: 139
Joined: Monday 19 January 2015 9:14
Target OS: -
Domoticz version:

Re: Logitech Media Server

Post by Eduard »

cyberclwn wrote:Yay,

There they are.
Nice list of the players, greyed out if turned off, in color when turned on (altho the wrong icon, windows mediaplayer icon, not squeezebox, :lol: )
I can see what's playing, volume buttons/mute play/pause works too :)

I like it a lot, so far :)
Thanx! Was in doubt about the icon too; kodi also does not have an own icon. ;)

Working on notifications now :lol:
Post Reply

Who is online

Users browsing this forum: Google [Bot] and 1 guest