PV Inverter/Battery Integration

362 views
Skip to first unread message

Daniel Feist

unread,
Jun 10, 2020, 5:05:14 PM6/10/20
to Loxone English
Hi,

Does anyone have experience integrating with PV inverters and battery systems?

Data I'm interested in::
- PV production information.
- Battery charge status.
- Car charge status

Control I'm interested in:
- Ability to control when the battery starts stops charging and discharging.
- Ability to control when the car starts stops charging and discharging.

Use cases:
- Charge battery when the tariff is cheap.
- Turn on ASHP, if i) UVC is under a certain temperature ii) battery has > x % charge iii) PV is generating > kW.
- Charge battery overnight to z % based on sunlight forecast for the next day.
- etc.

Currently planned hardware is:
1) Solaredge inverter
2) Tesla Powerwall

But I can look at other products is there are issues integrating with these.

Has anyone already got this kind of integration already set up?

Thanks,

SteveJ

unread,
Jun 10, 2020, 6:02:42 PM6/10/20
to Loxone English
I have a SolarEdge Inverter, from which I'm reading generation data into Loxone.   I failed to get this to work properly using Loxone's built in Modbus over HTTP because I couldn't find a way to get Loxone to read both the current power being generated and the multiplier used to scale the result into W / KW etc at the same time, so it produced random spikes in reported value at times when the multiplier changed on one read cycle, but the value didn't get updated to match the new multiplier (ie 100W suddenly became 1KW for one read cycle).  I suspect there is a way to build the integration logic in Loxone to account for this, but after a few days trying I gave up and I now use a perl script running on a Linux server to read the Modbus values from the Inverter and send these to Loxone using HTTP virtual inputs.  On the face of it this setup would seem to have more things that could go wrong, but I have it running for a year and its not fallen over yet :)   The value of total generated power reported by the inverter is drifting slowly away from the discrete generation meter installed next to it, but the installers choose to use a meter with only a flashing LED as a potential integration point (ie no electrical pulse output or Modbus) and I haven't got round to getting an opto sensor hooked up to it yet so for now the Inverters reported generation stats have to suffice.

No experience with batteries yet, but I am using Loxone to direct spare power to heating hotwater immersion heater via a SSR, this works reasonably well, but its proving tricky to build config in loxone to react quickly and cut the pwoer to the immersion when the available spare power drops due to a cloud going over or someone boiling the  kettle.

HTH
Steve

Daniel Feist

unread,
Jun 10, 2020, 6:33:37 PM6/10/20
to Loxone English
Steve,

That's helpful yes.  Isn't there any way to integrate with Solaredge via HTTP, or would this require going out to the internet + authentication?  Be interesting to understand if others have got the Modbus interface working with Solaredge.

I could use a standard PV diverter, but given we'll have an efficient ASHP, I was thinking I could do better by the triggering ASHP based on multiple factors.  I know PV fluctuates too much to drive ASHP directly, but if there is a battery with charge.. this will act as a buffer.

That a good point on cutting diversion quickly enough, I guess that's why a lot of people use a hardware product for that.  With a battery, this problem goes away though I assume, as that would cover the gap and avoid unnecessary import in most cases.  Good enough excuse to get a battery?

Thanks,

SteveJ

unread,
Jun 11, 2020, 2:21:06 AM6/11/20
to Loxone English
 As far as I know, the inverter itself does not have an HTTP interface (in fact the model I have doesn't even have a web interface for config - its all done via the LCD screen). 

The only way I know of to get the stats out via HTTP is to use the solaredge monitor API in the cloud.  This does work, and seems reliable, but in my experience its far from real time as the inverter is only reporting stats upto the cloud every couple of mins.  Also i'm trying to keep away from anything that needs an active internet connection to keep working, i'd rather have everything running locally and I don't like to give away my data where I can avoid it [solaredge still have all my data in this case :(  ]. 

to avoid publishing my consumptionn data as swell as my generation, I didn't go with solaredge meters, I use one of these https://www.metermarket.co.uk/product/eastron-sdm230-modbus-mid-single-phase-100a-direct-connected-energy-meter to read the real time, via modbus extension into loxone, import/export power to enable me to detect when there is spare power available in the system.

Scrivs 78

unread,
Jun 11, 2020, 3:39:54 AM6/11/20
to Loxone English
Hi,

I have SolarEdge Inverter too which sends the data into the cloud and i use there app to look at information.  But for Loxone integratation i use the rebranded Eastron meter as like SteveJ from JW Smart Meters  https://www.jwsmartmeters.co.uk/product-category/din-rail-mounted-meters/ also for the same reasons, dont want to be reliant on data outside, plus for me its easier to configure rather than trying to get API's to work.
(Make sure you get MODBUS, not MBUS)


I have a Nissan leaf which i was trying to get the information from for battery, but never managed to get it to work unfortunately. I have another meter on order which will capture charge going in (or out if V2G), but obviously no way to get charge state using this method as you use the power to drive or charge off site.

House battery i think could work in the same way as the car, but you could prob use a calculation based on how much in and out to work out % full.  I havent got Tesla, so not sure how open their API's are.

Thanks

Andrew

Rob.no1

unread,
Jun 11, 2020, 6:09:15 AM6/11/20
to Loxone English
I too have a basic inverter with no outputs so in the end I just added a simple (about £10) pulsed meter to the inverter output and connected the pulse to an input on the miniserver (or extension) - this worked out a lot cheaper than the Modbus option and has been pretty accurate. I am not sure about the battery charging option as you would ideally want to vary the amount of power that was directed that way when the solar increases. I use an Immersun unit which monitors surplus power being generated and then redirects it various outputs (like the immersion heater or electric underfloor heating) - if you had a similar unit it would always try to charge when there was surplus power, but you could go via a loxone relay and choose to cut the supply if and when you wanted for that extra level of control. 

Kind Regards

Rob

Tico

unread,
Jun 11, 2020, 8:48:59 AM6/11/20
to Loxone English
As another option for solar/battery, Fronius is a well engineered system for 3rd party integration. I'm using Loxone for all aspects of battery charge control -

1. Battery charge management based on sunlight forecast,
2. Charge/Discharge mode management is available for all aspects of day/night time use,
3. Charge/Discharge rate management is available for all aspects of day/night time use,
4. All data exchange is on the home network and updated at 10 second intervals.

I've written a wiki for the Fronius Hybrid/Fronius Battery integration with Loxone. This may give some insight into what can be achieved.


On car charging, there's a thread here that integrates KEBA wallbox/Loxone (use Google Translate) -


And some other options with Loxone -


I would avoid the Tesla Powerwall if at all possible. The system is a closed shop for 3rd party integrators. Similarly with Solaredge. They don't have a great reputation for open API standards.

Cheers,

Tico

SteveJ

unread,
Jun 11, 2020, 10:36:07 AM6/11/20
to Loxone English
 Tico - I used your blog to help me get started with Modbus integration for my SolarEdge inverter - so thanks for that :)

I never managed to get the part about getting the current values and scaling factor to work properly, I kept getting spikes cuased by the current value changing before the scaling factor etc.  In your setup, what is generating the trigger for the analogue memories ?

Daniel Feist

unread,
Jun 11, 2020, 11:43:21 AM6/11/20
to Loxone English
> I would avoid the Tesla Powerwall if at all possible. The system is a closed shop for 3rd party integrators. Similarly with Solaredge. They don't have a great reputation for open API standards.  

Solaredge do have a Modbus interface though which should work, doesn't need to be a HTTP API.  Even if this doesn't work, I'm assuming you could still integrate with an electricity meter if you are just reading data.

The battery if more challenging though, as to control charge/discharge you need to interface with the battery directly.  There are some API's shared online, but hard to know if they are up-to-date and work on latest firmware.]

Thanks,

Hidde Beumer

unread,
Jun 12, 2020, 1:37:39 AM6/12/20
to Loxone English
I’ve for long thought to have all of this in loxone too. So for the PV I do have the fronius inverter, which works perfectly and integrates nicely on the local network.

For the car charging I plan to go with the zappi from myenergy. Does exactly what you want, although independent from loxone.

For battery I have no plan yet since it’s not cost effective in NL. I do however have the option to increase the temperature in our hot water tank using our heatpump. This will be triggered from loxone upon surplus energy during daytime.

Tico

unread,
Jun 12, 2020, 7:58:09 AM6/12/20
to Loxone English
@SteveJ - Regarding spikes in values -

With the SolarEdge Modbus values, you should be able to ingest them as a single 32bit value. ie. you won't have timing differences between the Scale factor and the base value. Both are read in one poll.

This link refers (post #3.2)

Reply all
Reply to author
Forward
0 new messages