.
.
.
.
.
.
AS OF 18-May-2020 THESE INSTRUCTIONS DO NOT APPLY. DO NOT RUN THIS PROCEDURE.
IF YOU WANT TO INSTALL THE SONOS PLUGIN, PLEASE DO SO THROUGH THE VERA PLUGIN MARKETPLACE (OR ALTAPP STORE).
.
.
.
.
.
These instructions are for users who want access to the Azure TTS engine support in the upcoming Sonos plugin 2.0 release. Version 2.0 is currently a work in progress, so be aware that you are installing pre-release software that has been through considerable revision with minimal testing.
READ THESE INSTRUCTIONS THROUGH FIRST, THEN FOLLOW THEM TO THE LETTER. If you donât run this procedure correctly, you risk destroying your existing Sonos devices, and if that happens, they will be recreated, but with new device numbersâyour existing scenes, Lua, Reactor, PLEG, etc. will need to be updated. If you do this procedure correctly, it will preserve the existing devices and their numbering, no additional work required.
DO NOT INSTALL THIS VERSION FOR ANY REASON OTHER THAN ACCESS TO AZURE TTS AT THIS TIME
DO NOT INSTALL THIS VERSION IF YOU DO NOT WANT PRE-RELEASE LEVEL SOFTWARE ON YOUR VERA SYSTEM
- Run the following Lua in Apps > Develop apps > Test Luup code. This code will disconnect your existing Sonos devices from the installed plugin. The devices will not be deleted, and they will still operate normally. By decoupling them from the plugin here, when you later delete the plugin (step 2), the devices will not be automatically deleted with itâweâre preserving your existing devices (and thus preserving their device numbers).
for n,d in pairs( luup.devices ) do if d.device_type == "urn:schemas-micasaverde-com:device:Sonos:1" then luup.attr_set( "plugin", "", n ) end end luup.reload()
- When Luup finishes reloading, go to Apps > My apps and uninstall the existing Sonos plugin (if itâs not listed there, no problem, just move on).
- Reload luup. I usually just to go Apps > Develop apps > Test Luup code and run
luup.reload()
- Open the Github develop branch repository: GitHub - toggledbits/Sonos-Vera at develop
- Click the green âClone or downloadâ button and choose âDownload ZIPâ
- Save the ZIP file.
- Unzip the ZIP file
- In the Vera UI, go to Apps > Develop apps > Luup files
- Multi-select the files (not foldersâignore any folders) you unzipped and drag them as a group to the âUploadâ button. Also skip the
Sonos_chime.mp3
file. - When the upload completes, Luup will reload.
- If you are upgrading from a prior spin of 2.0, skip now to step 14. If and only if you are installing 2.0 for the first time, then when the reload completes, create the Sonos System master device:
a. Go to Apps > Develop apps > Create device
b. In the âDescriptionâ field, enterSonos System
c. In the âUPnP Device Filenameâ field, enterD_SonosSystem1.xml
d. In the âUPnP Implementation Filenameâ field, enterI_SonosSystem1.xml
e. You may choose a room assignment if you wish.
f. Click âCreate deviceâ - Go to Apps > Develop apps > Test luup code and reload luup by running
luup.reload()
- Wait about five minutes. Your Vera may reload several times during this time.
- Hard refresh your browser. Do not skip this step. You should now see your Sonos devices, and the Sonos System master device should report the number of zone players it is managing.
If anything appears out of whack and it doesnât resolve in 5-10 minutes, repeat steps 12-14. Sometimes it takes a couple of reloads and hard refreshes to get everything sorted.
The new Sonos System master device will adopt your previous/existing Sonos devices as its children (with the same device number theyâve always had), and create new child devices for any other zone players discovered on the network. There is usually no need to run discovery manually in this version.
Install check: The âSettingsâ tab of the Sonos master device should show 20080.1005 (or higher)
Configuration of TTS is done on the Sonos System master device. You will need to register for an Azure account and set up a subscription and cognitive services. Create a subscription here: https://azure.microsoft.com/free/
TO CREATE THE COGNITIVE SERVICES RESOURCE (AFTER CREATING A SUBSCRIPTION):
- Go to: Microsoft Azure
- Enter a name for the resource. âVera Sonos TTSâ for example.
- Select the subscription (youâll probably only have one to choose from)
- Location: choose the one that appears geographically nearest to you.
- Pricing tier, choose âS0â or whatever is available/cheapest.
- Resource group: choose an existing or create a new one. Doesnât much matter what it is if this is all youâll be using Azure for.
- Check the âOK/agreeâ box and then click âCreateâ.
- Wait for resource to be created. When itâs finished, click âGo to resourceâ.
- Enter the key shown into the Azure TTS config on the Sonos plugin.
- Look at the endpoint URL; it should be
<region>.api.cognitive.microsoft.com
⊠choose the region in the Azure TTS config for the Sonos plugin that matches the region shown.