I have this saved in my Templates:
May 25, 2018
installed() - runs when driver is installed, via pair or virtual
configure() - runs when driver is installed, after installed is run. if capability Configuration exists, a Configure command is added to the ui
initialize() - runs first time driver loads, ie system startup when capability Initialize exists, a Initialize command is added to the ui.
updated() - runs when save is clicked in the preferences section
Initialized() is not a capability or built in driver command, it's a local method only, I've never understood it either, i guess it saves a few lines of duplicate calls...
But it seems one definition is missing:
uninstalled() - runs when device is removed
My driver template is nothing but those routines and so on... if I install it as-is, and then create a virtual device to use it, I can see the methods being called easily enough:
dev:433 2021-04-20 09:29:40.346 am trace Msg: uninstalled ran
dev:433 2021-04-20 09:29:32.084 am trace Msg: updated ran
dev:433 2021-04-20 09:29:20.267 am trace Msg: installed ran
dev:433 2021-04-20 09:29:20.262 am trace Msg: initialize ran
Initialize and installed both ran as a result of creating the virtual device.
Updated ran as a result of clicking Save Preferences.
Uninstalled ran as a result of clicking Remove Device.