Open jeanlucmongrain opened 3 months ago
There is no mechanism that reset Valid
to True
whenever the Victron is back online in mk2Ser
, this the reason metrics are never updated
The valid flag is set on the versionDecode
function call https://github.com/diebietse/invertergui/blob/master/mk2driver/mk2.go#L284. Then the latest info is sent in after we receive charge state here https://github.com/diebietse/invertergui/blob/master/mk2driver/mk2.go#L383
Do you see any debug logs that contain battery state decode
or versiondecode
?
I just rebuild from master
, added some extra debug logging and error logging.
And the value of .Valid
is always true going through a powercycle of the Victron. So it's not the reason.
I'm adding extra logging statements to figure
Do you see any debug logs that contain battery state decode or versiondecode?
yes actually
Do you see any debug logs that contain battery state decode or versiondecode?
just versiondecode
Without stateDecode
there will be no new info update sent to prometheus. I am unsure as to why you are not receiving charge state updates.
PR #45 improve things a bit, but I still don't get anymore commandReadRAMResponse
wimon frames once it's restarted
@ncthompson beside setTarget()
is there anything that need to be send to Victron to make it return winmon frames?
If invertergui starts while the victron is off and later turned on. the metrics are never digested.
and it will never get the winmon frame of startup if setTarget()
is never executed.
the only way to really handle that other case as well is looping and run setTarget()
until it works...
Victron is connected to a single-board computer through
/dev/ttyUSB0
. Invetergui is running from ARM64 Docker image.But everytime I turn off Victron for a while and turn it on. There is nore new metrics values published. But the metrics as still being ingested from the serial interface, as the debug logs show changes in values pulled from the Victron, example:
and later:
Among other values that are changed, the value of
BatVoltage
changed from26.84
to26.85
.but if I look at prometheus metrics the value is stuck at when I restarted Victron: