Writing data to modbus over tcp

As documented here: How to connect to Nibe heat pump without the cloud I’m running a Nibe heat pump, water tank and control unit. The whole thing shares quite a lot of data which is available via modbus/tcp. I’ve pretty much figured out how to read all the useful registers and display in HA. Now I’d like to be able to set a few registers (e.g. modbus in rw mode) but am struggling to find any examples of modbus configurations which can enable setting of registers. Anyone have an example they’re willing to share? And ideas about which lovelace cards are best for this?

The documentation for modbus has examples of how to configure things like modbus switches. If the standard entity classes do not work for you for some reason, modbus also provides some services for writing coils and registers. You can play with them using developer tools or use them in your automations and scripts.
Open your Home Assistant instance and show your service developer tools.

1 Like

Ah, I see what you mean. That was super easy. Had been wrongly assuming I needed to change modbus settings for the sensor. Changes in dev tools works!

Hi Kidwellj,

Were you able to write to your Nibe? Which pump do you have and which registers did you write to?