victronenergy / gui-v2

Other
25 stars 9 forks source link

Connected gensets UI changes #1220

Closed ReinvdZee closed 2 months ago

ReinvdZee commented 3 months ago

We've done quite some changes to the UI of connected gensets on gui-v1. See this doc. These changes should be implemented in Gui-v2 as well.

The new v1 UI looks like this: genset_new_ui

Manual start menu: Screenshot from 2024-06-10 14-16-02

The v2 UI currently is: image

Alarms dbus_generator now contains two seperate alarms for monitoring the auto start/stop mode of the GX and of the genset. Both alarms can be enabled/disabled with one switch (already present in Gui-v2): image The alarms are issued by dbus_generator and published by venus-platform. As was already discussed here no UI changes are necessary for the alarms to show up in Gui-v2.

Control Card The control card works properly as well: image

I can do a manual start and timed run and also enable/disable GX autostart from here. However, the state currently given in the manual start menu (embedded in autostart menu) can be out of sync with the state given in the card. But this is probably resolved if the UI changes are implemented. There are possibly some improvements to be made:

Other issues The genset we're testing with also exposes a tank sensor. On gui-v1, this is picked up correctly. Gui-v2 shows the sensor but it is "unknown": image On the tanks overview it is displayed properly: image

Tasks:

The menu is probably interleaved with the generator start/stop menu, be sure not to change the generator start/stop menu.

chriadam commented 3 months ago

This seems like a large number of UI changes / feature changes. There were other similarly large changes (like the acsystem one) recently, also. I am surprised that we are still receiving large feature changes at this point, considering the timeline. I would ask: is this truly necessary for 1.0.0?

blammit commented 3 months ago

See b9583fd7bee8f1120402ba4697693765c6f06f26 in gui-v1 for the main changes.

chriadam commented 3 months ago

Reopening issue. Per testing on Tuesday: 1) settings -> device list -> DSE genset controller, the text "Error" should read "Control error code" so as to be distinct from "Genset error code" which comes later in the list. 2) Genset device is not showing up on Overview page as an AC Input (nor as a gauge on Brief page). Simulation N.

ReinvdZee commented 3 months ago

Reported on slack: The generator manual start menu is not properly scaling. I reproduced this on a mobile phone. The controls work, but they do not scale evenly with the menu background.

image

chriadam commented 3 months ago

That latter issue (scaling of the dialog) is tracked separately by #1271

blammit commented 2 months ago

For reference, use this installation to test the "DSE genset controller".

blammit commented 2 months ago

Genset device is not showing up on Overview page as an AC Input (nor as a gauge on Brief page). Simulation N.

This is because com.victronenergy.system/Ac/ActiveIn/Source is not set to a valid value, and gui-v2 relies on this to determine the current active AC input. (Also, Ac/In/0/Connected and Ac/In/1/Connected are not set.)

Normally /Ac/ActiveIn/Source is set, so I think this is a bug in the simulation. @ReinvdZee could you confirm whether this is the case?

ReinvdZee commented 2 months ago

@blammit /Ac/ActiveIn/Source is only set when there is a multi with an active input. Simulation N is only a recording of the genset, not of the vebus service, so if you run this on a system with no further devices, /Ac/ActiveIn/Source will indeed not be set correctly.

You can use simulation O to test this. Simulation O also has a vebus system. I ran it and the generator widget showed up:

image

I would expect it to show up on the top-left instead of the bottom-left, though. But that may be a design choice.

We may not even need a genset service to test this. I set AC input 1 to "generator" on the lynx parallel test system and it shows up: image

blammit commented 2 months ago

Note: I am currently clarifying with Rein how we should identify the active AC input, as it seems that /Ac/ActiveIn is only set when there is a multi device (like vebus) present. If this is the case, then some work is required to rearrange how the active AC input is determined.

blammit commented 2 months ago

Clarified this with Rein. gui-v2 can use /Ac/ActiveIn/Source for now. I will close this as all issues are resolved.