question

prynhart1 avatar image
prynhart1 asked

Concurrent Connections to the GX Remote Console ?

We've got a CCGX, but the device is out in the garage, and I was wanting to setup a permanent (and stable) mirror of the GX GUI inside the house (one that doesn't also disconnect if there's an inbound connection to view the GX remote console on Port 80).

Having got root access to the device, I can see that there's this process that mirrors the GUI to a VNC server process:

/opt/victronenergy/gui/gui LinuxFb:VNC:size=480x272:depth=32 ...

Although the VNC Server process only listens on loopback, I was able to workaround this (for testing purposes) via an SSH port forward, and then connect (and see) the console via a VNC client:
gx-vnc.png

The problem is that if there is any inbound request to the GX device on Port 80 then the VNC client will disconnect (and vice versa) - i.e. even with this approach there seems to be only one concurrent connection to the GUI allowed.

Does anyone have any suggestions as to how I could achieve what I'm wanting to do ?

With Thanks in Advance

Patrick

[Aside: I'm aware that there's the VRM Portal - but unfortunately that isn't realtime enough. We're wanting to be able to plugin our car, or turn on the kettle etc and see the result, and the local GX GUI seems perfect for this.]

Venus OSCCGX Color Control
gx-vnc.png (86.2 KiB)
2 |3000

Up to 8 attachments (including images) can be used with a maximum of 190.8 MiB each and 286.6 MiB total.

4 Answers
Kevin Windrem avatar image
Kevin Windrem answered ·

Only one connection at a time is allowed


1 comment
2 |3000

Up to 8 attachments (including images) can be used with a maximum of 190.8 MiB each and 286.6 MiB total.

prynhart1 avatar image prynhart1 commented ·
The Kevin - having an awful time with this editor. It would seem that you are not allowed to write the word "l.o.c.a.l.h.o.s.t" without it being content blocked by nginx


I had to use a divide and conqueror approach to workout why it was not allowing submission.

Anyway - if you could please have a read of my full question (now that I've managed to get it uploaded) that would be great.

0 Likes 0 ·
JohnC avatar image
JohnC answered ·

Hi @prynhart1

If you can live without the moving dotted lines, try the Marine MFD app. Type "venus.local/app/" in a browser.

It might bob as a weird size, but you can Zoom to suit, even to multiple pages. The normal gui (Remote Console) is selectable from it, so if that got pushed off, just one button to return to the MFD.

1 comment
2 |3000

Up to 8 attachments (including images) can be used with a maximum of 190.8 MiB each and 286.6 MiB total.

patrick-rynhart avatar image patrick-rynhart commented ·

Thanks @JohnC, that's really helpful. I didn't know about that App - but it does allow 'side-by-side' info. It doesn't seem to split out "AC Loads" and "Critical Loads" as per the GX screenshot, but it's much better than an "it's not possible" answer. The fancy lines aren't important either :)

As an aside, today I've been looking at MQTT, and I've managed to subscribe to topics which map to the above GX values. At this stage, I'm thinking of maybe building a small 16x4 LCD display (via a Rasp Pi or similar) to get the data that I want elsewhere in the house.

Thanks for the help from a new user

Patrick

0 Likes 0 ·
nickdb avatar image
nickdb answered ·

Why not create a node-red dashboard of your own? iirc that is accessible from multiple devices.

5 comments
2 |3000

Up to 8 attachments (including images) can be used with a maximum of 190.8 MiB each and 286.6 MiB total.

patrick-rynhart avatar image patrick-rynhart commented ·

Yeah I'm heading down this path. Experimenting with paho.mqtt.client on Python3 and getting some promising results. Still, if they (Victron) did have a "read only" VNC console (that you could connect to simultaneously from multiple devices on the LAN) that would be a nice touch IMHO. The built-in Victron GUI / console is quite nice.

0 Likes 0 ·
nickdb avatar image nickdb ♦♦ patrick-rynhart commented ·

Just an observation on vrm realtime mode, mine responds within a couple of seconds, which seems fit for most purposes. It may vary with internet access, but it is a reasonable substitute.

0 Likes 0 ·
patrick-rynhart avatar image patrick-rynhart nickdb ♦♦ commented ·
Interesting - I'm brand new to the whole Victron ecosystem (our system just went live). Didn't know that there was a VRM realtime mode. The current VRM dashboard that I have access to seems to only refresh / supply updates every few minutes or so. I guess I need to read the docs.... (Always a learning curve with a new platform.)
0 Likes 0 ·
Show more comments
JohnC avatar image JohnC ♦ commented ·
As I understand it, Node Red won't work on a CCGX.
0 Likes 0 ·
zonnigbreda avatar image
zonnigbreda answered ·

Was trying for the same... What was working for me is to start a 2nd vnc screen (the 1 at the end of the first line, instead of 0 for the regular vnc screen).

Then ensure this can be reached from outside the device (so I don't need to tunnel via ssh)

It did not seem to interfere with the regular vnc screen.


You need ssh access to your device. On the commandline execute:

root@cerbo:~# /opt/victronenergy/gui/gui -nomouse -display VNC:size=480x272:depth=32:passwordFile=/data/conf/vncpassword.txt:1 &
root@cerbo:~#sysctl -w net.ipv4.conf.all.route_localnet=1
root@cerbo:~# iptables -t nat -I PREROUTING -p tcp --dport 5901 -j DNAT --to 127.0.0.1:5901
2 |3000

Up to 8 attachments (including images) can be used with a maximum of 190.8 MiB each and 286.6 MiB total.