driver: Add support for GetPollInterval cmd

This commit is contained in:
linuswck 2024-10-10 15:19:43 +08:00
parent 51b82e0447
commit 9bec56ed6c

View File

@ -66,6 +66,7 @@ class CmdList:
SetPidOutMin = _dt.f32,
SetPidOutMax = _dt.f32,
ConfigTempAdcFilter = _dt.temp_adc_filter,
GetPollInterval = _dt.none,
SetTempMonUpperLimit = _dt.f32,
SetTempMonLowerLimit = _dt.f32,
ClearAlarm = _dt.none,
@ -620,6 +621,10 @@ class Thermostat:
}
return await self._send_raw_cmd(cmd)
async def get_poll_interval(self):
return await self._send_cmd(self._cmd._target, self._cmd.GetPollInterval, msg_type="Interval")
class Kirdy:
def __init__(self):
self.device = Device(self._send_cmd, self._send_raw_cmd)