Files
ems/db/migration/V096__heat_pump_mim_b19n.sql
Dusan Vojacek d63a85a2ea
Some checks failed
CI and deploy / migration-check (push) Failing after 7m29s
CI and deploy / deploy (push) Has been skipped
TČ Samsung přes MIM-B19N: endpoint 172.16.1.17, plný poll, registry doc
- V096: endpoint home-01 TČ z placeholderu 192.168.1.103 na reálný Waveshare
  RS485 TO POE ETH (B) 172.16.1.17:502; telemetry_heat_pump.room_temp_c.
- R__048: fn_telemetry_heat_pump_sample rozšířena (water_inlet, room_temp,
  defrost, alarm_code) — drop/comment bez parametrů dle konvence.
- poll_heat_pump: místo TODO stubu (zapisoval dummy 45/55 °C!) skutečné čtení
  MIM bloku 50-75 + defrost reg 2; gate na comm_status ready (jinak skip);
  operating_mode off/heat/cool/auto/dhw/error; power_w NULL (MIM příkon nemá).
- docs/04-modules/modbus-registers-mim-b19n.md (mapa, 9600 8E1, DIP adresa,
  troubleshooting E6xx) + heat-pump.md odkaz.

Živý stav: TCP :502 OK, Modbus bez odpovědi (čeká na protokol převodníku /
paritu EVEN / polaritu A-B — checklist v docu).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-12 18:24:10 +02:00

22 lines
995 B
SQL
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
-- Samsung TČ (EHS) přes Modbus interface MIM-B19N(T): skutečný RS485→TCP
-- převodník (Waveshare RS485 TO POE ETH (B)) na 172.16.1.17 nahrazuje
-- placeholder 192.168.1.103 ze seedu. MIM = Modbus RTU slave, 9600 8E1,
-- adresa dle DIP/rotary (zde 1). Registry: docs/04-modules/modbus-registers-mim-b19n.md.
update ems.site_endpoint e
set host = '172.16.1.17',
port = 502,
notes = 'Waveshare RS485 TO POE ETH (B) pro Samsung EHS přes MIM-B19N(T). Sériová linka 9600 8E1 (parita EVEN!), Modbus TCP server :502, unit_id = adresa MIM dle DIP (1).'
where e.id = (
select hp.endpoint_id
from ems.asset_heat_pump hp
join ems.site s on s.id = hp.site_id
where s.code = 'home-01'
);
alter table ems.telemetry_heat_pump
add column if not exists room_temp_c numeric(5,2);
comment on column ems.telemetry_heat_pump.room_temp_c is
'Prostorová teplota hlášená vnitřní jednotkou (MIM reg base+9, °C×10). Vstup budoucího termálního modelu domu.';