starob wrote: @Michalux check if you have any strange readings around the inverter state transition around "Wait" to "Normal".
For me, when production starts, I have a registered power and production peak. It wasn't there before, maybe it has to do with the season and the weather.
You need to make extra data validation, which neither you nor I have.
The case is difficult because it is one shot and it is difficult to capture and it spoils the statistics.
In general, it is not a peak of power and production, but before the inverter goes into the Normal state, it briefly returns the last value from the previous day. In one of the last versions I added a protection not to send data to InfluxDB/Prometheus/MQTT when the status of the inverter is different than Normal (variable invstatus).
Data in JSON format is dumped on the console at each status (e.g. to see errors in case of emergency).
I also added a new script that reads all data regarding serial numbers, versions, etc/etc

(unfortunately, embracing it with the same script would require a lot of modifications, because the command no. 4 works a bit differently than no. 3).
I also introduced all the error statuses from the documentation so that the codes would be converted to names nicely.
Added after 7 [minutes]: mariopoz wrote: Hey! I've got a question.
How did you solve the "problem" of calling the InverterData.py script?
So far I managed to run it via crontab, but there I can usually set it every 1 minute.
I still have a problem with a plugin in Grafana, I can't find one like you used timeseries anywhere.
I'm on crontab. I don't really need to read more than once a minute.
But I don't see a problem to write a simple shell script that runs InverterData.py in an interval of min 1s (I don't recommend it, because the logger inverter may not work), e.g.
while true; do
python3 InverterData.py
sleep 1
done
You run the script in the background (./skrypt.sh &) and you're done. It can also be thrown into the crontab, so that it runs, for example, once every 10 minutes (then the loop must be limited so that it does not last > 10 minutes). This is in case the script dies/was killed (e.g. due to OS restart).
As for Grafana, it's a plugin available with Grafana (standard installation - I didn't add anything).
Maybe you have too old version of Grafana? I'm on 8.2.1 at the moment.
Added after 10 [minutes]: mariopoz wrote: Have you managed to solve this problem?
I have a similar message.
I don't use MQTT, so I didn't mess with the original code and didn't check it.
However, look in the forks of my project on GitHub - in one of them someone corrected this piece of code.
Added after 13 [minutes]: By the way (while I'm already producing

), then I found yet another version of the Sofar/MODBUS documentation. The ranges of registers for reading production data are not suitable for my inverter, but it is greatly extended in relation to the documentation that I found on the forum (but registers containing SN, versions, etc. are OK). It shows that it is also possible to manage the inverter in a similar way, including switching on/off, changing the configuration, etc. (generally writing support, not only reading).
I am attaching the document for those interested.