with the just release Hubitat version (2.1.5) there is a new function to set the Hub time via an API call.
Here is a driver that allows you to specify a local NTP server to retrieve the date/time from and it will update the Hub accordingly.
Right now, the driver does NOT support SNTP, only plain old NTP, however. It checks the time on boot and every X minutes (configurable).
The configuration should be pretty self-explanatory but I am happy to elaborate if anyone has questions.
You do need Hubitat version 2.1.5 or higher to have this driver working!
Anything capable of running a NTP server that's always on; PC, laptop, rPI, etc. I have a simple NTPd server running on a rPI Model 3B, for instance. Works flawlessly.
To add to that list of devices that can be NTP servers: NAS, and some routers/firewalls running for example openwrt, pfsense, Mikrotik. All of these can also have their NTP time synced using a cheap USB GPS dongle, which makes them great for setting time even when there is no Internet access.
You can put in any NTP server you want. Having a local NTP service just makes your HE less reliant on cloud and all of your local time based systems to be in sync from a single local source.
I suspect that the hub doesn't update its clock on a continuous basis after the one check it does at boot time. So your HE clock will drift over time. After a couple of weeks, mine was a good 4-5 seconds off. This NTP client can be set to update your clock periodically and/or if its out of sync by various amounts.
Question:
Should I be worried about the following error?
I set up a Virtual Device with this as the device driver, and pressed "refresh".
That should update to the NTP time? (if the hub is off)
And it still happens when you press refresh. It might have been from the very first execution when you installed the driver and there was no IP address yet