From 11db632d7e20c34ff3332f48083839f52c8c6465 Mon Sep 17 00:00:00 2001 From: mle Date: Sat, 25 May 2024 18:22:53 +0200 Subject: [PATCH] Add Start/Stop/Restart settings to DT inverters. --- goodwe/dt.py | 4 ++++ tests/test_dt.py | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/goodwe/dt.py b/goodwe/dt.py index f3979a7..57e780a 100644 --- a/goodwe/dt.py +++ b/goodwe/dt.py @@ -114,6 +114,10 @@ class DT(Inverter): Integer("shadow_scan", 40326, "Shadow Scan", "", Kind.PV), Integer("grid_export", 40327, "Grid Export Enabled", "", Kind.GRID), Integer("grid_export_limit", 40328, "Grid Export Limit", "%", Kind.GRID), + Integer("start", 40330, "Start / Power On", "", Kind.GRID), + Integer("stop", 40331, "Stop / Power Off", "", Kind.GRID), + Integer("restart", 40332, "Restart", "", Kind.GRID), + Integer("grid_export_hw", 40345, "Grid Export Enabled (HW)", "", Kind.GRID), ) # Settings for single phase inverters diff --git a/tests/test_dt.py b/tests/test_dt.py index 9bb9518..56fae94 100644 --- a/tests/test_dt.py +++ b/tests/test_dt.py @@ -101,7 +101,7 @@ def test_GW6000_DT_runtime_data(self): self.assertFalse(self.sensor_map, f"Some sensors were not tested {self.sensor_map}") def test_GW6000_DT_setting(self): - self.assertEqual(4, len(self.settings())) + self.assertEqual(8, len(self.settings())) settings = {s.id_: s for s in self.settings()} self.assertEqual('Timestamp', type(settings.get("time")).__name__) self.assertEqual('Integer', type(settings.get("grid_export")).__name__)