fix cutoff a grid peak shaving register
Some checks failed
CI and deploy / migration-check (push) Failing after 13s
CI and deploy / deploy (push) Has been skipped

This commit is contained in:
Dusan Vojacek
2026-04-29 13:36:38 +02:00
parent 2c884e2135
commit dede8d604d
12 changed files with 79 additions and 125 deletions

View File

@@ -9,7 +9,6 @@ from services.control.exporter_monolith import (
ControlSetpoints,
InverterConfig,
_deye_reg178_verify_with_double_read,
_deye_reg179_verify_match,
_deye_tou_params,
_deye_tou_power_verify_match,
_deye_zero_export_amps_for_passive,
@@ -55,11 +54,6 @@ class ModbusVerifyPolicyTests(unittest.TestCase):
self.assertTrue(ok)
self.assertEqual(v, 48)
def test_reg179_verify_match_only_bits_0_1(self) -> None:
# expected=3 (enable), actual can have other bits set but bits0-1 must match
self.assertTrue(_deye_reg179_verify_match(3, 0xFFFB))
self.assertFalse(_deye_reg179_verify_match(3, 0xFFFA)) # bits0-1=2
def test_reg178_not_critical_for_self_sustain(self) -> None:
self.assertFalse(deye_reg_triggers_self_sustain_after_verify_exhaust(178))