Home Assistant and Eastron SDM72d with Protoss PW21

Hello together,

I’m trying to connect the SDM72D with my Home Assistant, unfortunately without success.
I’m think the configuration is by the Protoss OK, because I can see in Protoss that the bytes are sending to my wallbox.
In my configuration.yaml I have:


# modbus communication
modbus:
  - name: "hauptzahler"
    close_comm_on_error: false
    retry_on_empty: true
    retries: 10
    delay: 10
    message_wait_milliseconds: 1000
    timeout: 10
    
    type: tcp
    host: 192.168.178.XX
    port: 8899
    sensors:
      - name: hauptzahler_phase_1_line_to_neutral_volts
        slave: 1
        address: 1
        input_type: input
        count: 2
        precision: 2
        data_type: float32
        unit_of_measurement: V
        device_class: voltage
        scan_interval: 30
      - name: hauptzahler_phase_1_current
        slave: 1
        address: 6
        input_type: input
        count: 2
        precision: 2
        data_type: float32
        unit_of_measurement: A
        device_class: current
        scan_interval: 30
      - name: hauptzahler_phase_1_power
        slave: 1
        address: 12
        input_type: input
        count: 2
        precision: 3
        data_type: float32
        unit_of_measurement: kW
        device_class: power
      - name: hauptzahler_phase_1_va
        slave: 1
        address: 18
        input_type: input
        count: 2
        precision: 2
        data_type: float32
        unit_of_measurement: VA
        device_class: power
      - name: hauptzahler_phase_1_va_reactive
        slave: 1
        address: 24
        input_type: input
        count: 2
        precision: 2
        data_type: float32
        unit_of_measurement: VAr
        device_class: power
      - name: hauptzahler_sum_of_line_currents
        slave: 1
        address: 48
        input_type: input
        count: 2
        precision: 3
        data_type: float32
        unit_of_measurement: A
        device_class: current
      - name: hauptzahler_total_system_power
        slave: 1
        address: 52
        input_type: input
        count: 2
        precision: 3
        scale: 0.001
        data_type: float32
        unit_of_measurement: kW
        device_class: power
      - name: hauptzahler_total_system_va
        slave: 1
        address: 56
        input_type: input
        count: 2
        precision: 2
        data_type: float32
        unit_of_measurement: VA
        device_class: power
      - name: hauptzahler_total_system_var
        slave: 1
        address: 60
        input_type: input
        count: 2
        precision: 2
        data_type: float32
        unit_of_measurement: VAr
        device_class: power
      - name: hauptzahler_frequency_of_supply_voltages
        slave: 1
        address: 70
        input_type: input
        count: 2
        precision: 2
        data_type: float32
        unit_of_measurement: Hz
      - name: hauptzahler_import_wh_since_last_reset
        slave: 1  
        address: 73
        input_type: input
        count: 2
        precision: 2
        data_type: float32
        unit_of_measurement: kWh
        device_class: energy
      - name: hauptzahler_export_wh_since_last_reset
        slave: 1
        address: 74
        input_type: input
        count: 2
        precision: 2
        data_type: float32
        unit_of_measurement: kWh
        device_class: energy
      - name: hauptzahler_total_system_power_demand
        slave: 1
        address: 84
        input_type: input
        count: 2
        precision: 2
        data_type: float32
        unit_of_measurement: W
        device_class: power
      - name: hauptzahler_maximum_total_system_power
        slave: 1
        address: 86
        input_type: input
        count: 2
        precision: 2
        data_type: float32
        unit_of_measurement: W
        device_class: power
      - name: hauptzahler_total_system_va_demand
        slave: 1
        address: 100
        input_type: input
        count: 2
        precision: 2
        data_type: float32
        unit_of_measurement: VA
        device_class: power
      - name: hauptzahler_maximum_total_system_va_demand
        slave: 1
        address: 102
        input_type: input
        count: 2
        precision: 2
        data_type: float32
        unit_of_measurement: VA
        device_class: power
      - name: hauptzahler_line_1_to_line_2_volts
        slave: 1
        address: 200
        input_type: input
        count: 2
        precision: 2
        data_type: float32
        unit_of_measurement: V
        device_class: voltage
      - name: hauptzahler_line_2_to_line_3_volts
        slave: 1
        address: 202
        input_type: input
        count: 2
        precision: 2
        data_type: float32
        unit_of_measurement: V
        device_class: voltage
      - name: hauptzahler_line_3_to_line_1_volts
        slave: 1
        address: 204
        input_type: input
        count: 2
        precision: 2
        data_type: float32
        unit_of_measurement: V
        device_class: voltage
        
# Example configuration.yaml entry
utility_meter:
  daily_energy:
    source: sensor.hauptzahler_total_system_power
    name: Daily Energy
    cycle: daily

  monthly_energy:
    source: sensor.hauptzahler_total_system_power
    name: Monthly Energy
    cycle: monthly

The IP and port are correct and the addresses should be correct too. Nevertheless I get this error by HA:

Logger: homeassistant.components.modbus.modbus
Source: components/modbus/modbus.py:385
Integration: Modbus (documentation, issues)
First occurred: 18:23:14 (1 occurrences)
Last logged: 18:23:14

Pymodbus: hauptzahler: Modbus Error: [Input/Output] Modbus Error: [Invalid Message] No response received, expected at least 8 bytes (0 received)

Can You help me?

EDIT: I have checked now once again and some bytes are sending via “Netp” to my synology where HA is installed (see attachment).

Protoss is working

Try sensors individually in yaml

You just have one error

Maybe its only one sensor failing

Thank You Nikita for Your reply. I have deleted now all and left only one. I get still the same error.
Perhaps is it because of wrong addresses? As attachment I send You the table with addresses. What should I write to get for example the informations about the first position in the table?

I have now:


modbus:
  - name: "hauptzahler"
    close_comm_on_error: false
    retry_on_empty: true
    retries: 10
    delay: 10
    message_wait_milliseconds: 1000
    timeout: 10
    type: tcp
    host: 192.168.178.XX
    port: 8899
    sensors:
      - name: hauptzahler_gesamt_leistung
        slave: 1
        address: 1
        data_type: float32
        unit_of_measurement: W
        device_class: power

but don’t work.

modbus:
#
  - name: "hauptzahler"
    close_comm_on_error: true
    retry_on_empty: false
    retries: 3
    delay: 1
    message_wait_milliseconds: 250
    timeout: 5
    type: tcp
    host: 192.168.178.XX
    port: 8899
#
    sensors:
      - name: hauptzahler_gesamt_leistung
        slave: 1
        address: 1 # try with 1, 2, 30001,  30002
        count: 2
        input_type: input
        data_type: float32
        unit_of_measurement: W
        device_class: power

Hi,

I have tried now all the four addresses and unfortunately without success… still the same error.



Hello once again,

what I found now, that after restart of Home Assistant for the short time HA has a connection with the protoss but after ca. 1 minute loose the connection. Any ideas why?

Log: Pymodbus: hauptzahler: Modbus Error: [Input/Output] [Errno 32] Broken pipe

Hey, it works with my SDM72D

# Modbus
modbus:
- name: moxa
  type: tcp
  host: 192.168.2.149
  port: 502

  sensors:
    - name: SDM_Wallbox_Wirkleistung
      slave: 1
      address: 52
      count: 2
      input_type: input
      data_type: float32
      unit_of_measurement: W
      device_class: power
    - name: SDM_Wallbox_gesamte_kumulierte_Wirkleistung
      slave: 1
      address: 342
      count: 2
      input_type: input
      data_type: float32
      unit_of_measurement: kWh
      device_class: energy