Integrate LG Heatpump into HA using modbus?

For some time I’ve wanted to add my LG Heatpump (HM163MR U34 16kW) to my Home Assistant, for monitoring and controlling it. I have no clue how to begin and can’t see the forest for the trees. Here are some of the trees I looked at:

Unfortunately none assume zero previous knowledge and I feel like a monkey looking into a rusty watch. Ideally I’d like to see how somebody before me invented that wheel and has it spinning around! A How To Connect for dummies if you want. An Elmer to help me understand what I need to learn. The last link above comes close but I prefer writing over video (I know, I know, I’m a boomer…)

My heatpump does not have an interface (yet) and I see there are several options. LG have an expensive WiFi solution that runs through their cloud. No thank you! MODBUS seems to be the solution for a local integration. It comes in several flavours, with RTU, TCP, RS-485, PoE which I have no clue what they are or how to tell them apart. What would be the best for me?

My Home Assistant runs on a laptop and I routinely always update to the latest version, currently that is Core 2026.9.2, Supervisor 2026.09.0, Operating System 18.2, and Frontend 20260826.7. I have a lot of devices on WiFi, Zigbee, and use Node-Red, a Home Wizard P1 dongle and very soon an AlphaEss home battery will be installed. I have some 34 solar panels (10 kWpeak) that will be connected directly. My wife want to buy an electric car so we’ll want to add a charger for that as well. Once I get all these devices into Home Assistant I’ll have to figure out an algorithm to make optimum use of solar power and minimise power intake from the mains supply.

One step at a time, the first will be to connect the heatpump to HA. Can you point me in the right direction?

Your HM163MR.U34 is a Therma V (R32 Monobloc S, 16 kW, 3-phase) — so every Therma V guide you found applies to it.

RTU is the protocol, RS-485 is the wire it runs on, TCP is the same protocol over Ethernet (your pump doesn’t speak it), PoE is unrelated.

You don’t need to buy an interface. Modbus RTU is already on the pump’s board — a connector marked “3rd party controller”, terminals A and B. PI485 and PMBUSB00A are for LG’s own bus, not this.

To enable: power off, SW1-1 → ON. A “Modbus Address” item then appears in the installer menu on the wired remote. 9600 8N1. SW1-2 differs by series — try ON, then OFF.

Master side, pick one:

RS-485→Ethernet gateway (Elfin EW11, Waveshare) + HA’s Modbus integration. Fastest, but dies with the laptop.
DIN-rail controller as the master, talking to HA over the ESPHome API — keeps running when HA is down. We make one (HomeMaster MicroPLC); applies to any ESPHome master.

Registers: GitHub - basti242/homeassistant_lg_therma_v_modbus · GitHub — already mapped, with photos of the connector.

Gotchas: subtract 1 from LG’s register numbers; some manual revisions swap holding and input; if nothing answers, swap A and B; energy registers only on units built from ~Dec 2023.

Wiring: shielded twisted pair, COM to every node, 120 Ω at both ends only, away from mains.

On the solar algorithm you mention at the end — I wrote up one approach here, might be useful when you get to it: EV Solar Charging Without Calculating Solar Surplus — A Closed-Loop PID Approach Using Your Battery

Thanks Dmitry, at least you seem to understand what I need. However, I get the idea you wear seven-legue boots and I’m not up to speed. You say I don’t need an interface but then you give me a choice for the master side. (btw that’s what I was referring to as “interface”, some device to enable data exchange between the heat pump and HA). That’s right where you loose me. I’m not sure what the pro’s and con’s are. ‘dies with the laptop’ is that my HA machine? What is the point of having a running interface without HA? What is an ESPHome master? The rest of your info doesn’t make any sense to me yet. As I said, assume I have zero relevant knowledge. Can you translate? Thanks for your help and understanding!

What I meant: the logic should live in a small ESP32 board, not in Home Assistant. The board talks to the heat pump over two wires and decides things by itself. The laptop only shows you the numbers and lets you change settings — if it’s off, the heating carries on as normal.

That’s all “master” and “dies with the laptop” meant.

Board: M5Stack Atom Lite + ATOMIC RS485 Base (~€20), or LilyGO T-CAN485 (~€20). It runs ESPHome — free, flashed from a short config file.

Two wires plus common to the 3rd-party-controller terminals, turn Modbus on in the installer menu, load the ready Therma V config from the repo we linked. It appears in HA with the sensors named. Read-only for a week, then let it write.

Just a little update. I chose the Waveshare gateway and got it running. I used the homeassistant_lg_therma_v_modbus/modbus_lg_heatpump.yaml at 9d706123560525c8820cc53a0111f7cf790ab5ea · basti242/homeassistant_lg_therma_v_modbus · GitHub and found some errors in the units, like l/min where HA needs L/min and Bar vs bar. I now have the modbus integration showing 58 entities.

Next step is to create a nice UI in Overview, monitor the heatpump and start thinking on how to optimise it using my solar power. Thanks for your help so far!