In a custom plugin, I have a method reading a state value for targeted device, doing some things modifying this value, and at the end updating the device state with the new value. It looks like this :
Code: Select all
def selectZone(self, action, dev):
activeZone = dev.states[u'activeZone']
... some very interesting things ...
dev.updateStateOnServer("activeZone", value=targetZone)Is it normal ?
