Announcement

Collapse
No announcement yet.

Event not able to determine if Sonos is Playing

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • The Profit
    started a topic Event not able to determine if Sonos is Playing

    Event not able to determine if Sonos is Playing

    Hi Dirk,
    I have created the below event to turn on Sonos in our master bedroom in the morning when there is motion within a specific time. The event seems to keep triggering every time there is motion. I have a condition in the event to prevent it from triggering at every motion trigger "AND IF Sonos Master Bedroom State has a value that is not equal to Playing" but it isn't working. We recently noticed that the music would keep pausing for a second and then start the music again, which is why I noticed this issue. The State device does show that the Master Bedroom is Playing so I'm not sure why it would keep triggering.

    Any suggestions?

    Click image for larger version

Name:	Untitled.png
Views:	2
Size:	37.5 KB
ID:	1292352

  • The Profit
    replied
    Originally posted by teladog01 View Post

    Have you tried restarting HS3? I know it seems obvious but many times this initial troubleshooting step gets overlooked. I have found that when things all of a sudden start working differently than usual, when no changes have been made, a simple restart often times resolves the issue.
    Yes I did that a few minutes ago....I agree this is always a good idea!


    Sent from my iPad using Tapatalk

    Leave a comment:


  • dcorsus
    replied
    Originally posted by The Profit View Post

    Look at my original event in Post #1, I believe that is what I used to begin with. The event as it was originally has been working fine for quite some time until a few days ago. The issue is the player would stop playing and then start playing again. I first thought it may have been a buffering issue but when I saw that the event kept triggering with every motion trigger I started there. None of the other Sonos speakers have buffering issues and the one in the Master bedroom is within 8 feet of the AP.


    Sent from my iPad using Tapatalk
    I believe I have been focusing on the wrong issue ... Just changed my test to use device status and seems to work OK.
    Gotta run now but if you could confirm the trace you posted had the issue captured I can look at it again .... or .... you take a trace only when it happened and post that.
    Typically, I have made events that tend to have some "consistency" check added , say when motion for more than x seconds. It depends a bit on which sensor you have been using and how well you can trust it not to "bounce" .... I had a garage door opening sensor which would generate a bunch of on-off-on-off events before settling.
    Do also check your other events, recently a very similar issue was posted which (after posting a log) showed that one event triggered another and therefore interrupted, in this case, the TTS announcement, paired or linked players tend to be the culprit here ...

    Leave a comment:


  • teladog01
    replied
    Originally posted by The Profit View Post
    The event as it was originally has been working fine for quite some time until a few days ago.
    Have you tried restarting HS3? I know it seems obvious but many times this initial troubleshooting step gets overlooked. I have found that when things all of a sudden start working differently than usual, when no changes have been made, a simple restart often times resolves the issue.

    Leave a comment:


  • The Profit
    replied
    Originally posted by zwolfpack View Post
    You should change to State not equal Playing rather than Play ... Playing is a status value while Play is control value. Click image for larger version

Name:	Sonos State.PNG
Views:	3
Size:	172.2 KB
ID:	1292657
    Look at my original event in Post #1, I believe that is what I used to begin with. The event as it was originally has been working fine for quite some time until a few days ago. The issue is the player would stop playing and then start playing again. I first thought it may have been a buffering issue but when I saw that the event kept triggering with every motion trigger I started there. None of the other Sonos speakers have buffering issues and the one in the Master bedroom is within 8 feet of the AP.


    Sent from my iPad using Tapatalk

    Leave a comment:


  • zwolfpack
    replied
    You should have State not equal Playing rather than Play ... Playing is a status value while Play is control value. Click image for larger version  Name:	Sonos State.PNG Views:	1 Size:	172.2 KB ID:	1292657

    Leave a comment:


  • The Profit
    replied
    Originally posted by dcorsus View Post

    Just followed my own advice; you definitely can't set it to "Play", just tried that. It all looks OK but when in the HS device management page, and I click on the hyperlinked "State" device, select the "Advanced" tab, I see the Status as "1=Dim" and Value "1 = Playing", I wonder whether the problem is there to be found. Why wouldn't it show "Status : 1 = Playing" ????
    My player is currently Stopped and shows the same Status:

    Status: 2 = Dim
    Value 2 = “Stopped”



    Sent from my iPad using Tapatalk

    Leave a comment:


  • The Profit
    replied
    Originally posted by dcorsus View Post

    Same deal in this log .... HS is not querying the PI for the state of the player, it just executes the action ..... So it is not that the PI is returning the wrong answer to the "isnotPlaying" query ... it is not queried at all.

    Oh, I think I just saw the problem. You are comparing the HS DEVICE state to not playing, use the "Sonos Condition" = isnotPlaying. have to admit, it should work with using the HS device but perhaps you need to compare it against "Play" instead of "Playing", not sure myself, my recommendation, change it to a Sonos Condition and it should work.
    When you setup your test event, which condition did you use? The Sonos Condition with “isnotPlaying” or the HS device and “Play”?

    I will give the Sonos condition a try first, it seems to me that if it’s using your PI conditions it’s most likely to work. I’ll try using the HS Device against “Play” afterwords.....just for “Fun”. :-)


    Sent from my iPad using Tapatalk

    Leave a comment:


  • dcorsus
    replied
    Originally posted by dcorsus View Post

    Same deal in this log .... HS is not querying the PI for the state of the player, it just executes the action ..... So it is not that the PI is returning the wrong answer to the "isnotPlaying" query ... it is not queried at all.

    Oh, I think I just saw the problem. You are comparing the HS DEVICE state to not playing, use the "Sonos Condition" = isnotPlaying. have to admit, it should work with using the HS device but perhaps you need to compare it against "Play" instead of "Playing", not sure myself, my recommendation, change it to a Sonos Condition and it should work.
    Just followed my own advice; you definitely can't set it to "Play", just tried that. It all looks OK but when in the HS device management page, and I click on the hyperlinked "State" device, select the "Advanced" tab, I see the Status as "1=Dim" and Value "1 = Playing", I wonder whether the problem is there to be found. Why wouldn't it show "Status : 1 = Playing" ????

    Leave a comment:


  • dcorsus
    replied
    Originally posted by The Profit View Post

    Here is the HS3 Log.

    First thing in the morning everything starts off with just this event turning on the Master Bathroom Sonos, all of the other Sonos speakers are off. The only other event that I have that could turn on another Sonos occurs on Wed morning but it shouldn't have affected this test as we did it this morning. The state of the player shows "Stopped" when this event triggers and I have checked it after it has already triggered and it does show "Playing" in the State device. Could I be using an incorrect condition for the device?
    Same deal in this log .... HS is not querying the PI for the state of the player, it just executes the action ..... So it is not that the PI is returning the wrong answer to the "isnotPlaying" query ... it is not queried at all.

    Oh, I think I just saw the problem. You are comparing the HS DEVICE state to not playing, use the "Sonos Condition" = isnotPlaying. have to admit, it should work with using the HS device but perhaps you need to compare it against "Play" instead of "Playing", not sure myself, my recommendation, change it to a Sonos Condition and it should work.

    Leave a comment:


  • The Profit
    replied
    Originally posted by dcorsus View Post
    What player do you have in the master bathroom and is it paired?
    The Sonos speaker that I have in there is a Sonos Play 3 I believe. It’s the middle sized speaker that they have recently discontinued. It is a solo speaker in the room. I don’t have any speakers that are paired in the house.


    Sent from my iPad using Tapatalk

    Leave a comment:


  • dcorsus
    replied
    What player do you have in the master bathroom and is it paired?

    Leave a comment:


  • The Profit
    replied
    Originally posted by dcorsus View Post

    yes that would help :-)

    Is the "master bathroom" player by any chance paired or grouped with other players?
    If you go to the HS device page, is the state of the player correct before you create motion in the Bathroom and the event (wrongly) fires?
    Here is the HS3 Log.

    First thing in the morning everything starts off with just this event turning on the Master Bathroom Sonos, all of the other Sonos speakers are off. The only other event that I have that could turn on another Sonos occurs on Wed morning but it shouldn't have affected this test as we did it this morning. The state of the player shows "Stopped" when this event triggers and I have checked it after it has already triggered and it does show "Playing" in the State device. Could I be using an incorrect condition for the device?

    Attached Files

    Leave a comment:


  • dcorsus
    replied
    Originally posted by The Profit View Post



    I could send you my HS logs where it shows that the event is triggering, would that help?


    Sent from my iPad using Tapatalk
    yes that would help :-)

    Is the "master bathroom" player by any chance paired or grouped with other players?
    If you go to the HS device page, is the state of the player correct before you create motion in the Bathroom and the event (wrongly) fires?

    Leave a comment:


  • The Profit
    replied
    Originally posted by dcorsus View Post
    Just did a quick test, it seems to work as it should on my system but I didn't try 6 "IF" statements. How did you test this? Did you manually run the event or went into the bathroom and caused motion? If I run this event manually, it seem to skip any conditions and just executes the action. If I do a real test, it works as designed.
    If I triggered it manually it would have ignored all of the triggers and conditions that I had in the event so I enabled the event before we started our day so that it would trigger the event via motion. I took a look at the text file that I sent, I see where it is setting the station and volume but it is doing that every couple of minutes isn’t it?

    I could send you my HS logs where it shows that the event is triggering, would that help?


    Sent from my iPad using Tapatalk

    Leave a comment:

Working...
X