victronenergy / venus

Victron Energy Unix/Linux OS
https://github.com/victronenergy/venus/wiki
577 stars 72 forks source link

Change venus-platform handling of the reboot path so that a (MQTT-) sender gets an ack #1256

Closed mpvader closed 3 months ago

mpvader commented 5 months ago

for various paths, after sending a value to the W/.../ path on MQTT, the sender also received a publish back on the /N or /R path. But for reboot it doesn't.

@jhofstee is this something not too difficult to do?

Background: the VRM team has been making a reboot button, was a very small change and prompted by the locking gui-v1 issue. And even though gui-v1 no longer locks up, I'd still like the reboot button; but then preferably such that VRM can tell the user that the GX device actually received the message.

Just some 2 seconds delay before initiating the reboot would be good enough afaik. Then VRM will:

  1. user presses the button
  2. vrm shows that button was pressed
  3. vrm waits for return ack (by listening to /N or /R topic) with timeout of 4 seconds.
  4. if it receives the ack, it will tell user command was received and reboots.
  5. if it doesn't, which will be only small percentage of cases, show a more "confusing" message.. :).

and then most likely we'll also be able to improve this a bit in gui-v2?

if for some reason this is all complicated, then never mind!

mpvader commented 3 months ago

small thing to fix? can you do that soon so its in v3.40?

Even for official releases I get complaints that gui-v1 gets stuck now and then - and by having above we can make a good working button in VRM.

mpvader commented 3 months ago

closing, followup work is in an issue for vrm.