From 048245f674678e0afc376cee0f8a8e91bb0fac99 Mon Sep 17 00:00:00 2001 From: linuswck Date: Mon, 18 Mar 2024 17:50:37 +0800 Subject: [PATCH] set_tec_max_i_pos/neg->...cooling_i/heating_i --- pykirdy/driver/kirdy_async.py | 8 ++++---- pykirdy/pid_autotune.py | 4 ++-- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/pykirdy/driver/kirdy_async.py b/pykirdy/driver/kirdy_async.py index 6c315a7..05de13c 100644 --- a/pykirdy/driver/kirdy_async.py +++ b/pykirdy/driver/kirdy_async.py @@ -358,16 +358,16 @@ class Thermostat: """ return await self._send_cmd(TARGET_THERMOSTAT, "SetTecMaxV", max_v) - async def set_tec_max_i_pos(self, max_i_pos): + async def set_tec_max_cooling_i(self, max_i_pos): """ - Set Tec maximum positive output + Set Tec maximum cooling current (Settable Range: 0.0 - 1.0) - max_i_pos: A """ return await self._send_cmd(TARGET_THERMOSTAT, "SetTecMaxIPos", max_i_pos) - async def set_tec_max_i_neg(self, max_i_neg): + async def set_tec_max_heating_i(self, max_i_neg): """ - Set Tec maximum negative output + Set Tec maximum heating current (Settable Range: 0.0 - 1.0) - max_i_neg: A """ return await self._send_cmd(TARGET_THERMOSTAT, "SetTecMaxINeg", max_i_neg) diff --git a/pykirdy/pid_autotune.py b/pykirdy/pid_autotune.py index e73d43c..8a280af 100644 --- a/pykirdy/pid_autotune.py +++ b/pykirdy/pid_autotune.py @@ -278,8 +278,8 @@ async def main(): await kirdy.thermostat.set_temp_mon_upper_limit(target_temperature + 20) await kirdy.thermostat.set_temp_mon_lower_limit(target_temperature - 20) - await kirdy.thermostat.set_tec_max_i_pos(output_step) - await kirdy.thermostat.set_tec_max_i_neg(output_step) + await kirdy.thermostat.set_tec_max_cooling_i(output_step) + await kirdy.thermostat.set_tec_max_heating_i(output_step) # The Polling Rate of Temperature Adc is equal to the PID Update Interval await kirdy.thermostat.config_temp_adc_filter("Sinc5Sinc1With50hz60HzRejection", "F16SPS")