Scraping Delta SOLIVIA PV inverter data

@Robert,
That the values where highly inaccurate, I experienced also after I tried to include the scrape script, by your hand with the IP and name of my inverter. I thought it was because I inserted in the wrong config file. After I removed it, the wright values reappeared after several reboots of HA and the gateway. I just tried something, because I am not hindered, by any real knowledge of YAML or Python.

I ran this scraper setup for many years without problems, the issue with incorrect values being retrieved has only started recently (and I can see the values being incorrect on the webpage, so itā€™s not because of an incorrectly configured scraper).

I never used the Solivia portal so didnā€™t know it was discontinued, but it does sound like a likely cause of these issues.

My hardware solutions talks directly to the inverters, with the added bonus that it provides much more information than the gateway ever did in my case.

I donā€™t need that much data. Actually only those two values ā€‹ā€‹that I mentioned earlier and of which I think the actually generated energy of the PV installation is the most important, because it does not come via the P1 cable. HA uses the value that the smart meter indicates and that is after the current consumption has been deducted. That is of course also important if you think about tax payments. Consuming as much of the energy generated as possible yourself, is the most cost-effective option.
I still think your scrape script is the closest to a simple solution for me. If only I understood a little bit.
Q: You use 2 inverters, I only have 1. Does that affect that script? Or do you enter data for those inverters twice?
Q: Where exactly, so in which file should these lines be inserted in HA, or should I create a new file, with what name and where should it be located in HA?

The gateway has separate pages for each inverter, so I had configured two scrapers.

How to add scrapers is documented here: Scrape - Home Assistant

@Jeroen, Send me a.u.b.(please) that script, although I am an absolute beginner in scripting, I have to learn it and then I might also understand the clues that RobertKlep refers me to. A long way to go. So donā€™t hold your breath. I have some professional experience, but that mainly applies to Microsof. I still have some links to a Forum about the Delta, so if you are interested I can post them (if that is allowed here) I have been looking for a way to download the info from my inverter since installation (now 8 years), via that M1. I was so disappointed when I heard that it had to go through that Kwalitatief Uitermate Teleurstellende (Qualitatively Extremely Disappointing) portal. The web interface prevented me from having to go to the attic every day to read the final score of the day and gave me a kind of dashboard for the current yield.

Indeed, my script doesnā€™t scrape the web interface of the M1 gateway, it uses the M1 gateway as a serial device server (which is undocumented by Delta).
Iā€™ll put more details in reply to your more recent message.

Sure. I just created a shortened version of what I use myself, will send it as a PM.

If anyone has links to current Python projects that talk to Delta Solivia inverters via serial, please let me know, perhaps one is designed in a way that would make it easy to extend it with support to relay via the M1.

Feel free to share it here, Iā€™m always interested in undocumented stuff :wink:

@Jeroen The following links on Github, are not directly about the M1 but are relevant, I think
ā€¦com/bbinet/delta-rpi
ā€¦com/runesl/DeltaPVOutput
ā€¦com/lvzon/soliviamonitor#readme
ā€¦com/rwh86/delta-rpi

1 Like

All those projects basically use the same method as I am with ESPHome, reading the inverter data directly off the RS-485 bus.

The protocol is well documented, but the main issue is that there are dozens of Solivia inverter models, and about 10 different data formats. Most implementations only use a single data format (my implementation too).

Somewhere in This forum is a reversed engineerd ā€œDeltaSoliviaProtocolTest.exeā€ also needs a com port but perhaps useful ā€œā€¦forums.whirlpool.net.au/archive/1901079ā€
It is fairly old and long.

Iā€™ll send you a link in PM. Iā€™m not ready to share publicly; I made the script using documentation that I received under NDA, and even though I signed the NDA just over 10 years ago, I donā€™t see any expiration date on it. Iā€™ve tried to contact Delta several times, but never received a response.

1 Like

@JeroenvIS
Iam not that bright, What is PM and NDA.?
In 8 years I never received any response of emea-delta. About the new cloud solution i did, but when I asked, where to order the hardware for free, I did get an anserw but not very useable.

Sorry if I was unclear.

PM = Private Message - I tried to send you a direct (private) message through the forum, did you receive it? It contains a link to a slightly modified version of the script that I use.

NDA = Non-disclosure agreement. I had to sign a legally binding document with Delta to obtain the protocol details that I needed to communicate with the inverter through the M1 gateway. I went down that road because I was very disappointed with the cloud service after I had bought the gateway. The document restricts me from sharing the documentation that I received, but also from sharing work that I have done based on that documentation.

Back when I signed the NDA, I was in direct contact with a product manager within Delta. I know for a fact that he still works there, but my attempts to reach him in the last years have all failed.

My point of view is that Deltaā€™s business is not harmed in any way if I share some of my work to allow others to keep monitoring their Solivia inverters through an M1 gateway - but since Delta does not reply, I donā€™t know if they share that view :frowning:

@Jeroen, thanks first, but as I said, Iā€™ll have to learn ā€œPerlā€ first, as well as calling this script. No idea where to insert this; what the name and path should be.

@robertklep Still discovered where and why the example failed to make ā€œno valid configurationā€. Presumably due to a version difference. ā€œvalue_template: ā€˜{{ value|int }}ā€™ scan_interval: 30ā€ Were not implementable, especially with the ā€œscan_intervalā€ that is difficult, because HA=Srape scrapes default, every 10 minutes and that is, as far as Iā€™m concerned, way too slow. It hasnā€™t become clear to me exactly what to do with ā€œvalue|intā€. Donā€™t know the correct syntax. But as in your example, it gives an error message.
For the first time it works, it said with the aforementioned shortcomings, such as extraneous values and the necessary reboot of the gateway. I also have ā€œOpen IEā€, with which I can also see it. If I could prevent it from connecting to the deceased portal, this was all I need, some sort of quick and nasty solution. If I detect a regularity in the jamming of the M1 gateway, I just put a timer in between. If such a thing is not possible with HA. But for now, I go and concentrait on realy important things, as the exchange of window and door/frames, Inclusive triple glazing, by the estatecompagnie what is the comming weeks. Thanks all for the imput.
Whish You all happy holydays.