Mode Manager Not Setting Correct Mode - v 2.3.4.122

I've noticed some weirdness with Mode Manager the last couple of days. I don't know if it's related to the v2.3.4.122 update or not. My "Evening" mode should be set only at 10 minutes before Sunset. If I'm away and return, the mode is always set to "Home", but there's a RM rule that runs that checks the time. If the mode should be evening, it turns on the "Evening" switch and the mode changes to Evening.

This morning I left the house to walk the dog. Mode changed from Home to Away. The Evening switch was off. When I returned, the Mode was set to Evening directly. And, sure enough, when I came in the door the house behaved as though it were evening. Evening should never be set directly when I return home, so not sure what's going on here. Mode Manager settings and log attached.

This has only happened once. But yesterday when the mode should have been Home it switched to Asleep. I don't have those logs, sorry.


By using Return From Away with presence, that means set the mode per the time table upon that event. Since you have no times for the other modes, I'm pretty sure it would pick Evening.

It's a rather bizarre setup for the Times table.

I has reliably returned as Home for a long, long time. It was set up this way in the old Mode Manager as well. This is new behavior.

It may seem "bizarre" to you. But my use case is that Evening is the only mode that changes based on time. All other modes change based on switches or presence.

Here are the logs from yesterday, showing that it changed to Home when I returned from Away.

And this is the documentation in Mode Manager under "Help for times table." This says that if the mode is skipped in the times table, the other methods of setting Mode will be used.

That doesn't really apply to Return from Away. As I said, it's looking for the current period based on the times. With only one time, it only has one choice.

The way Return From Away works is that is uses a Shadow Mode. When the mode is set by a time, the Shadow Mode is also set. So in your case, the Shadow Mode is always Evening. Then, if you're Away, and the mode changes to some other timed set mode, the Shadow Mode would be updated (since the mode itself shouldn't change due to Skip). Then when Return From Away happens, the mode is set to Shadow Mode. For your setup, this will always be Evening.

But something must have changed because this has been working to return to Home for a long time - see log in previous post. When the presence returns, the "Switch - Home" is turned on, so shouldn't that set mode to Home per the switches table?

You've got a potential race condition between Mode Manager and whatever sets the switch. You should just get rid of Return From Away for Presence, and do it with the rule that sets the switch.

Ok. I'll give that a try. Thanks.

It appears that there's no way to removed the "Return From Away for Presence" except to just remove the listed presence sensor(s). Is that correct and will that work?

Yes, deselect the sensor. Be sure to hit Done.

I gave that a try on my afternoon dog walk, and mode was Home when I returned.

In this case, though, it should have transitioned to Evening because it was sunset. :rofl: What happened was the geofence reported arrived just before sunset, and I actually walked in the door just after sunset. I'm laughing, because what are the chances?

No problem with this, though. I just need to tweak my "Home" RM rule to wait until I'm actually there to determine if it should be evening.

Thanks for your help @bravenel.

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.