'Update the controller with the latest value from a sensor.'

def update(self):

    node = self.gateway.sensors[self.node_id]
    child = node.children[self.child_id]
    set_req = self.gateway.const.SetReq
    for (value_type, value) in child.values.items():
        _LOGGER.debug('%s:    value_type    %s,    value    =    %s', self._name, value_type, value)
        if (value_type in (set_req.V_ARMED, set_req.V_LIGHT, set_req.V_LOCK_STATUS, set_req.V_TRIPPED)):
            self._values[value_type] = (STATE_ON if (int(value) == 1) else STATE_OFF)
        elif (value_type == set_req.V_DIMMER):
            self._values[value_type] = int(value)
        else:
            self._values[value_type] = value
