Modbus RTU SDM72

Hello,

I would connect the SDM72 over RTU:

Register: 30053

Length Bytes: 4
Data Format: Float
Units: W
Hi Byte: 00
Lo Byte 034

  • name: “Stromzähler Heizung”
    type: serial
    baudrate: 9600
    bytesize: 8
    method: rtu
    parity: E
    port: /dev/ttyUSB0
    stopbits: 1
    sensors:
    • name: “Sensor1”
      unit_of_measurement: W
      address: 30053
      count: 2

The meter is recognized and values are also displayed. Unfortunately only always 0 and not the values from the counter. Can someone help me? I’m just new to Modbus and still have a lot to learn.

Thanks

Type input, address 53

This would receive a message but the message is wrong?

        address: 53
        count: 2
        input_type: input
        data_type: float
# Example configuration.yaml entry
modbus:
  - name: hub1
    type: tcp
    host: IP_ADDRESS
    port: 502
    sensors:
      - name: Sensor1
        unit_of_measurement: °C
        slave: 1
        address: 100
      - name: Sensor2
        unit_of_measurement: mg
        address: 110
        count: 2
      - name: Sensor3
        unit_of_measurement: °C
        slave: 1
        address: 120
        input_type: input
        data_type: float
        scale: 0.01
        offset: -273.16
        precision: 2

Yes I test it but then the result came but its wrong.

Maybe address 52

            # Get data from SDM72D
            Total_System_Power = self.rs485.read_float(52, functioncode=4, numberOfRegisters=2)
            Import_Wh_since_last_reset = self.rs485.read_float(72, functioncode=4, numberOfRegisters=2)
            Export_Wh_since_last_reset = self.rs485.read_float(74, functioncode=4, numberOfRegisters=2)
            Total_kwh = self.rs485.read_float(342, functioncode=4, numberOfRegisters=2)
            Settable_total_kWh = self.rs485.read_float(384, functioncode=4, numberOfRegisters=2)
            Settable_import_kWh = self.rs485.read_float(388, functioncode=4, numberOfRegisters=2)
            Settable_export_kWh = self.rs485.read_float(390, functioncode=4, numberOfRegisters=2)
            Import_power = self.rs485.read_float(1280, functioncode=4, numberOfRegisters=2)
            Export_power = self.rs485.read_float(1282, functioncode=4, numberOfRegisters=2)
            

Try adress 52 only. Always cancel “3” and all zero digits. From the leaving number (in this example the 53 discount 1). Might work.
Michael

I was able to successfully communicate to the SDM72D-M power meter, using the script below.

Hardware: Raspberry PI 3
Modbus connection: via USB to Modbus Dongle (no-name from Ebay)
Power meter: EASTRON SDM72D-M

Note: Baudrate was raised to 19.200 and polling interval shortened to 10 seconds. Any other setting for these two parameters naturally would work as well.

Important note: download the SDM72D-M user manual from Eastron, there you see the correct Modbus address codes.
For example; Phase1 line voltage is Addr: 0x00, Phase1 current is 0x06, total system power is 0x34 (decimal 52). Do Not use the 300xx register addresses, these won’t work.

modbus:

  • name: EASTRON_SDM72DM
    message_wait_milliseconds: 10
    retry_on_empty: true
    close_comm_on_error: false
    type: serial
    baudrate: 19200 #works also with 9600 baud
    bytesize: 8
    method: rtu
    parity: E
    port: /dev/ttyUSB0
    stopbits: 1
    sensors:

measure phase1 voltage (addr 0x00)

- name: "sdm72DM_L1_voltage"
  unit_of_measurement: V
  slave: 1
  address: 00
  input_type: input
  count: 2
  precision: 1
  scan_interval: 10
  device_class: Voltage
  state_class: measurement
  data_type: float32

measure phase1 current (addr 0x06)

- name: "sdm72DM_L1_current"
  unit_of_measurement: A
  slave: 1
  address: 06
  input_type: input
  count: 2
  precision: 2
  scan_interval: 10
  device_class: Current
  state_class: measurement
  data_type: float32

measure total instantaneous power consupmption (addr ox34)

- name: "sdm72DM_instant_power"
  unit_of_measurement: W
  slave: 1
  address: 52
  input_type: input
  count: 2
  precision: 1
  scan_interval: 10
  device_class: Power
  state_class: measurement
  data_type: float32

measure total cumulative energy consupmption (addr ox180)

- name: "sdm72DM_total_energy"
  unit_of_measurement: kWh
  slave: 1
  address: 384
  input_type: input
  count: 2
  precision: 1
  scan_interval: 10
  device_class: Energy
  state_class: measurement
  data_type: float32
2 Likes

Still happy or are there any updates I could look for ?

I have 4 of these SDM72D-M in my distribution panel to connect and then to read from my HA server.
That is cablewise 35 m away. I could use a LAN cable with its 4 pairs of 2 cables.

Would love to hear any news about your project and what you would suggest now with the experience of over a year.

Thanks a lot !