Fronius inverter JSON integration - Printable Version +- Logic Machine Forum (https://forum.logicmachine.net) +-- Forum: LogicMachine eco-system (https://forum.logicmachine.net/forumdisplay.php?fid=1) +--- Forum: Scripting (https://forum.logicmachine.net/forumdisplay.php?fid=8) +--- Thread: Fronius inverter JSON integration (/showthread.php?tid=2103) |
Fronius inverter JSON integration - tomasjancys - 31.05.2019 Hi, Does anybody have an implementation with Fronius inverter via JSON? BR Tomas RE: Fronius inverter JSON integration - Erwin van der Zwart - 01.06.2019 Hi, I have a script version, maybe this helps you with creating the JSON template.
Fronius Solar Inverter.lua (Size: 3.36 KB / Downloads: 238)
BR, Erwin RE: Fronius inverter JSON integration - Habib - 02.06.2019 HI Erwin, have you similar script for Kostal or something else? RE: Fronius inverter JSON integration - tomasjancys - 04.06.2019 (01.06.2019, 09:57)Erwin van der Zwart Wrote: Hi, Thanks Erwin! RE: Fronius inverter JSON integration - Firechief - 19.06.2020 Hi Erwin, Does this script work on the regular connection with the internet or is there a separate connection to the inverter. They have installed a Fronius here today and i'm running the script resident with an interval of 60 seconds, but i get no data. Adjusted the IP and created objects in HL, no errors and no log. Thx in advance RE: Fronius inverter JSON integration - Daniel - 19.06.2020 This is old way of making Modbus TCP integration it work on local network. This should be converted to a profile. RE: Fronius inverter JSON integration - balatis - 20.06.2020 Hi in modbus section creat a new modbus tcp connection and try below Json RE: Fronius inverter JSON integration - Firechief - 21.06.2020 @Balatis, File uploaded as a profile in Modbus section, connection created. Error Log: Fronius (TCP 192.168.XXX.XXX:502) connection failed: Connection refused. I guess that the port is not right, but i can't find what port to set. Thx edit: The pv system was installed last friday and i guess i don't have full admin access to the inverter and the modbus is not active on the inverter. i will call them first thing monday. RE: Fronius inverter JSON integration - Firechief - 22.06.2020 Update: Got on the phone with Fronius tech support and they gave me access to the inverter. Adjusted the modbus settings in the inverter and it's working now. Thx RE: Fronius inverter JSON integration - Firechief - 22.06.2020 As mentioned above, connection works, but i think i don't have the right setting in the modbus config because for some data i get really strange values. Or otherwise my datatype's are incorrect in HL Modbus settings: Gegevensoverdracht via Modbus: TCP Modbus-poort: 502 String Control-adresoffset: 101 Sunspec Model Type: Float (can select int/SF) Datatype in HL objects: 4 byte floating point RE: Fronius inverter JSON integration - balatis - 22.06.2020 (22.06.2020, 16:45)Firechief Wrote: As mentioned above, connection works, but i think i don't have the right setting in the modbus config because for some data i get really strange values. Or otherwise my datatype's are incorrect in HLif you have value , you have communication ..... maybe your type of inverter has deferment register list of values .... The above json is for symo 10000w here there is all register data of all models https://www.fronius.com/en/photovoltaics/products/all-products/system-monitoring/open-interfaces/modbus-rtu RE: Fronius inverter JSON integration - Firechief - 21.04.2021 Balatis, Just to let you know, I adjusted the Sunspec Model Type from Float to int/SF and now values are correct. In the meantime i also installed the Fronius Smart Meter and I will try to adapt the json profile to be able to read all the data from the Smart Meter as well. RE: Fronius inverter JSON integration - Firechief - 22.04.2021 Hi All, Based on the json profile provided above, I created a second profile for the smart meter. Then I created a second modbus connection on the HL with the same IP and Port as the Fronius inverter, but changed the device adress to 2 as the Inverter has adress 1. This doesn't work and I get a "read failed : Target device failed to respond" error. I looked in the manual and this writes the modbus device ID for the Smart Meter should be 240 for the 1st smart meter. It still doesn' work. Can anyone help? Thx in advance PS: json profile added RE: Fronius inverter JSON integration - Daniel - 22.04.2021 You don't have any datatype set in your profile, looking on the bus_datatype it is most likely more than one register. If it is just one then datatype is not needed for more it is mandatory. https://openrb.com/docs/modbus.htm RE: Fronius inverter JSON integration - Firechief - 22.04.2021 Daniel, I made an exact copy of the profile (wich works) provided by Balatis above, I only changed the addresses to what I could find in the Fronius documentation. I now see an error on the profile: "Fronius Smart Meter(TCP 192.168.100.189:502)read failed: illegal data address" So I guess the addresses are not correct? Kind regards So would this be correct syntax?: Code: { RE: Fronius inverter JSON integration - Daniel - 22.04.2021 I don't know as I don't know what is the registry size. What does the manuals says about this? RE: Fronius inverter JSON integration - Firechief - 23.04.2021 Daniel, Attached the manual and register for the Fronius. There is a second register for the meter also. File attached Hope you can help me out... Inverter is a single phase and meter is a 3-fase because the grid is 3x400V+N Kind regards RE: Fronius inverter JSON integration - admin - 23.04.2021 Since the addressing starts from 1 you need to subtract 1 from each address. You also need to read from input registers (read-only), not normal registers. Then there's a separate register which stores the scaling factor. Newer firmwares have an option to do a read test not only for RTU but also for TCP. It's more convenient than creating profiles for testing. Try this profile: Code: { RE: Fronius inverter JSON integration - Firechief - 23.04.2021 Admin, Created the profile but noticed in JSON editor there was an error on line 13: Code: "value_nan":[ 0x8000 ] Error: Parse error on line 13: ... "value_nan":[ 0x8000 ] }, -----------------------^ Expecting 'STRING', 'NUMBER', 'NULL', 'TRUE', 'FALSE', '{', '[', ']', got 'undefined' Tried the profile but still getting the error: "Fronius Test(TCP 192.168.100.189:502)read failed: illegal data address" RE: Fronius inverter JSON integration - admin - 23.04.2021 JSON does not allow hexadecimal numbers by default but LM will accept such profile. Have you deleted the device and created it again from scratch after uploading new profile? Are you using slave ID 240 for the meter? If it still does not work then use Read test to check which input register is readable. |