Modifying gui-v2

Hi all,

with 3.50, gui-v2 seems to be the new direction. I’ve seen the old discussions about how to modify the GUI, but it’s not conclusive what in the end the chosen solution really is and how to make it happen.
Specifically, this is about GitHub - kcbam/dbus-huaweisun2000-pvinverter: dbus driver for victron cerbo gx / venus os for huawei sun 2000 inverter - we’re adding menus to configure the PV inverter for gathering the data. I’d like to replicate this into gui-v2, but I’m lacking a starting point on how to do it the right way.

Thanks a lot, Klaus

1 Like

i think more ways will come with time.

I’d be happy with one documented way… :sweat_smile:

As far as I can tell, there is no change to how you do this in gui-v2 from the original gui, since you don’t need to change the GUI to provide menus for user settings. This is all part of the dbus api. If you define attributes as settings when you register the device on the dbus they will appear as user settable attributes on the device’s setup menu.

If don’t have an example to hand but this is the setup menu on a temperature sensor.

and

This is unfortunately not the case. Your example is based upon the file /opt/victronenergy/gui/qml/PageTemperatureSensor.qml in the V1 GUI and works for the temperature devices. Any other special devices that are not already covered by the GUI need to adapt the GUI, see the install.sh script in the github repo linked above for an example. The question is basically: what is the correct way to do this in the GUI-V2. There was a discussion about it in the old community and I’d love to continue this discussion, but that’s not possible: Venus OS: modifying gui-v2 - VictronEnergy

Hey all, yes, we’re also keen to restart that discussion; and get to work on it.

In brief:

gui-v2 is 100% open source, which btw is a good step forward compared to gui-v1. Modding it is possible, but then to see your changes also via VRM you need to build your modded version from source; including the wasm version, and install that onto your GX. There is working infrastructure in place to then upload/access that over VRM. For details see here: GitHub - victronenergy/gui-v2.

While possible, building gui-v2 is not easy, and for sure more complex than logging into the GX device and modding a few QML files as was done by many on gui-v1.

And that is where we are considering to make better options; for example a JSON or similar structure to allow adding more menu’s.

4 Likes