Python plugin: Sonos [old version]
Moderator: leecollings
- waaren
- Posts: 6028
- Joined: Tuesday 03 January 2017 14:18
- Target OS: Linux
- Domoticz version: Beta
- Location: Netherlands
- Contact:
Re: Python plugin: Sonos
[quote="hpnisse"]Hey!
I have a Synology DS1515+ NAS with DSM version 6.1-15047.
And I have installed Domoticz Beta v3.7320 by jumbotroll, that should support Python Plugin Beta.
The problem is that when I add plugins, Sonos, the Domoticz installation can't find it.
...
I have installed this plugin on my Synology 916+ in
/usr/local/domoticz/var/plugins/domoticz-sonos
and it's working
I have a Synology DS1515+ NAS with DSM version 6.1-15047.
And I have installed Domoticz Beta v3.7320 by jumbotroll, that should support Python Plugin Beta.
The problem is that when I add plugins, Sonos, the Domoticz installation can't find it.
...
I have installed this plugin on my Synology 916+ in
/usr/local/domoticz/var/plugins/domoticz-sonos
and it's working
Debian buster, bullseye on RPI-4, Intel NUC.
dz Beta, Z-Wave, RFLink, RFXtrx433e, P1, Youless, Hue, Yeelight, Xiaomi, MQTT
==>> dzVents wiki
dz Beta, Z-Wave, RFLink, RFXtrx433e, P1, Youless, Hue, Yeelight, Xiaomi, MQTT
==>> dzVents wiki
-
- Posts: 2
- Joined: Monday 17 April 2017 13:51
- Target OS: NAS (Synology & others)
- Domoticz version:
- Contact:
Re: Python plugin: Sonos
waaren wrote: I have installed this plugin on my Synology 916+ in
/usr/local/domoticz/var/plugins/domoticz-sonos
and it's working
Thanks to you both!!!GuyTreepbush wrote:Your file permissions are wrong. Set permissions for plug-in.py file to 0777
Changed the rights and owner of the files/folders, and moved everything to "domoticz/var/plugins/Sonos".
The volume and some on/off button appeared in devices.
Now I just have to figure it out how to use it like I want... is there any page that list all "commands" I can do?
Can I change input and groups by lua events?
Thanks again!!
-
- Posts: 443
- Joined: Thursday 12 November 2015 10:55
- Target OS: Raspberry Pi / ODroid
- Domoticz version: Beta
- Location: The Netherlands
- Contact:
Re: Python plugin: Sonos
No you can't. Currently you can only play/pause them, change the volume, and see what's playing.hpnisse wrote:waaren wrote: I have installed this plugin on my Synology 916+ in
/usr/local/domoticz/var/plugins/domoticz-sonos
and it's workingThanks to you both!!!GuyTreepbush wrote:Your file permissions are wrong. Set permissions for plug-in.py file to 0777
Changed the rights and owner of the files/folders, and moved everything to "domoticz/var/plugins/Sonos".
The volume and some on/off button appeared in devices.
Now I just have to figure it out how to use it like I want... is there any page that list all "commands" I can do?
Can I change input and groups by lua events?
Thanks again!!
Raspberry Pi 4 - RFXtrx433 - CC2531 Zigbee - Opentherm Gateway - P1 smart meter - Netatmo - Philips Hue - ELV Max! - ESP8266 DIY water meter - 6 x Sonos - 4 x IP cameras - Wall mounted tablet + Dashticz - Google Home integration - MANY switches/sensors
-
- Posts: 5
- Joined: Thursday 11 June 2015 20:37
- Target OS: Raspberry Pi / ODroid
- Domoticz version: 2020.2
- Contact:
Re: Python plugin: Sonos
Hello tester22.
Great pluginn if it should be working. I've copied the files to /domoticz/plugins/Sonos/...files...
Rebooted several times my r-pi, and checked by hardware and virtual switch but i cann't find the option to add a Sonos switch?
Do i miss something what isn't mensient on the internet?
Some screanshots of prints would be nice to see what i can get..
Keep up the good work, hopefull there will be an office plugin soon like Heos by Denon.
Update: There wasn't any version of Python installed, after that en rebooting again it does work. Very Cool.
Great pluginn if it should be working. I've copied the files to /domoticz/plugins/Sonos/...files...
Rebooted several times my r-pi, and checked by hardware and virtual switch but i cann't find the option to add a Sonos switch?
Do i miss something what isn't mensient on the internet?
Some screanshots of prints would be nice to see what i can get..
Keep up the good work, hopefull there will be an office plugin soon like Heos by Denon.
Update: There wasn't any version of Python installed, after that en rebooting again it does work. Very Cool.
Regards, Johan.
Synology NAS DS 713+ (Docker running Domoticz & MQTT), R-Pi2 with P1 Interface. 4xKUKA devices. 3 x Camera's.
Xiaomi MiHome Gateway. Sonoff Basic MQTT (Tasmota). AirconWithMe Wifi Airco module.
Synology NAS DS 713+ (Docker running Domoticz & MQTT), R-Pi2 with P1 Interface. 4xKUKA devices. 3 x Camera's.
Xiaomi MiHome Gateway. Sonoff Basic MQTT (Tasmota). AirconWithMe Wifi Airco module.
- leecollings
- Posts: 167
- Joined: Tuesday 30 June 2015 18:09
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Location: United Kingdom
- Contact:
Re: Python plugin: Sonos
Can someone please help me? I'm not getting much help from the plugin author, and despite trying everything that's been listed, I am not seeing 'Sonos' appear in my Hardware devices list.
Just to go through the basics...
I'm running Beta 3.7450
I have uploaded the plugin.py file in /plugins/sonos/
I have installed python3 and restarted the Pi
Still nothing shows up in the Hardware dropdown list.
Is there anything else I need to do?
UPDATE:
Even after running `sudo apt-get install python3-dev`, I'm still seeing the error in the log after restarting DM:
`PluginSystem: Failed dynamic library load, install the latest libpython3.x library that is available for your platform.`
How can I fix this? Is this what's stopping Sonos from appearing in the Hardware list?
Just to go through the basics...
I'm running Beta 3.7450
I have uploaded the plugin.py file in /plugins/sonos/
I have installed python3 and restarted the Pi
Still nothing shows up in the Hardware dropdown list.
Is there anything else I need to do?
UPDATE:
Even after running `sudo apt-get install python3-dev`, I'm still seeing the error in the log after restarting DM:
`PluginSystem: Failed dynamic library load, install the latest libpython3.x library that is available for your platform.`
How can I fix this? Is this what's stopping Sonos from appearing in the Hardware list?
Last edited by leecollings on Tuesday 16 May 2017 12:29, edited 1 time in total.
-
- Posts: 49
- Joined: Tuesday 20 December 2016 17:43
- Target OS: Raspberry Pi / ODroid
- Domoticz version: beta
- Location: Sweden
- Contact:
Re: Python plugin: Sonos
Do you have any entry in your log displaying that the plugin system is loaded or that the plugin itself is loaded?leecollings wrote:Can someone please help me? I'm not getting much help from the plugin author, and despite trying everything that's been listed, I am not seeing 'Sonos' appear in my Hardware devices list.
Just to go through the basics...
I'm running Beta 3.7450
I have uploaded the plugin.py file in /plugins/sonos/
I have installed python3 and restarted the Pi
Still nothing shows up in the Hardware dropdown list.
Is there anything else I need to do?
Does any other plugins work? What browser are you using?
- leecollings
- Posts: 167
- Joined: Tuesday 30 June 2015 18:09
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Location: United Kingdom
- Contact:
Re: Python plugin: Sonos
Even after running `sudo apt-get install python3-dev`, I'm still seeing the error in the log after restarting DM:
`PluginSystem: Failed dynamic library load, install the latest libpython3.x library that is available for your platform.`
How can I fix this? Is this what's stopping Sonos from appearing in the Hardware list?
`PluginSystem: Failed dynamic library load, install the latest libpython3.x library that is available for your platform.`
How can I fix this? Is this what's stopping Sonos from appearing in the Hardware list?
-
- Posts: 49
- Joined: Tuesday 20 December 2016 17:43
- Target OS: Raspberry Pi / ODroid
- Domoticz version: beta
- Location: Sweden
- Contact:
Re: Python plugin: Sonos
Since libpython isn't working that is what you need to fix.leecollings wrote:Even after running `sudo apt-get install python3-dev`, I'm still seeing the error in the log after restarting DM:
`PluginSystem: Failed dynamic library load, install the latest libpython3.x library that is available for your platform.`
How can I fix this? Is this what's stopping Sonos from appearing in the Hardware list?
Have you looked here: https://www.domoticz.com/wiki/Using_Python_plugins
You need both python3 and python3-dev.
- leecollings
- Posts: 167
- Joined: Tuesday 30 June 2015 18:09
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Location: United Kingdom
- Contact:
Re: Python plugin: Sonos
Something strange going on.
So I already have python3, and this is the latest version. (But I previously ran apt-get install python3-dev, and that installed).
So I seem to have both a production and dev version of python3 installed, but yet Domoticz still displays the message
2017-05-16 11:23:20.424 PluginSystem: Failed dynamic library load, install the latest libpython3.x library that is available for your platform.
So I already have python3, and this is the latest version. (But I previously ran apt-get install python3-dev, and that installed).
So I seem to have both a production and dev version of python3 installed, but yet Domoticz still displays the message
2017-05-16 11:23:20.424 PluginSystem: Failed dynamic library load, install the latest libpython3.x library that is available for your platform.
- leecollings
- Posts: 167
- Joined: Tuesday 30 June 2015 18:09
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Location: United Kingdom
- Contact:
Re: Python plugin: Sonos
Installed them both, and restarted. Still seeing the error notice in the log.
No idea what's going on.
No idea what's going on.
- leecollings
- Posts: 167
- Joined: Tuesday 30 June 2015 18:09
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Location: United Kingdom
- Contact:
Re: Python plugin: Sonos
Now after reading article1, I tried to install sudo apt-get install libpython3.4
But this then said Unable to locate. Unable to find by regex...
I find it hard to believe that some users have had this working fine without any issues... There's clearly an issue probably within Domoticz if it's reporting that I don't have python3, which I clearly do.
But this then said Unable to locate. Unable to find by regex...
I find it hard to believe that some users have had this working fine without any issues... There's clearly an issue probably within Domoticz if it's reporting that I don't have python3, which I clearly do.
- leecollings
- Posts: 167
- Joined: Tuesday 30 June 2015 18:09
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Location: United Kingdom
- Contact:
Re: Python plugin: Sonos
Can anyone help me please? There must be something I'm missing out here.
Is there any way to force to re-install whatever required version of python is needed? I've been trying apt-get install python3.6.1 and libpython3.6.1 but it can't find those either.
This is really annoying!!
Is there any way to force to re-install whatever required version of python is needed? I've been trying apt-get install python3.6.1 and libpython3.6.1 but it can't find those either.
This is really annoying!!
- leecollings
- Posts: 167
- Joined: Tuesday 30 June 2015 18:09
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Location: United Kingdom
- Contact:
Re: Python plugin: Sonos
Okay, so I managed to install Python 3.6.1 and that loads fine.
I can now see Sonos Players in the Hardware List, but when I click 'Add', literally nothing happens. Nothing in the log, Domoticz doesn't crash. It just does nothing.
Any where I can go from here?
I can now see Sonos Players in the Hardware List, but when I click 'Add', literally nothing happens. Nothing in the log, Domoticz doesn't crash. It just does nothing.
Any where I can go from here?
-
- Posts: 49
- Joined: Tuesday 20 December 2016 17:43
- Target OS: Raspberry Pi / ODroid
- Domoticz version: beta
- Location: Sweden
- Contact:
Re: Python plugin: Sonos
What browser are you using. If you are using Chrome you should make an force reload. Due to cached JavaScript.leecollings wrote:Okay, so I managed to install Python 3.6.1 and that loads fine.
I can now see Sonos Players in the Hardware List, but when I click 'Add', literally nothing happens. Nothing in the log, Domoticz doesn't crash. It just does nothing.
Any where I can go from here?
- leecollings
- Posts: 167
- Joined: Tuesday 30 June 2015 18:09
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Location: United Kingdom
- Contact:
Re: Python plugin: Sonos
Hmm I'll try a cache clear and maybe an entire rPi restart.
I'm running Safari on Mac OS X by the way
I'm running Safari on Mac OS X by the way
- leecollings
- Posts: 167
- Joined: Tuesday 30 June 2015 18:09
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Location: United Kingdom
- Contact:
Re: Python plugin: Sonos
Got them added now, and seems to be successfully pausing the speakers when turning the switches On and Off.
My ultimate goal is to have an Event where it will collect the state of all players, pause them, play an MP3 file, and then return them to their original state.
I don't suppose this feature is actually built into the plugin in an easy way is it? I was looking at the Http Node Sonos API that does this via the clip all function, but there's such a delay between firing the event and actually hearing any sound.
What would be the best way to get the speakers to play a locally hosted (on the Pi) MP3 file?
My ultimate goal is to have an Event where it will collect the state of all players, pause them, play an MP3 file, and then return them to their original state.
I don't suppose this feature is actually built into the plugin in an easy way is it? I was looking at the Http Node Sonos API that does this via the clip all function, but there's such a delay between firing the event and actually hearing any sound.
What would be the best way to get the speakers to play a locally hosted (on the Pi) MP3 file?
-
- Posts: 49
- Joined: Tuesday 20 December 2016 17:43
- Target OS: Raspberry Pi / ODroid
- Domoticz version: beta
- Location: Sweden
- Contact:
Re: Python plugin: Sonos
Right now it is only possible to control playback and volume on the players.leecollings wrote:Got them added now, and seems to be successfully pausing the speakers when turning the switches On and Off.
My ultimate goal is to have an Event where it will collect the state of all players, pause them, play an MP3 file, and then return them to their original state.
I don't suppose this feature is actually built into the plugin in an easy way is it? I was looking at the Http Node Sonos API that does this via the clip all function, but there's such a delay between firing the event and actually hearing any sound.
What would be the best way to get the speakers to play a locally hosted (on the Pi) MP3 file?
To be able to use tts or an local MP3 file Domoticz need to expose an http endpoint that the Sonos players can load data from, it is not possible with the current version of the python framework.
Also there is no clean way in Domoticz to send an event to an device in Domoticz other than on/off/dim.
Hopefully this will be possible in the future.
- leecollings
- Posts: 167
- Joined: Tuesday 30 June 2015 18:09
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Location: United Kingdom
- Contact:
Re: Python plugin: Sonos
Ah, sorry I didn't see the post earlier about what you can and can't do.
Thanks for the heads up, this may not cut the mustard for what I'm after. But nonetheless, it's fantastic to see a nice native Domoticz plugin to use.
I'll head back to the other API and see if I can improve the delay on firing the events of that.
I would love to hear about any updates to this plugin though, if these features are planned to be added at some point?
Thanks for the heads up, this may not cut the mustard for what I'm after. But nonetheless, it's fantastic to see a nice native Domoticz plugin to use.
I'll head back to the other API and see if I can improve the delay on firing the events of that.
I would love to hear about any updates to this plugin though, if these features are planned to be added at some point?
-
- Posts: 142
- Joined: Friday 21 October 2016 9:25
- Target OS: NAS (Synology & others)
- Domoticz version:
- Location: Netherlands
- Contact:
Re: Python plugin: Sonos
All working well on my side, but curious about the custom icons. They don't seem to be used at all, or is there something else I need to do to make use of them?tester22 wrote:Try this version: https://github.com/tester22/Domoticz-So ... /plugin.pybdormael wrote:Yes, the zip file is there as well, unfortunatly since domoticz does not start, I don't have any logging available either.tester22 wrote:
Strange, did you copy all the files including the zip files to the plugin folder?
Is there any way I can add extra logging ?
I introduced custom icons about an week ago and maybe thats what causing it.
- leecollings
- Posts: 167
- Joined: Tuesday 30 June 2015 18:09
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Location: United Kingdom
- Contact:
Re: Python plugin: Sonos
After the past hour of removing and re-uploading the plugin files, clearing cache, restarting the Pi, and Allowing new sensors for 5 minutes, I still haven't been able to see 'Sonos Players' in the Hardware list.G3rard wrote: Just place the code in a file called plugin.py and place it in the folder domoticz/plugin/sonos.
After a restart of Domoticz you can add your Sonos via the Hardware settings under Sonos Players.
There must be something more to adding this, as htese instructions don't seem to be working at all.
Can you give some advice or assistance please? Running v3.7613 Beta
Who is online
Users browsing this forum: Google [Bot] and 1 guest