name: Dual energy meter
products:
  - id: 79a7z01v3n35kytb
    model: V-WIFI-DL02-ES
entities:
  - entity: sensor
    category: diagnostic
    name: Total energy
    class: energy
    dps:
      - id: 123
        name: sensor
        type: integer
        unit: kWh
        class: total_increasing
        mapping:
          - scale: 1000
      - id: 103
        name: Device state
        type: string
        mapping:
          - dps_val: close
            value: close
          - dps_val: monitor
            value: monitor
          - dps_val: working
            value: working
          - dps_val: warning
            value: warning
  - entity: sensor
    translation_key: power_x
    translation_placeholders:
      x: A
    category: diagnostic
    class: power
    dps:
      - id: 105
        name: sensor
        type: integer
        unit: W
        force: true
        class: measurement
        mapping:
          - scale: 10
  - entity: sensor
    translation_key: current_x
    translation_placeholders:
      x: A
    category: diagnostic
    class: current
    dps:
      - id: 106
        name: sensor
        type: integer
        unit: A
        class: measurement
        force: true
        mapping:
          - scale: 1000
  - entity: sensor
    translation_key: voltage_x
    translation_placeholders:
      x: A
    category: diagnostic
    class: voltage
    dps:
      - id: 107
        name: sensor
        type: integer
        unit: V
        class: measurement
        force: true
        mapping:
          - scale: 10
  - entity: sensor
    category: diagnostic
    name: Total energy A
    class: energy
    dps:
      - id: 108
        name: sensor
        type: integer
        unit: kWh
        class: total_increasing
        mapping:
          - scale: 1000
  - entity: sensor
    category: diagnostic
    name: Today energy A
    class: energy
    dps:
      - id: 109
        name: sensor
        type: integer
        unit: kWh
        class: total_increasing
        mapping:
          - scale: 1000
  - entity: sensor
    translation_key: power_x
    translation_placeholders:
      x: B
    category: diagnostic
    class: power
    dps:
      - id: 115
        name: sensor
        type: integer
        unit: W
        force: true
        class: measurement
        mapping:
          - scale: 10
  - entity: sensor
    translation_key: current_x
    translation_placeholders:
      x: B
    category: diagnostic
    class: current
    dps:
      - id: 116
        name: sensor
        type: integer
        unit: A
        class: measurement
        force: true
        mapping:
          - scale: 1000
  - entity: sensor
    translation_key: voltage_x
    translation_placeholders:
      x: B
    category: diagnostic
    class: voltage
    dps:
      - id: 117
        name: sensor
        type: integer
        unit: V
        class: measurement
        force: true
        mapping:
          - scale: 10
  - entity: sensor
    category: diagnostic
    name: Total energy B
    class: energy
    dps:
      - id: 118
        name: sensor
        type: integer
        unit: kWh
        class: total_increasing
        optional: true
        mapping:
          - scale: 1000
  - entity: sensor
    category: diagnostic
    name: Today energy B
    class: energy
    dps:
      - id: 119
        name: sensor
        type: integer
        unit: kWh
        class: total_increasing
        mapping:
          - scale: 1000
