Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- dashboard_import:
- package_import_url: github://MariuszWoszczynski/WMBUS-reader/WMBUS-reader-v5.yaml@main
- import_full_config: true
- substitutions:
- name: "wmbus-reader-v5"
- friendly_name: "WMBUS Reader V5"
- esphome:
- name: "${name}"
- friendly_name: "${friendly_name}"
- project:
- name: esphome.wmbus_reader
- version: "1.0"
- esp32:
- board: nodemcu-32s
- framework:
- type: esp-idf
- external_components:
- # - source:
- # type: git
- # url: https://github.com/IoTLabs-pl/esphome-components
- # alternatively
- #- source: github://SzczepanLeon/[email protected] #or @5.0.4
- - source: github://zelo66/wmbusmeterCustom@main #or @5.0.4
- components:
- - socket_transmitter
- - wmbus_common
- - wmbus_radio
- - wmbus_meter
- mdns:
- disabled: false
- time:
- - platform: sntp
- id: time_sntp
- # Enable logging
- logger:
- level: VERY_VERBOSE
- logs:
- wmbus: VERY_VERBOSE
- # Enable Home Assistant API
- api:
- encryption:
- key: "xxxZMIENNATOWOJ"
- ota:
- - platform: esphome
- password: "xxxZMIENNATOWOJ"
- wifi:
- ssid: !secret wifi_ssid
- password: !secret wifi_password
- output_power: 18dB
- # static IP configuration (instead of data from the secret file)
- # manual_ip:
- # static_ip: 192.168.10.99
- # gateway: 192.168.10.1
- # subnet: 255.255.255.0
- # Enable fallback hotspot (captive portal) in case wifi connection fails
- ap:
- ssid: "Wmbus-Reader-V5 Fallback Hotspot"
- captive_portal:
- web_server:
- port: 80
- version: 3
- output:
- - platform: gpio
- id: status_led
- pin: GPIO02
- spi:
- clk_pin: GPIO33
- mosi_pin: GPIO32
- miso_pin: GPIO19
- wmbus_radio:
- radio_type: SX1276
- cs_pin: GPIO23
- reset_pin: GPIO22
- irq_pin: GPIO21
- # on_packet:
- # - logger.log: "Odebrano pakiet: ${data}" # Loguje dane pakietu
- on_frame:
- - then:
- - logger.log:
- format: "RSSI: %ddBm T: %s (%d)"
- args: [ frame->rssi(), frame->as_hex().c_str(), frame->data().size() ]
- - then:
- - repeat:
- count: 1
- then:
- - output.turn_on: status_led
- - delay: 100ms
- - output.turn_off: status_led
- - delay: 100ms
- ##############################################################################################################################################################################
- ##############################################################################################################################################################################
- # The following sensors are examples, for IZAR, APATOR, UNISMART, Heat and Electricity meters. Leave only the configuration of such meters you have, delete the other sensors.
- ##############################################################################################################################################################################
- ##############################################################################################################################################################################
- ############################# Define counters here (typ, ID, key, mode...) ###############################
- wmbus_meter:
- - id: electricity_meter
- meter_id: 0x00000 ######## enter your ELECTRICITY meter ID here ########### #0x00000000 #ID format for SzczepanLeon
- type: tauronkpl # Lub "kaifa" - spróbuj obu wariantów
- # key: xxxxxx
- key: xxxxx######## enter your key here ###########
- mode:
- - T1
- - C1
- ########################### Define sensors here #####################################
- sensor:
- - platform: wmbus_meter #Electicity meter
- parent_id: electricity_meter
- field: current_power_consumption_kw
- name: Electricity Meter - current power
- accuracy_decimals: 0
- device_class: power
- unit_of_measurement: W
- state_class: measurement
- filters:
- - multiply: 1000
- - platform: wmbus_meter
- parent_id: electricity_meter
- field: total_energy_consumption_kwh
- name: Electricity Meter - energy consumption
- accuracy_decimals: 3
- device_class: energy
- state_class: total_increasing
- - platform: wmbus_meter
- parent_id: electricity_meter
- field: total_energy_production_kwh
- name: Electricity Meter - energy production
- accuracy_decimals: 3
- device_class: energy
- state_class: total_increasing
- - platform: wmbus_meter
- parent_id: electricity_meter
- field: current_power_production_kw
- name: Electricity Meter - current power production
- accuracy_decimals: 0
- device_class: power
- unit_of_measurement: W
- state_class: measurement
- filters:
- - multiply: 1000
- - platform: wmbus_meter
- parent_id: electricity_meter
- field: voltage_at_phase_1_v
- name: Electricity Meter - voltage L1
- accuracy_decimals: 0
- device_class: voltage
- unit_of_measurement: V
- state_class: measurement
- - platform: wmbus_meter
- parent_id: electricity_meter
- field: voltage_at_phase_2_v
- name: Electricity Meter - voltage L2
- accuracy_decimals: 0
- device_class: voltage
- unit_of_measurement: V
- state_class: measurement
- - platform: wmbus_meter
- parent_id: electricity_meter
- field: voltage_at_phase_3_v
- name: Electricity Meter - voltage L3
- accuracy_decimals: 0
- device_class: voltage
- unit_of_measurement: V
- state_class: measurement
- - platform: wmbus_meter
- parent_id: electricity_meter
- field: max_power_consumption_kw
- name: Electricity Meter - max power
- accuracy_decimals: 3
- device_class: power
- state_class: measurement
- - platform: wmbus_meter
- parent_id: electricity_meter
- field: rssi_dbm
- name: Electricity Meter RSSI
- #######################################################################################
- # More info on https://github.com/SzczepanLeon/esphome-components
Advertisement
Add Comment
Please, Sign In to add comment