Fronius inverter integration

Also note that (maybe only if you have a load-controller), this provides consumption data:

http://ip-of-inverter/solar_api/v1/GetPowerFlowRealtimeData.fcgi

as value_json.Body.Data.Site.P_Load

as per http://www3.fronius.com/cps/rde/xbcr/SID-ACEDAD0F-36E36A58/fronius_international/42_0410_2012_318486_snapshot.pdf

Maybe wrong place to ask, but what’s up with “Fronius symo component”


“status” is “closed” ? is it integrated already or not ? that can be gamechanger as I’m also with Fronius Symo here.

where is the return JSON file stored ?

I have no clue, but you can see the data returned as attributes of the rest sensor you applied the address to

fixed it , removed the .value after the P_Grid
now looks like …

platform: rest
resource: http://10.0.0.106/solar_api/v1/GetPowerFlowRealtimeData.fcgi
name: “Grid power”
value_template: ‘{{ value_json.Body.Data.Site.P_Grid }}’
unit_of_measurement: “W”
scan_interval: 100

There is a better version based on pyfronius of this author. I think it is not integrated yet in HA, but you can install the component in your custom components. And that should work. I will try out soon myself.

Did you try it out? I installed pyfronius & put the file in custom_components but Im not sure how to configure it. Thanks

After you have this you should add the component to yor sensors

- platform: fronius
  host: xxx.xxx.xxx.xxx    # ip address of your inverter
  type: inverter
  device: 1
  scope: device

Than there should be a sensor available called sensor.fronius_inverter_192xxxxxxxxx_1 Where the number (192xxxxxxxxx) is the IP address of the inverter without dots.Using templates you should then be able to access all the data from the inverter.

- platform: template
  sensors:
    electricity_inverter1_power_netto:
      unit_of_measurement: 'W'
      value_template: >-
        {% if states.sensor.fronius_inverter_192178XXXXXX_1.attributes.power_ac is defined %}
          {{ states.sensor.fronius_inverter_192178XXXXXX_1.attributes.power_ac | float | round(2) }}
        {% else %}
          0
        {% endif %}

Somehow this does not work for me anymore, but it is supposed to work like that.

1 Like

Thanks for that. Doesn’t work for me either.

I guess the API will have to do for now

Any one have is working on there system. An any bad report, will anyone will reopen the project on GitHub

Here are sensors I use from Fronius:

1 Like

I used the “rest” sensor component to get the data, but because the inverter switches off during night time the sensor kept on giving me errors. So I created a Nodered flow that request the data from the inverter and sends it via MQTT to Home Assistant.

Copy the text in the fronius Node red Flow file and in node red select, Import - Clipboard - and paste the text in the screen - Import

MQTT Sensor.yaml (161 Bytes)

Fronius Node Red Flow.yaml (5.4 KB)

I tried to copy your flow but the link does not work. I will get my fronius soon. Does it always switch off during night?

Hi, think is is to save power. I will include the node red flow in this email. Remember to change your ip address.

[{“id”:“9593ad35.c187”,“type”:“debug”,“z”:“5948f6d6.2e0478”,“name”:“AC Power (W)”,“active”:false,“tosidebar”:true,“console”:false,“tostatus”:true,“complete”:“payload.Body.Data.PAC.Value”,“x”:850,“y”:300,“wires”:[]},{“id”:“5dfa164.58095e8”,“type”:“inject”,“z”:“5948f6d6.2e0478”,“name”:“10s Ping”,“topic”:"",“payload”:"",“payloadType”:“date”,“repeat”:“10”,“crontab”:"",“once”:false,“onceDelay”:0.1,“x”:110,“y”:150,“wires”:[[“37ae92a9.d7d7de”]]},{“id”:“7ac6d5d5.9a5c6c”,“type”:“http request”,“z”:“5948f6d6.2e0478”,“name”:“Fronius”,“method”:“GET”,“ret”:“txt”,“url”:“http://192.168.0.11/solar_api/v1/GetInverterRealtimeData.cgi?Scope=Device&DeviceId=1&DataCollection=CommonInverterData",“tls”:"",“x”:505,“y”:151,“wires”:[[“a9cfbdae.041d5”]]},{“id”:“a9cfbdae.041d5”,“type”:“json”,“z”:“5948f6d6.2e0478”,“name”:"",“property”:“payload”,“action”:"",“pretty”:true,“x”:651,“y”:149,“wires”:[[“bd52e4dc.fa7728”,“9593ad35.c187”,“c41d832.acd468”,“e19ca8a1.3dfcd8”,“7f4bc525.ae3afc”,“6861e9ee.053448”,“fc1983d6.6b2fa”,“709c31ca.5787b”,“2e949744.f43168”,“d06d091c.fa9428”,“a89e54a4.f47088”]]},{“id”:“bd52e4dc.fa7728”,“type”:"mqtt out”,“z”:“5948f6d6.2e0478”,“name”:"",“topic”:“tele/fronius/STATE”,“qos”:“0”,“retain”:“false”,“broker”:“63c06b21.e27344”,“x”:850,“y”:150,“wires”:[]},{“id”:“c41d832.acd468”,“type”:“debug”,“z”:“5948f6d6.2e0478”,“name”:“Day Energy (W)”,“active”:false,“tosidebar”:true,“console”:false,“tostatus”:true,“complete”:“payload.Body.Data.DAY_ENERGY.Value”,“x”:850,“y”:350,“wires”:[]},{“id”:“e19ca8a1.3dfcd8”,“type”:“debug”,“z”:“5948f6d6.2e0478”,“name”:“Error code”,“active”:false,“tosidebar”:true,“console”:false,“tostatus”:true,“complete”:“payload.Body.Data.DeviceStatus.ErrorCode”,“x”:840,“y”:200,“wires”:[]},{“id”:“7f4bc525.ae3afc”,“type”:“debug”,“z”:“5948f6d6.2e0478”,“name”:“Freqency (Hz)”,“active”:false,“tosidebar”:true,“console”:false,“tostatus”:true,“complete”:“payload.Body.Data.FAC.Value”,“x”:850,“y”:400,“wires”:[]},{“id”:“6861e9ee.053448”,“type”:“debug”,“z”:“5948f6d6.2e0478”,“name”:“AC Current (I)”,“active”:false,“tosidebar”:true,“console”:false,“tostatus”:true,“complete”:“payload.Body.Data.IAC.Value”,“x”:850,“y”:450,“wires”:[]},{“id”:“fc1983d6.6b2fa”,“type”:“debug”,“z”:“5948f6d6.2e0478”,“name”:“DC Current (I)”,“active”:false,“tosidebar”:true,“console”:false,“tostatus”:true,“complete”:“payload.Body.Data.IDC.Value”,“x”:850,“y”:500,“wires”:[]},{“id”:“709c31ca.5787b”,“type”:“debug”,“z”:“5948f6d6.2e0478”,“name”:“AC Volt (V)”,“active”:false,“tosidebar”:true,“console”:false,“tostatus”:true,“complete”:“payload.Body.Data.UAC.Value”,“x”:840,“y”:550,“wires”:[]},{“id”:“2e949744.f43168”,“type”:“debug”,“z”:“5948f6d6.2e0478”,“name”:“DC Volt (V)”,“active”:false,“tosidebar”:true,“console”:false,“tostatus”:true,“complete”:“payload.Body.Data.UDC.Value”,“x”:840,“y”:600,“wires”:[]},{“id”:“d06d091c.fa9428”,“type”:“debug”,“z”:“5948f6d6.2e0478”,“name”:“Total Power (W)”,“active”:false,“tosidebar”:true,“console”:false,“tostatus”:true,“complete”:“payload.Body.Data.TOTAL_ENERGY.Value”,“x”:850,“y”:650,“wires”:[]},{“id”:“2abda7a9.5dcfc8”,“type”:“comment”,“z”:“5948f6d6.2e0478”,“name”:“Status codes”,“info”:“0-6 Startup \n7 Running \n8 Standby \n9 Bootloadingd \n10 Error “,“x”:1040,“y”:250,“wires”:[]},{“id”:“a89e54a4.f47088”,“type”:“debug”,“z”:“5948f6d6.2e0478”,“name”:“Status code”,“active”:false,“tosidebar”:true,“console”:false,“tostatus”:true,“complete”:“payload.Body.Data.DeviceStatus.StatusCode”,“x”:840,“y”:250,“wires”:[]},{“id”:“cbb73493.5d5608”,“type”:“comment”,“z”:“5948f6d6.2e0478”,“name”:“Error Code”,“info”:“0 OKAY Request successfully finished, Data are valid \n1 NotImplemented The request or a part of the request is not implemented yet \n2 Uninitialized Instance of APIRequest created, but not yet configured \n3 Initialized Request is configured and ready to be sent \n4 Running R equest is currently being processed (waiting for response) \n5 Timeout Response was not received within desired time \n6 Argument Error Invalid arguments/combination of arguments or missing arguments \n7 LNRequestError Something went wrong during sending/receiving of LN-message \n8 LNRequestTimeout LN-request timed out \n9 LNParseError Something went wrong during parsing of successfully received LN-message \n10 ConfigIOError Something went wrong while reading settings from local config \n11 NotSupported The operation/feature or whatever is not supported \n12 DeviceNotAvailable The device is not available \n255 UnknownError undefined runtime error”,“x”:1030,“y”:200,“wires”:[]},{“id”:“37ae92a9.d7d7de”,“type”:“time-range-switch”,“z”:“5948f6d6.2e0478”,“name”:“sunrise/sunset”,“lat”:”-32.3469794”,“lon”:“115.8009645”,“startTime”:“sunrise”,“endTime”:“sunset”,“startOffset”:0,“endOffset”:0,“x”:310,“y”:150,“wires”:[[“7ac6d5d5.9a5c6c”],[]]},{“id”:“63c06b21.e27344”,“type”:“mqtt-broker”,“z”:"",“name”:“Mqtt Broker”,“broker”:“192.168.0.2”,“port”:“1883”,“clientid”:"",“usetls”:false,“compatmode”:true,“keepalive”:“60”,“cleansession”:true,“birthTopic”:"",“birthQos”:“0”,“birthPayload”:"",“closeTopic”:"",“closeQos”:“0”,“closePayload”:"",“willTopic”:"",“willQos”:“0”,“willPayload”:""}]

Hi Guys,

I’m looking at including this data into HA but think i need a database setup first so not the waste space and cpu on my hassio machine.

For those whos inverter stops reporting at sunset you can enable it to stay on via the inverters settings. Username is admin and the password was set up to be my wifi one at time of install.

Then under the Fronius solar.web tab select yes for logging during night hours. I have a smart meter put in to track power usage of the house so i needed to enable this to get night time statistics.

Hi @paul2nz, and thank you for your contribution!
In order to make it work, though, I had to make 2 changes (Hass.io 0.91.1):

  • The URL of the second link is broken (lacks a “o” in “community”)
  • The string “value_json” in MQTT Sensor has to ba changed in “json_value”

Hope this helps others!

Hi,

This looks good as I use Node Red for my HA.

I am just getting some solar quotes and am looking at Fronius. Is the Smart Meter required for your node to work?

Thanks
Nick

I have made some posts and have used Fronius in Home Assistant. I think that there will be a component very soon as well for Fronius.

The posts is sometimes in swedish but google translate should do the job.

http://www.planet4.se/solceller-del-3-grafana-home-assistant-och-magic-mirror/

looks good

I have a Fronius inverter being installed in a couple of weeks so I really hope that a HA component is released soon. It will make the integration very neat and tidy