Working version with heating reading

This commit is contained in:
Constantin Pascal
2025-12-28 11:38:33 +02:00
parent bc976e33b3
commit 76411f4434
2 changed files with 43 additions and 4 deletions
+2
View File
@@ -15,6 +15,7 @@ DEFAULT_PORT = 502
# Modbus register configuration
TEMP_HUMIDITY_REGISTER = 0x83 # Register 131 (decimal)
SETPOINT_REGISTER = 144 # Register 144 (decimal, 0x90 hex)
HEATING_STATUS_REGISTER = 211 # Register 211
REGISTER_COUNT = 4
# Coil configuration
@@ -56,6 +57,7 @@ class SlaveData:
available: bool = True
coils: list[bool] | None = None # 40 coil states (True=ON, False=OFF)
registers: dict[int, int] | None = None # Register address -> int16 value
setpoint: float | None = None # Target temperature setpoint (°C)
@dataclass