The 2023.7 update of ESPHome added readouts for the Belgian capacity tariff to the DSMR component. As my Slimmelezer+’s config didn’t include these sensors, I’ve setup my own config bases on Marcel’s to add them.

Note that the config below will also include sensors that are not available on Belgian meters. Some have a Belgian counterpart (like gas_delivered vs gas_delivered_be), some just don’t seem to be used in Belgium (like electricity_failures). The DSMR encryption key also isn’t needed on Belgian meters. You can remove those sections or comment them out in config below or disable the entities within Home Assistant.

substitutions:
  device_name: slimmelezer
  device_description: "DIY P1 module to read your smart meter"
     
esphome:
  name: ${device_name}
  friendly_name: ${device_name}
  comment: "${device_description}"
  platform: ESP8266
  esp8266_restore_from_flash: true
  board: d1_mini
  name_add_mac_suffix: false
  project:
    name: zuidwijk.slimmelezer
    version: "1.0"
  # on_boot:
  #   then:
  #     - if:
  #         condition:
  #           lambda: return id(has_key);
  #         then:
  #           - lambda: |-
  #               std::string key(id(stored_decryption_key), 32);
  #               id(dsmr_instance).set_decryption_key(key);
  #         else:
  #           - logger.log:
  #               level: info
  #               format: "Not using decryption key. If you need to set a key use Home Assistant service 'ESPHome:  ${device_name}_set_dsmr_key'"
 
wifi:
  ssid: !secret wifi_ssid
  password: !secret wifi_password
 
  # Enable fallback hotspot (captive portal) in case wifi connection fails
  ap:
    ssid: ${device_name}
    ap_timeout: 15s
 
captive_portal:
 
# Enable logging
logger:
  baud_rate: 0
 
# Enable Home Assistant API
api:
  encryption:
    key: !secret api_encryption_key
  # services:
  #   service: set_dsmr_key
  #   variables:
  #     private_key: string
  #   then:
  #     - logger.log:
  #         format: Setting private key %s. Set to empty string to disable
  #         args: [private_key.c_str()]
  #     - globals.set:
  #         id: has_key
  #         value: !lambda "return private_key.length() == 32;"
  #     - lambda: |-
  #         if (private_key.length() == 32)
  #           private_key.copy(id(stored_decryption_key), 32);
  #         id(dsmr_instance).set_decryption_key(private_key);
 
ota:
 
web_server:
  port: 80
 
uart:
  baud_rate: 115200
  rx_pin: D7
 
# globals:
#   - id: has_key
#     type: bool
#     restore_value: yes
#     initial_value: "false"
#   - id: stored_decryption_key
#     type: char[32]
#     restore_value: yes
 
dsmr:
  id: dsmr_instance
  # For Luxembourg users set here your decryption key. 
  # Enable this when using decryption for Luxembourg;
  # key looks like '00112233445566778899AABBCCDDEEFF'
  #decryption_key: !secret decryption_key 
 
sensor:
  - platform: dsmr
    # --- Electricity ---
    # energy_delivered_lux:
    #   name: "Energy Consumed Luxembourg"
    #   state_class: total_increasing
    energy_delivered_tariff1:
      name: "Energy Consumed Tariff 1"
      state_class: total_increasing
    energy_delivered_tariff2:
      name: "Energy Consumed Tariff 2"
      state_class: total_increasing
    # energy_returned_lux:
    #   name: "Energy Produced Luxembourg"
    #   state_class: total_increasing
    energy_returned_tariff1:
      name: "Energy Produced Tariff 1"
      state_class: total_increasing
    energy_returned_tariff2:
      name: "Energy Produced Tariff 2"
      state_class: total_increasing
    power_delivered:
      name: "Power Consumed"
      accuracy_decimals: 3
    power_returned:
      name: "Power Produced"
      accuracy_decimals: 3
    # electricity_failures:
    #   name: "Electricity Failures"
    #   icon: mdi:alert
    # electricity_long_failures:
    #   name: "Long Electricity Failures"
    #   icon: mdi:alert
    # electricity_sags_l1:
    #   name: "Voltage Sags Phase 1"
    #   icon: mdi:alert
    # electricity_sags_l2:
    #   name: "Voltage Sags Phase 2"
    #   icon: mdi:alert
    # electricity_sags_l3:
    #   name: "Voltage Sags Phase 3"
    #   icon: mdi:alert
    # electricity_swells_l1:
    #   name: "Voltage Swells Phase 1"
    #   icon: mdi:alert
    # electricity_swells_l2:
    #   name: "Voltage Swells Phase 2"
    #   icon: mdi:alert
    # electricity_swells_l3:
    #   name: "Voltage Swells Phase 3"
    #   icon: mdi:alert
    voltage_l1:
      name: "Voltage Phase 1"
    voltage_l2:
      name: "Voltage Phase 2"
    voltage_l3:
      name: "Voltage Phase 3"
    current_l1:
      name: "Current Phase 1"
    current_l2:
      name: "Current Phase 2"
    current_l3:
      name: "Current Phase 3"
    power_delivered_l1:
      name: "Power Consumed Phase 1"
      accuracy_decimals: 3
    power_delivered_l2:
      name: "Power Consumed Phase 2"
      accuracy_decimals: 3
    power_delivered_l3:
      name: "Power Consumed Phase 3"
      accuracy_decimals: 3
    power_returned_l1:
      name: "Power Produced Phase 1"
      accuracy_decimals: 3
    power_returned_l2:
      name: "Power Produced Phase 2"
      accuracy_decimals: 3
    power_returned_l3:
      name: "Power Produced Phase 3"
      accuracy_decimals: 3
    # --- Peak Tariff ---
    active_energy_import_current_average_demand:
      name: "Peak Current Average Quarterly Demand"
      icon: mdi:chart-sankey
    active_energy_import_maximum_demand_running_month:
      name: "Peak Month Maximum Quarterly Demand"
      icon: mdi:chart-sankey
    active_energy_import_maximum_demand_last_13_months:
      name: "Peak 13 Month Maximum Quarterly Demand"
      icon: mdi:chart-sankey
    # --- Gas ---
    # gas_delivered:
    #   name: "Gas Consumed"
    #   state_class: total_increasing
    gas_delivered_be:
      name: "Gas Consumed Belgium"
      state_class: total_increasing
  - platform: uptime
    name: "${device_name} Uptime"
  - platform: wifi_signal
    name: "${device_name} Wi-Fi Signal"
    update_interval: 60s
 
text_sensor:
  - platform: dsmr
    identification:
      name: "DSMR Identification"
    # p1_version:
    #   name: "DSMR Version"
    p1_version_be:
      name: "DSMR Version Belgium"
    # timestamp:
    #   name: "DSMR Timestamp"
    electricity_tariff:
      name: "DSMR Tariff"
    # electricity_failure_log:
    #   name: "DSMR Electricity Failure Log"
    #   icon: mdi:message-alert-outline
    # message_short:
    #   name: "DSMR Message Short"
    #   icon: mdi:message-text-outline
    message_long:
      name: "DSMR Message Long"
      icon: mdi:message-text-outline
    # gas_equipment_id:
    #   name: "DSMR Gas Equipment ID"
    # water_equipment_id:
    #   name: "DSMR Water Equipment ID"
    # sub_equipment_id:
    #   name: "DSMR Sub Equipment ID"
    # gas_delivered_text:
    #   name: "DSMR Gas Delivered Text"
  - platform: wifi_info
    ip_address:
      name: "${device_name} IP Address"
    ssid:
      name: "${device_name} Wi-Fi SSID"
    bssid:
      name: "${device_name} Wi-Fi BSSID"
  - platform: version
    name: "ESPHome Version"
    hide_timestamp: true