Why make a new Victron integration for Home Assistant?
There are already a few integrations for monitoring Victron devices from Home Assistant and they each rely on different interfaces and have different capabilities.
Until recently, I used a Victron VE.Bus Smart Dongle to monitor my Victron Multiplus II over Bluetooth LE and I controlled the device state using an optocoupler wired to the remote on/off terminal. It worked well but I could only switch the device on or off and I wanted to programmatically switch it between on and charger-only instead.
It turns out the Victron MK3 USB interface can set the operating mode and current limit programmatically, thereby achieving my goal of toggling charger-only mode. It also exposes a little more detail about the device’s behavior such as the AC input and output voltages and frequency which is nice. I’m not aware of any existing Home Assistant integrations for the Victron MK3 USB interface so I just wrote one.
I hope you find this new integration useful and I welcome your feedback!
Jeff.
It looks interesting. I have a few questions about whether it can be used in my use case and whether I can avoid having a GX in the system, as Multiplus II will be the only Victron device in the system.
I want it to run in the following modes:
UPS / Charger (with control of charging from the HA side as it has information about SOC)
Standalone inverter - for light load use conditions
Power assist mode with separate off-grid inverter as “generator” - for higher loads
Use the MK3 dongle with the Victron Connect app on your computer to configure the Multiplus II basic operating parameters such as battery chemistry and power assist behavior.
Then plug it into your home assistant box to read data from sensors and to set the operating mode to on / off / charger_only / inverter_only with automations depending on your needs.
Hi,
I have the following questions (since I am completely new to all of this)
I have the MK3 USB dongle. I have home assistant as Vmware in a Windows environment, and so far works flawlessly.
I have reconnected the MK3 and assigned it to the Vmware.
What happens next? I havent seen anything in the discrovered devices.
How do I make home assistant see the MK3 USB?
Thank you in advance for any assistance.
Have you installed the Victron MK3 integration using HACS and restarted Home Assistant?
If so, ensure that the MK3 is plugged into one of your inverter’s VE.Bus ports and that the inverter has power since the MK3 powers itself from VE.Bus.
If so, and the MK3 is still not being discovered, navigate to System → Hardware and click on All Hardware. Search for a USB serial device corresponding to the MK3 dongle. Mine is at /dev/serial/by-id/usb-VictronEnergy_MK3-USB_Interface_HQ2217T743W-if00-port0
If you find the MK3 device and it still isn’t discovered, then please send me the list of attributes (in case my integration isn’t matching them correctly).
If you don’t find the MK3 device, then perhaps check how you mapped it through VMware or examine the kernel logs for further clues.
Hi Jeff, I currently have the Victron MK3 USB integration working in a Supervised Home Assistant setup. However, I read recently that this Supervised HA is being deprecated.
If I switch to Home Assistant OS (HAOS) running on the same hardware, will the MK3 USB interface still be supported and work properly? and the python scripts?
Great!!! thank you! Perhaps another question There’s one more piece to my puzzle in addition to the RPI being connected via USB to the inverter, my setup is at my cottage and I run on the RPI a reverse SSH tunnel back home so I can access this device via ssh and HA web (long story - ISP is doing double NAT), so AFAIK on HAOS this is not something I can setup (crontab and autossh) to enable this connectivity.
Let’s try to stay on topic for the victron-mk3 integration.
That said, I suggest that you take a look at some of the Home Assistant add-ons for remote connectivity. I use Cloudflared to set up a remote proxy. There’s also TailScale, ZeroTier, and Wireguard which can set up a VPN.
Also, Nabu Casa offers Home Assistant Cloud for remote access and helps fund development of Home Assistant (which I think is well worth the investment).
Hi,
My victron inverter and HA machine are not close to each other. Are you aware of options that could be used such as ethernet to USB converters. Or connection via a esp device
USB 1.1 can go about 5 meters (16 feet) so you can try a longer USB cable between the MK3 and your computer.
Alternatively, VE.Bus uses a standard 8P8C twisted pair (“ethernet”) cable. I don’t know what its maximum length is but I suspect it’s somewhat far. So you can try a longer “ethernet” cable between the MK3 and your inverter.
Alternatively alternatively, the VE.Bus Bluetooth adapter works well and is supported by a Home Assistant integration and an ESPHome component although they can only read data and cannot set the inverter state.
I suspect it would be possible to port the victron-mk3 integration to ESPHome or run the library standalone on a little Raspberry Pi Zero but it’s not something I feel like doing myself. Feel free to have a go at it.
Hi I am also new to all these.
I have home assistant installed on a Synology Vmware. I have connected the MK3 and passthrough it to the VMWARE. I am trying however to understant how to install HACS. what is it? If it is an ADD on from the store I can’t find it.
Can someone help?
HACS is a custom integration for Home Assistant that helps you find and install custom integrations made by other people. It’s very useful: https://www.hacs.xyz/