twrecked / hass-aarlo

Asynchronous Arlo Component for Home Assistant
GNU Lesser General Public License v3.0
394 stars 78 forks source link

Doorbell Silent Mode (Chime and Call) #385

Open krelltunez opened 3 years ago

krelltunez commented 3 years ago

I previously had working toggles for the "silent mode" for the Arlo Video Doorbell's chimes and calls using this add-on. I used this in a "naptime" automation that silences all Echo devices and the Doorbell, as well as my phone notifications. At some point, the toggles for the doorbell stopped working. I am not certain when this happened, so I can't pinpoint it to an HA release. It may have corresponded with one of the latest hass-aarlo updates but I cannot say that with any degree of certainty.

Any idea how I could troubleshoot this? I'm pretty good with Home Assistant but have never done a ton of troubleshooting before. I've got no idea what the next steps might be here, but I'm happy to try!

Also curious whether anyone else is seeing this? I know there may not be many users that have the doorbell.

krelltunez commented 3 years ago

Broken, unfortunately. I get an error when I toggle any of the 3 switches - 'ArloDoorBell' object has no attribute '_chimes'

Log attached.

HA Log Encrypt.txt

twrecked commented 3 years ago

Got it. Give me a min. I have chimes so I missed a variable.

twrecked commented 3 years ago

Hopefully: #390

You don't have chimes - thanks for the logs, they really help - so I handle that now.

Sorry this is taking longer than it should but I don't have all the Arlo devices so I rely on other people debugging this stuff.

krelltunez commented 3 years ago

Getting there. I'm seeing some strangeness. Going through switch by switch:

  1. xxx_silent_mode_call
    • stays toggled on (and toggling off in HA works)
    • Arlo app is inconsistent, though - see below:
    • Under "Silent Mode" it says "Incoming calls and chimes are currently turned off."
    • Under "WHEN SILENT MODE IS ON" the first toggle ("Incoming Call") is off and the second ("Traditional Chime") is on
    • (See screenshot 3 in my post from yesterday)
  2. xxx_silent_mode_chime
    • does not stay toggled on
    • Arlo app is inconsistent - see below:
    • Under "Silent Mode" it says "Chimes are currently turned off." BUT...
    • Under "WHEN SILENT MODE IS ON" both toggles ("Incoming Call" and "Traditional Chime") are on
    • (See screenshot 2 in my post from yesterday)
    • It seems like the "Traditional Chime" toggle should be off, right?
  3. xxx_silent_mode_chime_call
    • stays toggled on (and toggling off in HA works)
    • Arlo app is inconsistent, though - see below:
    • Under "Silent Mode" it says "Incoming calls and chimes are currently turned off." BUT...
    • Under "WHEN SILENT MODE IS ON" the first toggle ("Incoming Call") is off and the second ("Traditional Chime") is on
    • (See screenshot 3 in my post from yesterday)
    • It seems like this should look like screenshot 1

Finally, if I toggle silent mode on in the Arlo app, I'm still not seeing it reflected in HA. I checked my.arlo.com and that lines up with what I see/do in the app, so I think this is on the HA end of things.

And no worries at all, I'm happy to keep helping. The only part that's hard/annoying for me is dealing with the log file.

twrecked commented 3 years ago

The traditional toggle should be fixed now.

As to the last point; it updates in the webpage if you change it from the app; I'll take a look at that from here. Everything normally comes in over a websocket, which I open from Arlo, so maybe it's getting opened differently.

krelltunez commented 3 years ago

Looks like it's working now. Note that when I toggle xxx_silent_mode_call, the message in the Arlo app says "Incoming calls and some chimes are currently turned off." When I toggle xxx_silent_mode_chime_call, it says "Incoming calls and chimes are currently turned off."

I still don't understand the logic behind the toggles under "WHEN SILENT MODE IS ON" in the Arlo app, because they don't always seem to match the message under "Silent Mode." But that's for another day.

Now that it's a little warmer outside, I will try to test this out when I won't drive my family nuts by doing so.

twrecked commented 3 years ago

That bit of the App is really confusing, I think that message must be statically generated. I did notice when you turn them both on - ie, allow both when silent - it turns silent mode off. There's too much double negative for me.

What's more interesting is the fact that when you change your silent mode in the app it updates on the web page. hass-arlo and the web page use the same mechanism -server sent events (sse) - so if the web page gets that information so should we but I'm not seeing it in the logs. I've spent some time looking at headers in the URL request and I've updated the ones in the Arlo code, that might help but I'm not too hopeful.

dejan2101 commented 3 years ago

Sorry, wasn't around yesterday :/ I'm sad to report my binary_sensors are still not being updated when motion/ding happens and also the recent activity and last event sensors are not updated.

twrecked commented 3 years ago

@dejan2101 Sounds like you have other issues going in. Can you:

If that doesn't show anything we'll need to get at the debug logs.

dejan2101 commented 3 years ago

everything seems to be ok in the Arlo app

twrecked commented 3 years ago

In that case we need to look at the logs. If it's just a crash we might not need to on any debug. Open in homeassistant.log, it will be created next to configuration.yaml, and look for the word traceback.

wizonesolutions commented 3 years ago

When I turn on Silent Mode from the web, I see:

{"from":"[snip]","to":"[snip]","action":"set","resource":"doorbells/[snip]","transId":"[snip]","publishResponse":true,"properties":{"silentMode":{"active":true,"call":true,"chimes":{"[snip]":true,"traditionalChime":true}}}}

Does this help? Is it different than the payload switch.aarlo_CAMERANAME_silent_mode_chime_call sends? No combination of the pseudo switches turns on full Silent Mode for me, but it works from the web. I have an Arlo Video Doorbell Wire-Free.

wizonesolutions commented 3 years ago

Ah. I see the problem in https://github.com/twrecked/pyaarlo/blob/master/pyaarlo/doorbell.py#L127

It seems that on my system, the property is called traditionalChime. However, pyaarlo expects it to be called traditional. Does this need to be configurable? I don't know if it varies by device or something.

wizonesolutions commented 3 years ago

Opened https://github.com/twrecked/pyaarlo/pull/76

twrecked commented 3 years ago

@wizonesolutions Thanks for looking into this, I'll take a look at your PR this week.