Cannot reset a flow meter on the nodemcu

Hi

I have setup a flow meter on a Nodemcu and get it all working but not the reset

esphome:
  name: flowmeter
  platform: esp32
  board: nodemcu-32s

# Enable logging
logger:

web_server:
  port: 80

# Enable Home Assistant API
api:
  encryption:
    key: "T0zldFKZ4eJ/h9E6yWnICjqDwN3sdjno1WW2VJljln0="
  services:
    - service: new_pulse
      variables:
        new_pulse_total: int
      then:
        - pulse_counter.set_total_pulses:
            id: my_pulse
            value: !lambda 'return new_pulse_total;'

ota:
  password: "74c0ff152eb0a7fc74090cc0f5072bf5"

wifi:
  ssid: !secret wifi_ssid
  password: !secret wifi_password

  # Enable fallback hotspot (captive portal) in case wifi connection fails
  ap:
    ssid: "Flowmeter Fallback Hotspot"
    password: "JK1OGlNKc6pH"

captive_portal:

sensor:
  - platform: uptime
    name: Smart Meter Uptime
  - platform: wifi_signal
    name: Smart Meter WiFi signal
  - platform: pulse_counter
    id: my_pulse
    pin: 12
    name: "Pulse Counter"
    update_interval: 2s
    # on_value:
    #   - pulse_counter.set_total_pulses:
    #       id: my_pulse
    #       value: 0
    total:
      unit_of_measurement: 'L'
      name: 'Total in Liter'
      filters:
        - multiply: 0.0022

Any help please