What is the deal with hub power backup?

Also, I have the hub on a 25' ethernet cable and a small portable UPS. In the past, this has let me move the hub close to Z-wave devices that were tricky to include or exclude, all while not having the hub lose power.

2 Likes

Outside of the ability to shutdown gracefully, mainly for the motion/contact sensors and locks for me, although many of my cameras are battery also.

5 Likes

As mentioned a few times above, one of my concerns is being able to properly shut down the hub.

But my house is also more than just light bulbs. :slight_smile: Most of my contact sensors, motion sensors, and whatnot are battery powered (and some, but not all, of my repeaters have battery backup; I suspect most devices can reach the hub directly if truly needed, but, yes, some may not while power is out). Say you're using Hubitat Safety Monitor. I'd still want it to activate the alarm when needed.

It also makes things more likely to work as expected when your power does come back. Say your hub was off during a scheduled mode change. You'll still be stuck in the "old" mode when power comes back. Same for any scheduled job, really. Just one less thing to worry about, IMHO!

5 Likes

I've mentioned this before but also consider a whole home surge protector.. not very expensive and can protect your appliances, smart bulbs etc as well.

4 Likes

Ironically, as I curse changing batteries and am now starting to avoid adding "curiosity devices' (those serving less than important purposes) the fact I'm still monitoring some critical things even when the power goes (by weather, load, or deviant purpose) is a comfort.

If I'm there it offers one level, if I'm not, it offers a heads up to go find out what's up. Yes, that means the broadband connection needs to be on UPS and up as well. Can't wait for the 'C9' to have a SIM card option so we can connect through the Cellular Network !!!! :stuck_out_tongue_winking_eye:

1 Like

I was just reading another post mentioning "mode correction" after power failure / upon startup:

I've read the same in our threads about "failsafe and startup" compensation and it still slays me that this is not an inbuilt function of the hub.

There are lots of good reasons to put the hub on a UPS.... that aside, and not to derail this thread...

... if you build a device wherein a power failure can get a fundamental scheduling construct like MODE out of sync ...and the consumer has to know to compensate for this...I'd say you're missing an opportunity to strengthen the failsafe nature of your product for the person plugging it in on DAY #1 having yet to read all these juicy morsels of good advice to compensate for what isn't built in.

1 Like

This is already possible. :smiley: (Just not with a SIM card alone.)


I don't know that this should be a hub function, but it would certainly be possible to write an alternative "Mode Manager" app that responds to the system start event and determines the likely desired mode based on time (and possibly presence, though if the hub was off when those events should have happened, who's to say it's accurate?). That actually might be a neat option for them to add to the existing app--seems straightforward enough (aside from the aforementioned possibility). The general consensus among staff with lots of other cases is that it's hard to know what you might want if the schedule was missed because the hub was off.

4 Likes

Hummm, I missed that and have used such modems in the past. Thanks for linking it.
[Correction: I HAD seen that but totally forgot! Just added some info to that thread, if HE were designed with IOT sim connectivity as an option it could be a very affordable setup for a remote location.]

Whether or not that capability ever gets built in or not I hope it is well recognized as broadband option and no gotchas arise on the HE side in using it.

On the Mode after power fail discussion:

Yeah, remembering that now.

I have a UPS that keeps my cable modem, WiFi Router, network switch, Hubitat hub, Lutron and Hue bridges powered during power failures. That also protects the electronics from power surges that are common when power comes back on.

It is true that lights and any mains powered devices will be offline, but if you have battery powered sensors such as motion sensors, contact sensors, water leak sensors, etc., they will continue to function.

1 Like

Same here. Plus most of my devices (unfortunatly) are battery powered. So even if the power goes out, things like leak sensors, contact sensors, my (local) alarm, etc, are still in play.

1 Like

This is not hard... If you have a device that includes a database of some sort, put it on a UPS. Period. Light switches and such are generally fine unless you get a decent power surge, and there's no easy way to keep them powered up, so you just hope for the best with those. But tiny little "computing devices" (such as routers and HE devices) do much better without abrupt power losses, and you really don't want to subject them to brownouts and rapid power cycling, which can happen as utilities come back online.

As others note, putting your modem, router, switches, APs, security system, and HE hubs (and that's not an all-inclusive list) on surge protection with battery backup is just cheap, easy problem prevention.

You learn stuff like this when you live on an island in Maine, way down a dirt road. That suburbia stuff is making some of you folks soft! (wink).

4 Likes

I've got all of my hubitats on UPSes, but is there a way for them to automatically power down gracefully when the power is out/the UPS is running low on battery power?

Yes, several ways.

I have Ring Alarm Extender v2 devices that not only are Z-Wave Extenders, but also have internal battery backup and send “switch to battery” events to the hub when mains power goes out. Then, I have a voting rule that handles the fact that power can go up and down for a while before it finally goes down, maintaining a count of how many Ring Extenders are presently down. The voting handles the case where one or two Ring Extenders may have dead backup batteries (and thus not report power fail), and handles the case where a Ring Extender may be accidentally knocked out of the wall socket. Then, after some number (4 of 6, in my rule) of the Ring Extenders have been on battery backup for a few minutes (shorter than the UPS uptime, but long enough to handle temporary outages), the Rule shuts the hub down using a command to a simple driver by Dominick Meglio (@dman2306):

Here is the power fail voting Rule and its local variable, etc:

Power Fail Rules

There are also six pairs of similar Rules, one for each Ring Extender. Here is one pair, for the first Ring Extender:

And here are the Hub Variables (f/k/a/ Global Variables) that keep track of the state of the Ring Extenders for use by the voting rule:

It’s also necessary to have the following Actions in your systemStart rule to handle the fact that any “switch to mains” power event from the Ring Extenders is lost while the hub it powered down, etc:

There is a bit of subtlety in the design of the voting rule and its supporting “Ring x to battery/mains” rules, such that it handles concurrent triggering/execution of the various rules as the power flaps up and down.

Larry Kahn (@kahn-hubitat) has also done a nice job on code that receives power and battery status from an APC UPS network card. You might check that out.

5 Likes

Thanks for the write up. I like the sophisticated solution. (It's too bad there's no easy/systematic way to see and use all of the great user-developed solutions in HA generally.)

I'll see if there's a good device to monitor and use Dominick's driver.

I have my Hubitat hub, WiFi Router, and Cable Modem on a UPS which will power all the devices for about 2 hours during a power outage. I also have a Ring Extender that acts as Home AC Power monitor and it sends a message to my Hubitat hub when there is a home power loss or when the power is restored. My Hubitat then goes into countdown mode and after a certain amount of time will do a graceful shutdown if the power is still out.

4 Likes

Of course, today I moved the hub 6" and the darn micro-USB cable fell off the back of the hub (but the other end connected to the UPS stayed in just fine). I wish that connection were more robust (or there was a way I could make it so the micro-USB cable didn't accidentally fall out of the hub).

Epoxy.

Are you serious? I was thinking hot glue.

1 Like

Oh, now you tell me.

Just got mine set up, albeit with just a single Ring extender. Was quick and easy, thanks to your help.

1 Like