I’m using the following code as an example of an announcement that Vera makes through my Sonos devices:
luup.call_action("urn:micasaverde-com:serviceId:Sonos1", "Say",
{Text="The Front Door has been left unlocked.",Language="en-CA",Duration=3,GroupZones="ALL",Volume=50},234)
My impression of the “Duration=3” parameter is that, if music is playing, the music will resume after the announcement is made. Well… it does, but it’s not actually the same song. It’s as if Sonos stops for the announcement, then makes the announcement, and then Sonos just restarts whatever channel was playing before the announcement. It’s always a new song.
Is this how it’s supposed to work?
Please look at the wiki, the duration is not a parameter for the Say action.
The previous playback context is restored after TTS. Depending on this context (the music service you are listening), it will continue the previous song or switch to a new one. For example, with Deezer flow, a new song is played but with a particular song from your local music library or even Deezer, the song is restarted at its previous position. If the song is put in the queue, it is working.
Ah hah, thanks. I used the “duration” parameter when calling up an MP3, and so I assumed it would work for the “Say” command as well. So whether the interrupted music will continue or restart is entirely dependent on the context… got it.