I’m trying to remotely view data from my system (3x Quattros, 6x MPPT, cerbogx, multiple battery controllers) and want to see power in and out of the quattros in as real-time as possible (Ideally not less that 4x per second). As I currently understand it, my options are as follows:
CerboGX:
Modbus: can poll as often as I want, but maybe that will put too much strain on the already heavily loaded system. 5 second default interval is too slow.
MQTT: Seems to trigger on state change, but seems like I don’t see anything faster than 1x per second
VE.Can: I assume I could tap into VE.Can and pull out the messages I want, but I don’t know the polling frequency, and I would be limited to the devices reporting on the CanBus. I assume this would be the fastest method, since data rate is much higher.
Bottom-line question is: What is the fastest polling method I can use with a CerboGX? Key values is the positive/negative current flowing through the Quattros (Which only have VE.Bus).
Some tests indicate that opening up dbus over tcp (in order to pipe data to Node Red on an external device) results in the same update frequency as mqtt, no faster than once per second.
For sure the VE.Can method is the one that will give you the fastest answers, but you must also take into account the speed of reading/sampling those values inside the device’s firmware.
So, no matter if you poll with 4Hz if internally the sampling is performed at 1Hz. You’ll get chunks of 4 consecutive identical values, even if the value is changing faster than that.
As the processing power of a microcontroller is a finite quantity, you must also take into account the overhead needed for answering to your polls.
I.E. the “questioning” may be very light on the CPU for the inquiring system at, let’s say, 5Hz, but take into account that the Quattro’s microcontroller must answer to your requests and this, at higher questioning speeds, may be very well a big overhead.
I’ve tested on my system (a Multi RS) and even at 10Hz polling rate, all seems to be OK and the results are consistent with a much higher internal sampling. Meaning, even at 10 times per second, I can get three consecutive answers with three different values.