PZEM-016 ESPHome ModBus pzemac

Hello, I have a question :-).

Using following esphome config on D1 Mini. Connected a PZEM-016 via a RS485-TTL converter trying to measure power/Ampere.

ESPhome config:

esphome:
  name: pzem016modbus
  platform: ESP8266
  board: d1_mini

substitutions:
  esp_name: pzem016modbus
  # Higher value gives lower watt readout
  current_res: "0.00520"
  # Lower value gives lower voltage readout
  voltage_div: "750"

wifi:
  ssid: "IOTDOM"
  password: !secret IOTDOM_wifi_key
  use_address: 192.168.6.38
  domain: .local.local
  # Enable fallback hotspot (captive portal) in case wifi connection fails
  ap:
    ssid: "${esp_name} Fallback Hotspot"
    password: !secret Fallback_Hotspot

captive_portal:

# Enable logging
logger:

# Enable Home Assistant API
api:

ota:

time:
  - platform: homeassistant
    id: homeassistant_time

uart:
  tx_pin: D1
  rx_pin: D2
  baud_rate: 9600
  stop_bits: 1

sensor:
  - platform: wifi_signal
    name: "${esp_name} - WiFi Signal"
    update_interval: 6s
    
  - platform: uptime
    name: "${esp_name} - Uptime"
    icon: mdi:clock-outline
    update_interval: 60s
    
  - platform: pzemac
    update_interval: 1s
    current:
      name: "${esp_name} A"
    voltage:
      name: "${esp_name} V"
    power:
      name: "${esp_name} W"
      unit_of_measurement: W
      id: "${esp_name}_W"
      icon: mdi:flash-outline
    frequency:
      name: "${esp_name} Hz"
    power_factor:
      name: "${esp_name} Pf"
    energy:
      name: "${esp_name} Wh"

  - platform: total_daily_energy
    name: "${esp_name} - Dagverbruik"
    power_id: "${esp_name}_W"
    filters:
        # Multiplication factor from W to kW is 0.001
        - multiply: 0.001
    unit_of_measurement: kWh
    icon: mdi:clock-alert

The Voltage is correct (externally measured).

The Watt and Ampere read out is not correct. I tried to “substitiute” with some confgi I found for the platform: hlw8012 but this does not work on platform: pzemac


  # Higher value gives lower watt readout
  current_res: "0.00520"
  # Lower value gives lower voltage readout
  voltage_div: "750"

This is my outcome in home assistant with a vacuum cleaner on:
image

And this is measure on the outlet via a Hidance power meter equally (correctly):

4.107 A
649.9 W

How and what can be wrong here? Where to start troubleshooting?

Some logging:

[15:43:21][D][pzemac:049]: PZEM AC: V=231.5 V, I=1.745 A, P=317.5 W, E=18.0 Wh, F=50.0 Hz, PF=0.79
[15:43:21][D][sensor:092]: 'pzem016modbus V': Sending state 231.50000 V with 1 decimals of accuracy
[15:43:21][D][sensor:092]: 'pzem016modbus A': Sending state 1.74500 A with 3 decimals of accuracy
[15:43:21][D][sensor:092]: 'pzem016modbus W': Sending state 317.50000 W with 1 decimals of accuracy
[15:43:21][D][sensor:092]: 'pzem016modbus - Dagverbruik': Sending state 0.01309 kWh with 3 decimals of accuracy
[15:43:21][D][sensor:092]: 'pzem016modbus Wh': Sending state 18.00000 Wh with 0 decimals of accuracy
[15:43:21][D][sensor:092]: 'pzem016modbus Hz': Sending state 50.00000 hz with 1 decimals of accuracy
[15:43:21][D][sensor:092]: 'pzem016modbus Pf': Sending state 0.79000  with 2 decimals of accuracy
[15:43:22][D][sensor:092]: 'pzem016modbus - WiFi Signal': Sending state -59.00000 dB with 0 decimals of accuracy
[15:43:22][D][pzemac:049]: PZEM AC: V=231.5 V, I=1.745 A, P=317.5 W, E=18.0 Wh, F=50.0 Hz, PF=0.79
[15:43:22][D][sensor:092]: 'pzem016modbus V': Sending state 231.50000 V with 1 decimals of accuracy
[15:43:22][D][sensor:092]: 'pzem016modbus A': Sending state 1.74500 A with 3 decimals of accuracy
[15:43:22][D][sensor:092]: 'pzem016modbus W': Sending state 317.50000 W with 1 decimals of accuracy
[15:43:22][D][sensor:092]: 'pzem016modbus - Dagverbruik': Sending state 0.01318 kWh with 3 decimals of accuracy
[15:43:22][D][sensor:092]: 'pzem016modbus Wh': Sending state 18.00000 Wh with 0 decimals of accuracy
[15:43:22][D][sensor:092]: 'pzem016modbus Hz': Sending state 50.00000 hz with 1 decimals of accuracy
[15:43:22][D][sensor:092]: 'pzem016modbus Pf': Sending state 0.79000  with 2 decimals of accuracy

Same values with logging very verbose.

I have measured the real values vs sensor values and made filters for calibrate linear… but taht makes it more flaky… please assist :slight_smile:

This makes this when no power used:

esphome:
  name: pzem016modbus
  platform: ESP8266
  board: d1_mini

substitutions:
  esp_name: pzem016modbus
  # Higher value gives lower watt readout
  current_res: "0.00520"
  # Lower value gives lower voltage readout
  voltage_div: "750"

wifi:
  ssid: "IOTDOM"
  password: !secret IOTDOM_wifi_key
  use_address: 192.168.6.38
  domain: .local.local
  # Enable fallback hotspot (captive portal) in case wifi connection fails
  ap:
    ssid: "${esp_name} Fallback Hotspot"
    password: !secret Fallback_Hotspot

captive_portal:

# Enable logging
logger:

# Enable Home Assistant API
api:

ota:

time:
  - platform: homeassistant
    id: homeassistant_time

uart:
  tx_pin: D1
  rx_pin: D2
  baud_rate: 9600
  stop_bits: 1

sensor:
  - platform: wifi_signal
    name: "${esp_name} - WiFi Signal"
    update_interval: 6s
    
  - platform: uptime
    name: "${esp_name} - Uptime"
    icon: mdi:clock-outline
    update_interval: 60s
    
  - platform: pzemac
    update_interval: 1s
    current:
      name: "${esp_name} A"
      filters:
      - calibrate_linear:
      # Map from sensor -> measured value
          - 0.0 -> 0.0
          - 1.231 -> 2.695
          - 1.606 -> 3.651
          - 1.928 -> 4.920
    voltage:
      name: "${esp_name} V"
    power:
      name: "${esp_name} W"
      unit_of_measurement: W
      id: "${esp_name}_W"
      icon: mdi:flash-outline
      filters:
      - calibrate_linear:
      # Map from sensor -> measured value
          - 0.0 -> 0.0
          - 198.2 -> 260.7  
          - 261.0 -> 428.0 
          - 326.8 -> 679.0
          - 3450. -> 1094.0
    frequency:
      name: "${esp_name} Hz"
    power_factor:
      name: "${esp_name} Pf"
    energy:
      name: "${esp_name} Wh"

  - platform: total_daily_energy
    name: "${esp_name} - Dagverbruik"
    power_id: "${esp_name}_W"
    filters:
        # Multiplication factor from W to kW is 0.001
        - multiply: 0.001
    unit_of_measurement: kWh
    icon: mdi:clock-alert

image

Some logging…

[14:51:15][VV][scheduler:152]: Running interval 'update' with interval=1000 last_execution=166282 (now=167290)
[14:51:15][VV][uart_esp8266:111]:     Wrote 0b00000001 (0x01)
[14:51:15][VV][uart_esp8266:111]:     Wrote 0b00000100 (0x04)
[14:51:15][VV][uart_esp8266:111]:     Wrote 0b00000000 (0x00)
[14:51:15][VV][uart_esp8266:111]:     Wrote 0b00000000 (0x00)
[14:51:15][VV][uart_esp8266:111]:     Wrote 0b00000000 (0x00)
[14:51:15][VV][uart_esp8266:111]:     Wrote 0b00001010 (0x0A)
[14:51:15][VV][uart_esp8266:111]:     Wrote 0b01110000 (0x70)
[14:51:15][VV][uart_esp8266:111]:     Wrote 0b00001101 (0x0D)
[14:51:15][VV][uart_esp8266:132]:     Read 0b00000001 (0x01)
[14:51:15][VV][uart_esp8266:132]:     Read 0b00000100 (0x04)
[14:51:15][VV][uart_esp8266:132]:     Read 0b00010100 (0x14)
[14:51:15][VV][uart_esp8266:132]:     Read 0b00001001 (0x09)
[14:51:15][VV][uart_esp8266:132]:     Read 0b00011110 (0x1E)
[14:51:15][VV][uart_esp8266:132]:     Read 0b00010000 (0x10)
[14:51:15][VV][uart_esp8266:132]:     Read 0b00011000 (0x18)
[14:51:15][VV][uart_esp8266:132]:     Read 0b00000000 (0x00)
[14:51:15][VV][uart_esp8266:132]:     Read 0b00000000 (0x00)
[14:51:15][VV][uart_esp8266:132]:     Read 0b00011011 (0x1B)
[14:51:15][VV][uart_esp8266:132]:     Read 0b00000100 (0x04)
[14:51:15][VV][uart_esp8266:132]:     Read 0b00000000 (0x00)
[14:51:15][VV][uart_esp8266:132]:     Read 0b00000000 (0x00)
[14:51:15][VV][uart_esp8266:132]:     Read 0b00000000 (0x00)
[14:51:15][VV][uart_esp8266:132]:     Read 0b00111100 (0x3C)
[14:51:15][VV][uart_esp8266:132]:     Read 0b00000000 (0x00)
[14:51:15][VV][uart_esp8266:132]:     Read 0b00000000 (0x00)
[14:51:15][VV][uart_esp8266:132]:     Read 0b00000001 (0x01)
[14:51:15][VV][uart_esp8266:132]:     Read 0b11110100 (0xF4)
[14:51:15][VV][uart_esp8266:132]:     Read 0b00000000 (0x00)
[14:51:15][VV][uart_esp8266:132]:     Read 0b01001000 (0x48)
[14:51:15][VV][uart_esp8266:132]:     Read 0b00000000 (0x00)
[14:51:15][VV][uart_esp8266:132]:     Read 0b00000000 (0x00)
[14:51:15][VV][uart_esp8266:132]:     Read 0b01001101 (0x4D)
[14:51:15][VV][uart_esp8266:132]:     Read 0b01111101 (0x7D)
[14:51:15][D][pzemac:049]: PZEM AC: V=233.4 V, I=4.120 A, P=691.6 W, E=60.0 Wh, F=50.0 Hz, PF=0.72
[14:51:15][V][sensor:013]: 'pzem016modbus V': Received new state 233.399994
[14:51:15][D][sensor:092]: 'pzem016modbus V': Sending state 233.39999 V with 1 decimals of accuracy
[14:51:15][VV][api.service:105]: send_sensor_state_response: SensorStateResponse {
  key: 121758983
  state: 233.4
  missing_state: NO
}
[14:51:15][VV][api.service:105]: send_sensor_state_response: SensorStateResponse {
  key: 121758983
  state: 233.4
  missing_state: NO
}
[14:51:15][V][sensor:013]: 'pzem016modbus A': Received new state 4.120000
[14:51:15][D][sensor:092]: 'pzem016modbus A': Sending state 4.12000 A with 3 decimals of accuracy
[14:51:15][VV][api.service:105]: send_sensor_state_response: SensorStateResponse {
  key: 121758992
  state: 4.12
  missing_state: NO
}
[14:51:15][VV][api.service:105]: send_sensor_state_response: SensorStateResponse {
  key: 121758992
  state: 4.12
  missing_state: NO
}
[14:51:15][V][sensor:013]: 'pzem016modbus W': Received new state 691.599976
[14:51:15][VV][sensor.filter:013]: Filter(0x3fff327c)::input(691.599976)
[14:51:15][VV][sensor.filter:020]: Filter(0x3fff327c)::output(454.497650) -> SENSOR
[14:51:15][D][sensor:092]: 'pzem016modbus W': Sending state 454.49765 W with 1 decimals of accuracy
[14:51:15][VV][preferences:051]: SAVE 34: 0=0x41577563 1=0xA639A098 (Type=3594776413, CRC=0xA639A098)
[14:51:15][V][sensor:013]: 'pzem016modbus - Dagverbruik': Received new state 13.466159
[14:51:15][VV][sensor.filter:013]: Filter(0x3fff2f0c)::input(13.466159)
[14:51:15][VV][sensor.filter:020]: Filter(0x3fff2f0c)::output(0.013466) -> SENSOR
[14:51:15][D][sensor:092]: 'pzem016modbus - Dagverbruik': Sending state 0.01347 kWh with 3 decimals of accuracy
[14:51:15][VV][api.service:105]: send_sensor_state_response: SensorStateResponse {
  key: 3594776413
  state: 0.0134662
  missing_state: NO
}
[14:51:15][VV][api.service:105]: send_sensor_state_response: SensorStateResponse {
  key: 3594776413
  state: 0.0134662
  missing_state: NO
}
[14:51:15][VV][api.service:105]: send_sensor_state_response: SensorStateResponse {
  key: 121758982
  state: 454.498
  missing_state: NO
}
[14:51:15][VV][api.service:105]: send_sensor_state_response: SensorStateResponse {
  key: 121758982
  state: 454.498
  missing_state: NO
}
[14:51:15][V][sensor:013]: 'pzem016modbus Wh': Received new state 60.000000
[14:51:15][D][sensor:092]: 'pzem016modbus Wh': Sending state 60.00000 Wh with 0 decimals of accuracy
[14:51:15][VV][api.service:105]: send_sensor_state_response: SensorStateResponse {
  key: 1924892698
  state: 60
  missing_state: NO
}
[14:51:15][VV][api.service:105]: send_sensor_state_response: SensorStateResponse {
  key: 1924892698
  state: 60
  missing_state: NO
}
[14:51:15][V][sensor:013]: 'pzem016modbus Hz': Received new state 50.000000
[14:51:15][D][sensor:092]: 'pzem016modbus Hz': Sending state 50.00000 hz with 1 decimals of accuracy
[14:51:16][VV][api.service:105]: send_sensor_state_response: SensorStateResponse {
  key: 2243667489
  state: 50
  missing_state: NO
}
[14:51:16][VV][api.service:105]: send_sensor_state_response: SensorStateResponse {
  key: 2243667489
  state: 50
  missing_state: NO
}
[14:51:16][V][sensor:013]: 'pzem016modbus Pf': Received new state 0.720000
[14:51:16][D][sensor:092]: 'pzem016modbus Pf': Sending state 0.72000  with 2 decimals of accuracy
[14:51:16][VV][api.service:105]: send_sensor_state_response: SensorStateResponse {
  key: 1841004789
  state: 0.72
  missing_state: NO
}
[14:51:16][VV][api.service:105]: send_sensor_state_response: SensorStateResponse {
  key: 1841004789
  state: 0.72
  missing_state: NO
}
[14:51:16][V][app:081]: A component took a long time in a loop() cycle (0.52 s).
[14:51:16][V][app:082]: Components should block for at most 20-30ms in loop().
[14:51:16][VV][scheduler:152]: Running interval 'update' with interval=1000 last_execution=167282 (now=168284)
[14:51:16][VV][uart_esp8266:111]:     Wrote 0b00000001 (0x01)
[14:51:16][VV][uart_esp8266:111]:     Wrote 0b00000100 (0x04)
[14:51:16][VV][uart_esp8266:111]:     Wrote 0b00000000 (0x00)
[14:51:16][VV][uart_esp8266:111]:     Wrote 0b00000000 (0x00)
[14:51:16][VV][uart_esp8266:111]:     Wrote 0b00000000 (0x00)
[14:51:16][VV][uart_esp8266:111]:     Wrote 0b00001010 (0x0A)
[14:51:16][VV][uart_esp8266:111]:     Wrote 0b01110000 (0x70)
[14:51:16][VV][uart_esp8266:111]:     Wrote 0b00001101 (0x0D)
[14:51:16][VV][uart_esp8266:132]:     Read 0b00000001 (0x01)
[14:51:16][VV][uart_esp8266:132]:     Read 0b00000100 (0x04)
[14:51:16][VV][uart_esp8266:132]:     Read 0b00010100 (0x14)
[14:51:16][VV][uart_esp8266:132]:     Read 0b00001001 (0x09)
[14:51:16][VV][uart_esp8266:132]:     Read 0b00010110 (0x16)
[14:51:16][VV][uart_esp8266:132]:     Read 0b00001111 (0x0F)
[14:51:16][VV][uart_esp8266:132]:     Read 0b11110000 (0xF0)
[14:51:16][VV][uart_esp8266:132]:     Read 0b00000000 (0x00)
[14:51:16][VV][uart_esp8266:132]:     Read 0b00000000 (0x00)
[14:51:16][VV][uart_esp8266:132]:     Read 0b00011010 (0x1A)
[14:51:16][VV][uart_esp8266:132]:     Read 0b10101100 (0xAC)
[14:51:16][VV][uart_esp8266:132]:     Read 0b00000000 (0x00)
[14:51:16][VV][uart_esp8266:132]:     Read 0b00000000 (0x00)
[14:51:16][VV][uart_esp8266:132]:     Read 0b00000000 (0x00)
[14:51:16][VV][uart_esp8266:132]:     Read 0b00111100 (0x3C)
[14:51:16][VV][uart_esp8266:132]:     Read 0b00000000 (0x00)
[14:51:16][VV][uart_esp8266:132]:     Read 0b00000000 (0x00)
[14:51:16][VV][uart_esp8266:132]:     Read 0b00000001 (0x01)
[14:51:16][VV][uart_esp8266:132]:     Read 0b11110011 (0xF3)
[14:51:16][VV][uart_esp8266:132]:     Read 0b00000000 (0x00)
[14:51:16][VV][uart_esp8266:132]:     Read 0b01001000 (0x48)
[14:51:16][VV][uart_esp8266:132]:     Read 0b00000000 (0x00)
[14:51:16][VV][uart_esp8266:132]:     Read 0b00000000 (0x00)
[14:51:16][VV][uart_esp8266:132]:     Read 0b01111100 (0x7C)
[14:51:16][VV][uart_esp8266:132]:     Read 0b00010010 (0x12)
[14:51:16][D][pzemac:049]: PZEM AC: V=232.6 V, I=4.080 A, P=682.8 W, E=60.0 Wh, F=49.9 Hz, PF=0.72
[14:51:16][V][sensor:013]: 'pzem016modbus V': Received new state 232.600006
[14:51:16][D][sensor:092]: 'pzem016modbus V': Sending state 232.60001 V with 1 decimals of accuracy
[14:51:16][VV][api.service:105]: send_sensor_state_response: SensorStateResponse {
  key: 121758983
  state: 232.6
  missing_state: NO
}
[14:51:16][VV][api.service:105]: send_sensor_state_response: SensorStateResponse {
  key: 121758983
  state: 232.6
  missing_state: NO
}
[14:51:16][V][sensor:013]: 'pzem016modbus A': Received new state 4.080000
[14:51:16][D][sensor:092]: 'pzem016modbus A': Sending state 4.08000 A with 3 decimals of accuracy
[14:51:16][VV][api.service:105]: send_sensor_state_response: SensorStateResponse {
  key: 121758992
  state: 4.08
  missing_state: NO
}
[14:51:16][VV][api.service:105]: send_sensor_state_response: SensorStateResponse {
  key: 121758992
  state: 4.08
  missing_state: NO
}
[14:51:16][V][sensor:013]: 'pzem016modbus W': Received new state 682.799988
[14:51:16](Message skipped because it was too big to fit in TCP buffer - This is only cosmetic)
[14:51:16][VV][sensor.filter:020]: Filter(0x3fff327c)::output(452.357483) -> SENSOR
[14:51:16][D][sensor:092]: 'pzem016modbus W': Sending state 452.35748 W with 1 decimals of accuracy
[14:51:16][VV][preferences:051]: SAVE 34: 0=0x415982E1 1=0x94329991 (Type=3594776413, CRC=0x94329991)
[14:51:16][V][sensor:013]: 'pzem016modbus - Dagverbruik': Received new state 13.594453
[14:51:16][VV][sensor.filter:013]: Filter(0x3fff2f0c)::input(13.594453)
[14:51:16][VV][sensor.filter:020]: Filter(0x3fff2f0c)::output(0.013594) -> SENSOR
[14:51:16][D][sensor:092]: 'pzem016modbus - Dagverbruik': Sending state 0.01359 kWh with 3 decimals of accuracy
[14:51:16][VV][api.service:105]: send_sensor_state_response: SensorStateResponse {
  key: 3594776413
  state: 0.0135945
  missing_state: NO
}
[14:51:16][VV][api.service:105]: send_sensor_state_response: SensorStateResponse {
  key: 3594776413
  state: 0.0135945
  missing_state: NO
}
[14:51:16][VV][api.service:105]: send_sensor_state_response: SensorStateResponse {
  key: 121758982
  state: 452.357
  missing_state: NO
}
[14:51:16][VV][api.service:105]: send_sensor_state_response: SensorStateResponse {
  key: 121758982
  state: 452.357
  missing_state: NO
}
[14:51:16][V][sensor:013]: 'pzem016modbus Wh': Received new state 60.000000
[14:51:17][D][sensor:092]: 'pzem016modbus Wh': Sending state 60.00000 Wh with 0 decimals of accuracy
[14:51:17][VV][api.service:105]: send_sensor_state_response: SensorStateResponse {
  key: 1924892698
  state: 60
  missing_state: NO
}
[14:51:17][VV][api.service:105]: send_sensor_state_response: SensorStateResponse {
  key: 1924892698
  state: 60
  missing_state: NO
}
[14:51:17][V][sensor:013]: 'pzem016modbus Hz': Received new state 49.900002
[14:51:17][D][sensor:092]: 'pzem016modbus Hz': Sending state 49.90000 hz with 1 decimals of accuracy
[14:51:17][VV][api.service:105]: send_sensor_state_response: SensorStateResponse {
  key: 2243667489
  state: 49.9
  missing_state: NO
}
[14:51:17][VV][api.service:105]: send_sensor_state_response: SensorStateResponse {
  key: 2243667489
  state: 49.9
  missing_state: NO
}
[14:51:17][V][sensor:013]: 'pzem016modbus Pf': Received new state 0.720000
[14:51:17][D][sensor:092]: 'pzem016modbus Pf': Sending state 0.72000  with 2 decimals of accuracy
[14:51:17][VV][api.service:105]: send_sensor_state_response: SensorStateResponse {
  key: 1841004789
  state: 0.72
  missing_state: NO
}
[14:51:17][VV][api.service:105]: send_sensor_state_response: SensorStateResponse {
  key: 1841004789
  state: 0.72
  missing_state: NO
}
[14:51:17][V][app:081]: A component took a long time in a loop() cycle (0.46 s).
[14:51:17][V][app:082]: Components should block for at most 20-30ms in loop().
[14:51:17][VV][scheduler:152]: Running interval 'update' with interval=6000 last_execution=162388 (now=168848)
[14:51:17][V][sensor:013]: 'pzem016modbus - WiFi Signal': Received new state -55.000000
[14:51:17][D][sensor:092]: 'pzem016modbus - WiFi Signal': Sending state -55.00000 dB with 0 decimals of accuracy
[14:51:17][VV][api.service:105]: send_sensor_state_response: SensorStateResponse {
  key: 3933520911
  state: -55
  missing_state: NO
}
[14:51:17][VV][api.service:105]: send_sensor_state_response: SensorStateResponse {
  key: 3933520911
  state: -55
  missing_state: NO
}
[14:51:17][VV][scheduler:152]: Running interval 'update' with interval=1000 last_execution=168282 (now=169282)
[14:51:17][VV][uart_esp8266:111]:     Wrote 0b00000001 (0x01)
[14:51:17][VV][uart_esp8266:111]:     Wrote 0b00000100 (0x04)
[14:51:17][VV][uart_esp8266:111]:     Wrote 0b00000000 (0x00)
[14:51:17][VV][uart_esp8266:111]:     Wrote 0b00000000 (0x00)
[14:51:17][VV][uart_esp8266:111]:     Wrote 0b00000000 (0x00)
[14:51:17][VV][uart_esp8266:111]:     Wrote 0b00001010 (0x0A)
[14:51:17][VV][uart_esp8266:111]:     Wrote 0b01110000 (0x70)
[14:51:17][VV][uart_esp8266:111]:     Wrote 0b00001101 (0x0D)
[14:51:17][VV][uart_esp8266:132]:     Read 0b00000001 (0x01)
[14:51:17][VV][uart_esp8266:132]:     Read 0b00000100 (0x04)
[14:51:17][VV][uart_esp8266:132]:     Read 0b00010100 (0x14)
[14:51:17][VV][uart_esp8266:132]:     Read 0b00001001 (0x09)
[14:51:17][VV][uart_esp8266:132]:     Read 0b00100110 (0x26)
[14:51:17][VV][uart_esp8266:132]:     Read 0b00000100 (0x04)
[14:51:17][VV][uart_esp8266:132]:     Read 0b10001111 (0x8F)
[14:51:17][VV][uart_esp8266:132]:     Read 0b00000000 (0x00)
[14:51:17][VV][uart_esp8266:132]:     Read 0b00000000 (0x00)
[14:51:17][VV][uart_esp8266:132]:     Read 0b00001000 (0x08)
[14:51:17][VV][uart_esp8266:132]:     Read 0b00101111 (0x2F)
[14:51:17][VV][uart_esp8266:132]:     Read 0b00000000 (0x00)
[14:51:17][VV][uart_esp8266:132]:     Read 0b00000000 (0x00)
[14:51:17][VV][uart_esp8266:132]:     Read 0b00000000 (0x00)
[14:51:17][VV][uart_esp8266:132]:     Read 0b00111100 (0x3C)
[14:51:17][VV][uart_esp8266:132]:     Read 0b00000000 (0x00)
[14:51:17][VV][uart_esp8266:132]:     Read 0b00000000 (0x00)
[14:51:17][VV][uart_esp8266:132]:     Read 0b00000001 (0x01)
[14:51:17][VV][uart_esp8266:132]:     Read 0b11110100 (0xF4)
[14:51:17][VV][uart_esp8266:132]:     Read 0b00000000 (0x00)
[14:51:17][VV][uart_esp8266:132]:     Read 0b01001101 (0x4D)
[14:51:17][VV][uart_esp8266:132]:     Read 0b00000000 (0x00)
[14:51:17][VV][uart_esp8266:132]:     Read 0b00000000 (0x00)
[14:51:17][VV][uart_esp8266:132]:     Read 0b00011100 (0x1C)
[14:51:17][VV][uart_esp8266:132]:     Read 0b11001001 (0xC9)
[14:51:17][D][pzemac:049]: PZEM AC: V=234.2 V, I=1.167 A, P=209.5 W, E=60.0 Wh, F=50.0 Hz, PF=0.77
[14:51:17][V][sensor:013]: 'pzem016modbus V': Received new state 234.199997
[14:51:17][D][sensor:092]: 'pzem016modbus V': Sending state 234.20000 V with 1 decimals of accuracy
[14:51:17][VV][api.service:105]: send_sensor_state_response: SensorStateResponse {
  key: 121758983
  state: 234.2
  missing_state: NO
}
[14:51:17](Message skipped because it was too big to fit in TCP buffer - This is only cosmetic)
[14:51:17][V][sensor:013]: 'pzem016modbus A': Received new state 1.167000
[14:51:17][D][sensor:092]: 'pzem016modbus A': Sending state 1.16700 A with 3 decimals of accuracy
[14:51:17][VV][api.service:105]: send_sensor_state_response: SensorStateResponse {
  key: 121758992
  state: 1.167
  missing_state: NO
}
[14:51:17][VV][api.service:105]: send_sensor_state_response: SensorStateResponse {
  key: 121758992
  state: 1.167
  missing_state: NO
}
[14:51:17][V][sensor:013]: 'pzem016modbus W': Received new state 209.500000
[14:51:17][VV][sensor.filter:013]: Filter(0x3fff327c)::input(209.500000)
[14:51:17][VV][sensor.filter:020]: Filter(0x3fff327c)::output(337.249634) -> SENSOR
[14:51:17][D][sensor:092]: 'pzem016modbus W': Sending state 337.24963 W with 1 decimals of accuracy
[14:51:17][VV][preferences:051]: SAVE 34: 0=0x415AF6B3 1=0x8FA61E70 (Type=3594776413, CRC=0x8FA61E70)
[14:51:17][V][sensor:013]: 'pzem016modbus - Dagverbruik': Received new state 13.685229
[14:51:17][VV][sensor.filter:013]: Filter(0x3fff2f0c)::input(13.685229)
[14:51:17][VV][sensor.filter:020]: Filter(0x3fff2f0c)::output(0.013685) -> SENSOR
[14:51:17][D][sensor:092]: 'pzem016modbus - Dagverbruik': Sending state 0.01369 kWh with 3 decimals of accuracy
[14:51:17][VV][api.service:105]: send_sensor_state_response: SensorStateResponse {
  key: 3594776413
  state: 0.0136852
  missing_state: NO
}
[14:51:17][VV][api.service:105]: send_sensor_state_response: SensorStateResponse {
  key: 3594776413
  state: 0.0136852
  missing_state: NO