Fronius Gen 24 modbus RTU

Hi. I already have 3 x Soils inverters and am successfully getting power and energy data from the inverters using modbus RTU. I have esphome running on a ESP8266, and a serial to RS485 board.

I want add 2 x Fronius Gen 24 Inverters and get power + energy data from then. I have set the Fronius inverters both to slaves and have given them unique ID’s. They are set to INT + SF. I don’t wish to use modbus TCP or API calls.

I am not seeing any values returned. Any ideas? Do I have the register values correct? And the value types?

  - platform: modbus_controller
    modbus_controller_id: modbus1_04
    id: fronius1_power
    name: "${device_name} Fronius1 Power" 
    address: 40083                 
    unit_of_measurement: "W"
    register_type: read
    value_type: U_WORD

  - platform: modbus_controller
    modbus_controller_id: modbus1_04
    id: fronius1_energy
    name: "${device_name} Fronius1 Energy" 
    address: 40093 
    unit_of_measurement: "Wh"
    register_type: read
    value_type: U_DWORD
    filters:
      - multiply: 100          
    state_class: total_increasing
    device_class: energy  

First of all, you should post your complete yaml.
Second, you should look at your logs to see what’s happening and post it
Third, esp8266 have only one serial, you should use esp32 board that has 3.

Why do I need 3 serial ports? I have one serial to rs485 board… so far 3 inverters on modbus, two more should be no issue… all with one serial port…. Up to 31 devices on one serial port should be ok, and I think a max of 256 @ lesser data demands….

My specific questions are around register addresses and data types….

Good idea on the logs… will do when I am next home…. Not sure how much the rest of the code helps - it’s already working with three inverters - my issue is with the two new ones, so I posted the relevant code…

If you can give different slave addresses and same baudrate and parity to all of your Frons, then one serial is fine.
If slave addresses are correct, you should see response from slaves on your log even if your register address is wrong.

Thank you… as I mentioned, all have unique id’s (and correct baud rate / parity settings)

I will come back with the logs when next home - in a day or two….

Thanks for your help….

ok
from log we can see response or exception response and figure out how to get the data you need.

Solved… The Fronius registers are holding (the Solis were read), and had the value type incorrect for power. The inverter is set to int+sf. Also works with the inverter set to float - just need to change the register addresses (40091 and 40101) and value_types to FP32. And then don’t need any scaling for W and Wh.

  - platform: modbus_controller
    modbus_controller_id: modbus1_04
    id: fronius_power_p1
    name: "${device_name} Fronius Phase 1 Power" 
    address: 40083
    unit_of_measurement: "W"
    register_type: holding
    value_type: S_WORD
    filters:
    lambda: return x / 10.0;

  - platform: modbus_controller
    modbus_controller_id: modbus1_04
    id: fronius_energy_p1
    name: "${device_name} Fronius Phase 1 Energy" 
    address: 40093
    unit_of_measurement: "kWh"
    register_type: holding
    value_type: U_DWORD
    filters:
       - multiply: 0.0000001      
    state_class: total_increasing
    device_class: energy