Groovy / Source question
I have been noticing that after a hub reboot, some of my devices are out of sync. How can I force (in the device drivers and/or apps) to issue some command (like refresh) when the hub is back up after a reboot?
Groovy / Source question
I have been noticing that after a hub reboot, some of my devices are out of sync. How can I force (in the device drivers and/or apps) to issue some command (like refresh) when the hub is back up after a reboot?
Perhaps youcan do this with a rule?
Use the location event systemStart and the trigger, and run a refresh() for all the devices you need whose drivers expose the refresh() command.
Thank you. I am specifically looking for details on how to do this in the drivers and apps I write. I want the system to be able to self-correct even if auto-refresh is turned off on my systems
You can look at the Initialize capability for drivers. This may be available for apps, but Im not sure.
More info:
Thank you.
initialize()
needs the capability added to work. That appears to be what I was missing.
initialize() - runs first time driver loads, ie system startup when capability Initialize exists, a Initialize command is added to the ui.
It definitely does. That messed me up regularly early on.