Installing Sonos Plugin 2.0 (development/pre-release) for Azure TTS access

Hi!
I have 3 Sonos. Each and every one shows: “Offline; waiting for proxy…” and “Can’t Detect Device”
since I updated to the latest version. The previous version worked ok. Any thoughts why?

Thank you @rigpapa! Your dedication and support is much appreciated for this and all other plugins!

2 Likes

@Fanan, if the message does not go away after about a minute, please go the master device and turn on “plugin” debug (only), then reload Luup, wait 60 seconds, and then run this in the “Test Luup Code” tool (copy-paste):

for v=1,16 do luup.log(string.rep("X",128),50) end
os.execute( "gzip -c /var/log/cmh/LuaUPnP.log >/tmp/log.gz" )
os.execute( "ln -sf /tmp/log.gz /www/" )

Then download the log file by requesting in a browser: http://your-vera-ip/log.gz

This should download a large-ish binary (compressed) file. PM me here and drag that file into the message.

**It appears some of us (in the US?) are having problems reading and posting to the forums. I’m seeing an expired certificate message, and posting is hit-ot-miss for me.

1 Like

Forum is very slow for me too, I’m in Canada

Also very slow here in Holland

Back on line this morning. A couple of people I chat with off-line had similar issues. We were seeing an old expired certificate for the site. In one case, there was a 3/17/2020 expiration, and another had a 12/18/2019 expiration! Today the cert is showing 3/6/2022 expiration and all is working well. Back to business!

1 Like

Yup, seems to to back, but I still see the December 18, 2019 certificate expiration.

Hi Patrick,
Run into a snag installing the plugin. My blue status bar shows “Sonos: Duplicate master device”.
Version is
2.0develop-20077.1800.
What other info do you need?

Thanks,
Roger

I think the message is pretty clear, so the resolution should be no surprise as well. Somehow you created two master devices. If you are upgrading from a previous 2.x release, you may have done steps 11-13; after the initial installation of 2.x, any upgrades to newer spins are only steps 4-10 (and 14).

Find the two master devices and go into their Advanced > Params and not their device numbers. Delete the one with the higher device number, and reload Luup.

Sorry for the stupid question. I didn’t see the engine that was created in the “No Room” and was headed out the door so didn’t have much time to investigate.

Just a note for future if it helps;

I just noticed 2 streams playing with Alexa on Sonos at the same time. I verbally initiated a song. It started playing immediately but with low volume. A second later Alexa confirmed the song with title and artist in loud volume while music continued in background. When she finished her prompt, the volume rose to the initiated level.

With Alexa integrated into Sonos, I’m sure it can do some awesome tricks.

The current version of Sonos 2.0 is now 20081.1005

  • Tested and working on openLuup. TTS requires special configuration, so please see the README file for instructions.
  • Vera3/Lite are not currently supported for Azure TTS due to limitations in Vera’s LuaSec libraries (not an uncommon problem these days). I am investigating workarounds but if it doesn’t jump to life, I’m not going to spend any more time on it, as these platforms are off support with Vera anyway.
  • The Say and Alert actions now accept parameter UnMute (boolean 0 or 1, default 1) to unmute target zones before playing the speech/alert.
  • The TTS cache now prunes itself. By default, it prunes speech files older than 90 days since last use (so if you use them, they resist pruning). You can change the age-out by setting TTSCacheMaxAge to the desired number of days. Setting it to 0 disables cache pruning, but you will then need to manage disk usage yourself.

My expectation now is that this is the last development release/alpha before beta. I am shooting for release to the App Marketplace around 4/12.

1 Like

Ive noticed the volume on my sonos’s blast when I start music. I’m not sure if its related to TTS or not.

What is the correct setting to have the music play volume and Alexa volume return to their previous levels after TTS has spoken?

There is only one volume setting that I am aware of, and it is restored when TTS completes.

FWIW, bear in mind that Alexa likes to be told “Volume N” (where N=1-10), whereas Sonos – and by extension, any Sonos plug-in – expects values N=0-100. So make sure your Alexa-enabled Sonos device isn’t getting the wrong message somewhere along the line.

I use Reactor to reset my Sonos volume daily, and Alexa routines to do the same with my Alexa devices nightly. Because I hate loud things!

To be clear, I view anything the built-in Alexa integration for Sonos does to be as relevant to Sonos as an Echo Dot sitting across the room from the Sonos. Unless the Sonos itself notifies the plugin of changes the Alexa might be making, there is no way for it to know what Alexa is doing to the Sonos, or be able to undo it. The fact that built-in Alexa can reduce the volume of Sonos’ playback so Alexa can play its audio over that, for example, tells me only that Alexa has an input to the Sonos’ audio mixer hardware (as expected–shared speakers), and it’s quite possible (likely, based on what we’re seeing, in fact) that the volume reduction is done in the electronics without any changes in Sonos parameters or even the awareness of the Sonos CPU at all.

Regardless, I don’t own any Alexa-integrated Sonos devices, and I won’t be buying any in the foreseeable future. So far, the community has not demonstrated that there is adequate interest in this plugin to support any additional investment.

1 Like

Concur wholeheartedly! I just wanted to make sure @w1se did not have competing workflows “out there somewhere” which might impact his setup. You are correct that Alexa’s interruptions of streaming music, during voice prompts, is done 100% on the fly and doesn’t alter Sonos’ internal settings.

Fun fact: I arrived so late in the Sonos game that it actually took me a day or two to realize that I’d been trying to set the Sonos plug-in’s volume at “4” (my normal Alexa voice volume) and wondering why I couldn’t hear anything, lol. :slight_smile:

1 Like

Hi!
My Sonos speakers don’t talk to me anymore. Have I understood it correctly; Azure is not a free service for more than a 30 days evaluation period? If so, is there any other TTS-services that´s free for us, rarely users, to use? (Another option is to create mp3 files for each scenario. The possibilty to make dynamic TTS messages goes out the window - but it´s not something I use anyway, because the lack of knowledge…)

When we started this, my Azure account was older and I had to re-enable it. It was still free. Maybe yours just needs renewal?