Jump to content

Welcome to Smart Home Forum by FIBARO

Dear Guest,

 

as you can notice parts of Smart Home Forum by FIBARO is not available for you. You have to register in order to view all content and post in our community. Don't worry! Registration is a simple free process that requires minimal information for you to sign up. Become a part of of Smart Home Forum by FIBARO by creating an account.

 

As a member you can:

  •     Start new topics and reply to others
  •     Follow topics and users to get email updates
  •     Get your own profile page and make new friends
  •     Send personal messages
  •     ... and learn a lot about our system!

 

Regards,

Smart Home Forum by FIBARO Team


  • 0

Quick App - Sonos Zone Controller


Krikroff

Question

Current version: 1.4.0
Date: 15/03/2021

 

Please login or register to see this image.

/monthly_2020_10/Preview_1.3.1.PNG.07af3ad8f4e892c6f2a00a8452a48bde.PNG" />

 

FUNCTIONS


The functions of this Quick App are:

Allowing to control Sonos Player from Home Center 3. It does support basic and advanced functions:

 

  • Basic Transport Control
    • Initiate playback
    • Toogle, Pause or Stop playback
    • Skip to the previous or Next track
  • Basic Rendering Control
    • Get player volume and mute state
    • Set player volume to a specific level and unmute the player if muted
    • Increase or decrease player volume
    • Get or Set or Toggle player mute state (Mute or unmute the player)
    • Get or Set or Toggle player loudness state
  •  Device Properties
    • Get or Set group LED state
  • Restart the QA Device
  • Enable Debug Mode

 

See Changelog / Manual for basic and advanced available actions

 

Examples:

  • Set player volume to a specific level and unmute the player if muted.
    fibaro.call(ID_QUICKAPP, "setVolume", 10, "Master")
  • Increase or decrease player volume.
    fibaro.call(ID_QUICKAPP, "setRelativeVolume", -5, "Master")
  • Initiate playback.
    fibaro.call(ID_QUICKAPP, "play")
  • Play a file at volume 10 with snapshot/revert process to restore previous state
    fibaro.call(ID_QUICKAPP, "playFile", "35HTGV34R7S/CD/Album/song.flac", true, 10)
  • Play a stream at volume 20 & 8s duration with snapshot/revert process to restore previous state
    fibaro.call(ID_QUICKAPP, "playStream", "https://s3.amazonaws.com/smartapp-media/sonos/bell1.mp3", true, 20, 8000)

 

Version 1.4.0

Tested with Sonos Sonos OS: S2 - Version 13 (number 62186220)
Tested with HC3 & HC3Lite v5.050.13 -> v5.063.30

  • Fix for Sonos firmware version 13
  • Fix for Sonos ARC getPositionInfo and malformed xmlsoap (hope full supoport soon)
  • Add playNextRadio command to navigate the radios
  • Add play mode control from QA button (loop in NORMAL,REPEAT_ALL,REPEAT_ONE,SHUFFLE_NOREPEAT,SHUFFLE,SHUFFLE_REPEAT_ONE)
  • Fix Radio metadata strange behaviors in some situations

 

 


 

Version 1.3.8

Tested with Sonos Sonos OS: S2 - Version 12.2.2 (number 61183220)

 

  • Improved support for albumArt, now work with Sonos Radio, Amazon Music, Spotify, TuneIn, Music library
  • Add option 'protect' to playFile and playStream for disallow to restart a playing
  • Add Crossfade mode support with getCrossfadeMode, setCrossfadeMode and toggleCrossfadeMode commands
  • Add sleepTimer command
  • Add setPlayMode command, support: NORMAL,REPEAT_ALL,REPEAT_ONE,SHUFFLE_NOREPEAT,SHUFFLE,SHUFFLE_REPEAT_ONE
  • Add selectLineIn command
  • Add in variables panel, "notification" variable to enable or disable the "Device notification error", if disabled QA trace the message in QA console only
  • Various improvement

 

Version 1.3.1 RC

Tested with Sonos Software Version: 56.0-76060 / Sonos OS: S2 - Version 12.0.5 & 12.1

 

  • Add support to use in block scenes (Play, Pause, Stop, Next, Prev, Set Volume, Set mute) 
  • Support for album covers when available (cf. music library)
  • Performance improvement when initiating a playback
  • Improved radio playback and track information
  • Increase the number of supported radio stations (with auto configuration up to 9)
  • Support for Sonos playlists (with auto configuration up to 6 saved queues)
  • Add playFile command
  • Add playStream command
  • Add playSavedQueue command
  • Add startQueue command
  • Add clearQueue command
  • Add seek command
  • Add snapshot command
  • Add revert command
  • Add getListSavedQueues command
  • Add addURIToQueue command
  • Add checkForUpdate command
  • Add getTreble and setTreble commands
  • Add getBass and setBass commands
  • Various Bug fixes (Polling when not configured, parsing ...)

 

Version 1.1.1

  • Support for TuneIn "My radio stations" (with auto configuration up to 6 radios)
  • Deletion of the variable variable "isConfigured" used by internal FTI Configuration
  • Minor bug fixes (No route to host cause wrong configuration status)
  • Tested with Sonos Software Version:55.1-74250 and 56.0-76060
  • Performance improvement

 

Version 1.0.3

  • Fix a problem with internal zoneGroups and ZoneGroupMembers parsing (Thanks to jgab, Alan Klepacz and robw)

 

Version 1.0.2

  • Minor bug fixes (Thanks to Macschimmi, Bodyart, minsad79) 

 

Version 1.0.0

  • Based on my HC2 virtual Device and completely rewriten for HC3 v5.030.45 or highter
  • Very low latency and more robust device (commands execution, processing)
  • Easy installation with auto configuration assist
  • Support standard capabilities (AVTransport, RenderingControl)
  • Displaying information on the currently playing or media loaded
  • Fully controllable from the LUA scenarios (see available command list)

 

 

You can download it from the Fibaro market: 

Please login or register to see this link.

 

 hope you will be pleased with it

 

 

ROADMAP

  • Support for multi-devices in group used for triggering in scene and prepare for group-ungroup
  • Support for TV source (if supporteed by device)
  • Support for Group
  • Support for TTS
Edited by Krikroff
Version 1.4.0
  • Like 17
  • Thanks 2
Link to comment
Share on other sites

Recommended Posts

  • 0
On 8/13/2020 at 11:06 PM, Rover said:

@Krikroff

With HC2 my main use of the Sonos VD is producing Sonos sounds with mp3's for Alarm, Doorbell, etc. also with use of Sonos TTS VD.

Is the momentary version of the HC3 Sonos QA (1.1.0 referred here as 1.1.1) already capable of playing mp3 sounds? I do not need real Test To Speak.

 

I'd like to do the same thing. I've migrated from HC2 to HC3 & would love to play a doorbell sound through Sonos, like I could through your Sonos controller on HC2.

 

Link to comment
Share on other sites

  • 0
On 9/20/2020 at 9:35 AM, michaelash said:
On 8/14/2020 at 12:06 AM, Rover said:

@Krikroff

With HC2 my main use of the Sonos VD is producing Sonos sounds with mp3's for Alarm, Doorbell, etc. also with use of Sonos TTS VD.

Is the momentary version of the HC3 Sonos QA (1.1.0 referred here as 1.1.1) already capable of playing mp3 sounds? I do not need real Test To Speak.

 

I'd like to do the same thing. I've migrated from HC2 to HC3 & would love to play a doorbell sound through Sonos, like I could through your Sonos controller on HC2

Please @Krikroff, could you answer this question?

This is very important for me.

Link to comment
Share on other sites

  • 0
Guest rafal_ll
W dniu 26.09.2020 o 10:27, Rover napisał:

Proszę @Krikroffczy mógłbyś odpowiedzieć na to pytanie?

To jest dla mnie bardzo ważne.

It is also important to me. Please

Link to comment
Share on other sites

  • 0
  • Inquirer
  • Hi guys! Sorry for the delay, a new version soon available (in review on market). 

     

    RELEASE NOTES

     

    Version 1.3.1 RC

     

    Tested with Sonos Software Version: 56.0-76060 / Sonos OS: S2 - Version 12.0.5 & 12.1

    • Add support to use in block scenes (Play, Pause, Stop, Next, Prev, Set Volume, Set mute) 
    • Support for album covers when available (cf. music library)
    • Performance improvement when initiating a playback
    • Improved radio playback and track information
    • Increase the number of supported radio stations (with auto configuration up to 9)
    • Support for Sonos playlists (with auto configuration up to 6 saved queues)
    • Add playFile command
    • Add playStream command
    • Add playSavedQueue command
    • Add startQueue command
    • Add clearQueue command
    • Add seek command
    • Add snapshot command
    • Add revert command
    • Add getListSavedQueues command
    • Add addURIToQueue command
    • Add checkForUpdate command
    • Add getTreble and setTreble commands
    • Add getBass and setBass commands
    • Various Bug fixes (Polling when not configured, parsing ...)
    • Like 4
    • Thanks 1
    Link to comment
    Share on other sites

    • 0

    Krikroff!!

     

    Thanks for the update! Really looking forward to this release!

    Link to comment
    Share on other sites

    • 0
  • Inquirer
  • QA now available to download from marketplace :)

    • Like 1
    • Thanks 2
    Link to comment
    Share on other sites

    • 0
    1 hour ago, Krikroff said:

    QA now available to download from marketplace :)

     

    Krikoff - Thank you so much!!!

     

    The updated functionality was exactly what I've been looking for - My doorbell now plays a sound in three Sonos zones!

     

    It was also so much easier to set up than on my old HC2.

     

    For anyone interested here's a screenshot of the new scene using Kirkoff's Quick App.

     

     

    Please login or register to see this attachment.

    • Like 2
    Link to comment
    Share on other sites

    • 0

    If anyone of you has an idea how I get the icons displayed in the app, I have stored them in the HC3 and are also displayed

    Link to comment
    Share on other sites

    • 0
    3 hours ago, michaelash said:

    The updated functionality was exactly what I've been looking for - My doorbell now plays a sound in three Sonos zones!

    When the doorbell sound interrupts playing music, is this music continuing with the same own volume level after playing the doorbell?

    Link to comment
    Share on other sites

    • 0
    9 hours ago, Rover said:

    When the doorbell sound interrupts playing music, is this music continuing with the same own volume level after playing the doorbell?

    Yes, it does!

    Link to comment
    Share on other sites

    • 0
  • Inquirer
  • 14 hours ago, Macschimmi said:

    If anyone of you has an idea how I get the icons displayed in the app, I have stored them in the HC3 and are also displayed


    set QA iconId variable with the desired icon ID.

    Link to comment
    Share on other sites

    • 0

    Krikroff thanks,

     

    Quick app works fine. 

     

    Is it possible to play sound (mp3) from google drive?

     

    I tryed to make with lua a scene. I get no sound on sonos Play1.

     

    Who can help me further?

     

    Thanks

     

     

    Please login or register to see this attachment.

    Link to comment
    Share on other sites

    • 0
  • Inquirer
  • Hi, files must be in your Sonos music library, could you try with playStream ?

    Link to comment
    Share on other sites

    • 0

    @Krikroff

     

    Super update! Much easier to use than the similar functionality in the HC2.

     

    But are seeing one issue, not sure what it is related to:

     

    Are using the "playFile" function to play a mp3 file stored on a NAS when someone presses the doorbell button. This works just fine and I have the sound played in three different Sonos speakers in the house. But if the doorbell button are pressed several times a strange thing happened, the sound is played several time as it should, and then there is a 5-10 silence after that last play of the sound and then the last 1-2 seconds of the sound is played again in all three speakers

    • Like 1
    Link to comment
    Share on other sites

    • 0
  • Inquirer
  • @JcBorgs, in next release: New option 'protect' to playFile and playStream for disallow to restart a playing

    Link to comment
    Share on other sites

    • 0

    @Krikroff

     

    I trying playStream --> not working.  Also with link MP3 from Synology NAS.

     

    fibaro.call(558"playStream""http://gofile.me/3k0Fd/ZnfTuVmq8, true, 50, 1400) 
     
    I'm getting error [14.10.2020] [11:32:15] [ERROR] [SCENE206]: (load):1: unfinished string near
     
    What do i wrong?
     
    Thanks.
    Link to comment
    Share on other sites

    • 0
  • Inquirer
  • Perhaps with a " to close the uri string ;)

     

    Link to comment
    Share on other sites

    • 0

    @KrikroffThanks for a great QA. Forgive me if this is already covered, but didn't find it mentioned.

     

    I have several zones where I vary how I group them (in the Sonos app). Now, I try to create a scene where a radio channel is played on 2 of the zones, indepenent of how they originally were grouped (or not) in the Sonos app. Tried the actions:

    fibaro.call({[1] = 37, [2] = 38, }, "setVolume"10"MASTER")
    fibaro.call({[1] = 37, [2] = 38, }, "playRadio"3)
    but the problem is that they are launched as individual streams and not as one stream, hence the streams are not in sync.
     
    Is there any way to define a group and "playRadio" as one? If not, would be a neat feature ?
    Link to comment
    Share on other sites

    Join the conversation

    You can post now and register later. If you have an account, sign in now to post with your account.

    Guest
    Answer this question...

    ×   Pasted as rich text.   Paste as plain text instead

      Only 75 emoji are allowed.

    ×   Your link has been automatically embedded.   Display as a link instead

    ×   Your previous content has been restored.   Clear editor

    ×   You cannot paste images directly. Upload or insert images from URL.

    ×
    ×
    • Create New...