def parse_data(self, device, raw_data): AjaxDevice.parse_data(self, device, raw_data) self._in_use = device["active"] self._load_power = device["current"] self._power_consumed = device["powerConsumed"] self._voltage = device["voltage"] self.async_schedule_update_ha_state()
def parse_data(self, device, raw_data): AjaxDevice.parse_data(self, device, raw_data) self._motion = device["motionPresent"] self.async_schedule_update_ha_state()
def parse_data(self, device, raw_data): AjaxDevice.parse_data(self, device, raw_data) self._closed = device["reedClosed"] self.async_schedule_update_ha_state()
def parse_data(self, device, raw_data): AjaxDevice.parse_data(self, device, raw_data) self._leak = device["leakDetected"] self.async_schedule_update_ha_state()
def device_state_attributes(self): return AjaxDevice.get_attributes(self)
def __init__(self, device, ajax_hub, device_class): AjaxDevice.__init__(self, device, ajax_hub) self._device_class = device_class
def parse_data(self, device, raw_data): AjaxDevice.parse_data(self, device, raw_data) self._smoke_alarm = device["smokeAlarm"] self.async_schedule_update_ha_state()
def __init__(self, device, ajax_hub): AjaxDevice.__init__(self, device, ajax_hub) self._in_use = device["active"] self._load_power = device["current"] self._power_consumed = device["powerConsumed"] self._voltage = device["voltage"]