Ferraris Energy Counter

Hi all,

i´m trying to figure out how to read the energy consumption from my old ferraris counter. (96rounds per kwh)
I have a tcrt5000 sensor attached to a wemos d1 mini.
Now I´m unsure if my setup is correct so far and if you have any further advices.

My ESPHome Code:


sensor:
  - platform: pulse_counter
    pin: GPIO12
unit_of_measurement: 'kW'
name: Stromzaehler
filters:
   - multiply: 0.0104167

If this is working I will add more sensors for Gas and Water.

It seems that total daily energy consumption is not supported by esphome for pulse counters?

It’s not indented properly. Here’s mine, along with my perfectly-working total daily energy sensor:

sensor:
  - platform: pulse_counter
    pin: D5
    unit_of_measurement: 'kW'
    name: 'Power Meter House'
    filters:
      - multiply: 0.06
    id: house_power

  - platform: total_daily_energy
    name: "Total Daily Energy"
    power_id: house_power
    accuracy_decimals: 1

image

image

2 Likes

Also, you need a multiplier of 0.625, I think. The pulse-counter measures in pulses per minute, and you need to adjust it so that this is the same as kW.

96 pulses in an hour would be 1kW, which is the same as 96/60 pulses per minute, so you need to multiply by 60/96=0.625 to get to the desired output number of 1. This does mean your minimum resolution will be 625W, which for typical house base load will result in a very “jumpy” graph with 0W in some slots and 625W in others. The long-term average will be accurate, though — you could set up a “smoothed” template filter in HA.

Ah, thanks for your explanation!
I will change the multiplier :slight_smile:

625W is indeed very “jumpy” - but as a starter it will do the job.
Later I will have a look at monitoring with clamps. But this looks much more complicated at a first look.

Do you have any example how this “smoothed” template filter could look like? I’ve tried it with the statistics platfrom, but the values doesn’t make sense:

sensor:

  - platform: statistics

    name: "Haus Stromzähler Mean"

    entity_id: sensor.haus_stromzahler

    state_characteristic: mean

My graph is very jumpy…like:
0, 0, 0, 0, 0, 0.8, 0, 0

And the statistics entity is showing 0.4 kW which must be wrong. In the upper example it should be 0.1 kW → 0.8/8

Something like this: Filter - Home Assistant