Skip to content

Usage Guide

This guide covers practical ways to use your WaterFlowKit in Home Assistant, including monitoring, calibration, automation examples, and dashboard tips.

Quick Start

After installation, your WaterFlowKit provides these key entities:

Flow Sensor Entities

EntityUse For
Flow1 Current water usageReal-time flow rate (L/min)
Flow1 Total ConsumptionCumulative volume — use for Energy Dashboard
Flow2 Current water usageReal-time flow rate sensor 2 (if connected)
Flow2 Total ConsumptionCumulative volume sensor 2 — use for Energy Dashboard

Water Temperature Entity (if applicable)

EntityUse For
Flow1 Water TemperatureWater temperature through sensor 1 (°C)
Flow2 TemperatureWater temperature through sensor 2 (°C)

Environment Sensor Entities

EntityUse For
TemperatureAmbient temperature around the WaterFlowKit (°C)
HumidityAmbient relative humidity (%)

Real-Time Monitoring

  1. Open Home Assistant and navigate to Settings
  2. Go to Devices & ServicesESPHome
  3. Select your WaterFlowKit device
  4. View all entities: flow rate, total volume, temperature (if applicable)

Disabling Unused Entities

If you're only using one sensor or don't have a temperature sensor:

  1. Go to your WaterFlowKit device
  2. Click on the unused entity
  3. Toggle Enabled to off

Home Assistant Energy Dashboard

Add water consumption to the Energy Dashboard for beautiful visualizations.

Adding Water Consumption

  1. Go to SettingsDashboardsEnergy
  2. Under Water Consumption, click Add Water Source
  3. Select your entity:
    • Flow1 Total Consumption or
    • Flow2 Total Consumption
  4. Click Save

Note: Use the Total Consumption entities (cumulative volume), not the flow rate entities.


Calibration

If your sensor readings don't match expected values, you can calibrate.

Method 1: Measure Known Volume

  1. Get a container with known volume (e.g., 10L bucket)
  2. Reset the sensor total in Home Assistant
  3. Fill the container through the monitored pipe
  4. Compare the sensor reading with actual volume
  5. Calculate correction factor:
    Correction = Actual Volume / Sensor Reading

Method 2: Adjust Pulses Per Liter in ESPHome

  1. Adopt the WaterFlowKit in ESPHome
  2. Find the pulse counter configuration:
yaml
sensor:
  - platform: pulse_counter
    pin:
      number: GPIO26
      mode:
        input: true
        pullup: true
    name: "Flow1 Current water usage"
    filters:
      - multiply: 0.00172  # Adjust for flow rate (L/min)
    total:
      name: "Flow1 Total Consumption"
      unit_of_measurement: "L"
      filters:
        - multiply: 0.00163  # Adjust for total volume (L)
  1. Adjust the multiply filter:
    • Reading too high? Decrease the value
    • Reading too low? Increase the value
  2. Save and install

Default vs Sensor-Specific Values

The firmware ships with default values that work for most sensors:

FilterDefault ValueDescription
Flow rate0.00172For L/min calculation
Total volume0.00163For L calculation

For more precision, use sensor-specific values:

SensorMultiply ValuePulses/Liter
YF-B1, YF-B70.00151515~660
YF-B5, YF-B60.00252525~396
YF-B100.00222222~450
YF-DN40-S0.03703704~27
YF-DN50-S0.08333333~12

Automation Examples

1. High Flow Alert

Alert when flow rate is unusually high (possible leak or open tap):

yaml
alias: "Water - High flow alert"
trigger:
  - platform: numeric_state
    entity_id: sensor.waterflowkit_flow1_current_water_usage
    above: 15  # More than 15 L/min
    for:
      minutes: 5
action:
  - service: notify.mobile_app
    data:
      title: "High Water Flow!"
      message: "Flow rate: {{ states('sensor.waterflowkit_flow1_current_water_usage') }} L/min for 5+ minutes"

2. Prolonged Flow Detection (Leak Warning)

Detect water running for an extended period:

yaml
alias: "Water - Prolonged flow warning"
trigger:
  - platform: numeric_state
    entity_id: sensor.waterflowkit_flow1_current_water_usage
    above: 0.5
    for:
      minutes: 30
action:
  - service: notify.mobile_app
    data:
      title: "Water Running!"
      message: "Water has been flowing for 30+ minutes. Check for open taps or leaks."

3. Daily Water Usage Report

Send a notification with daily water usage:

yaml
alias: "Water - Daily report"
trigger:
  - platform: time
    at: "21:00:00"
action:
  - service: notify.mobile_app
    data:
      title: "Daily Water Report"
      message: "Today's usage: {{ states('sensor.water_daily') }} L"

Note: Requires a utility meter helper for daily tracking.

4. Shower Timer

Track shower duration based on flow:

yaml
alias: "Shower - Timer notification"
trigger:
  - platform: numeric_state
    entity_id: sensor.waterflowkit_flow1_current_water_usage
    below: 1
condition:
  - condition: state
    entity_id: input_boolean.shower_in_progress
    state: "on"
action:
  - service: input_boolean.turn_off
    target:
      entity_id: input_boolean.shower_in_progress
  - service: notify.mobile_app
    data:
      title: "Shower Finished"
      message: "Duration: {{ (as_timestamp(now()) - as_timestamp(states.input_boolean.shower_in_progress.last_changed)) | int // 60 }} minutes"

5. Hot Water Temperature Alert

Alert if hot water isn't hot enough (requires YF-B7 or YF-B6 sensor):

yaml
alias: "Hot Water - Temperature alert"
trigger:
  - platform: numeric_state
    entity_id: sensor.waterflowkit_flow1_water_temperature
    below: 45
condition:
  - condition: numeric_state
    entity_id: sensor.waterflowkit_flow1_current_water_usage
    above: 2
action:
  - service: notify.mobile_app
    data:
      title: "Hot Water Issue"
      message: "Water temperature is only {{ states('sensor.waterflowkit_flow1_water_temperature') }}°C"

6. Flow Started/Stopped Events

Trigger automations when water flow starts or stops:

yaml
alias: "Water - Flow started"
trigger:
  - platform: numeric_state
    entity_id: sensor.waterflowkit_flow1_current_water_usage
    above: 0.5
action:
  # Add your actions here
  - service: logbook.log
    data:
      name: "Water Flow"
      message: "Started"

Dashboard Ideas

Creating Utility Meters

Track daily, weekly, and monthly water usage:

  1. Go to SettingsDevices & ServicesHelpers
  2. Click Create HelperUtility Meter
  3. Configure:
    • Name: Water Daily
    • Input sensor: sensor.waterflowkit_flow1_total_consumption
    • Meter reset cycle: Daily
  4. Repeat for weekly and monthly

Flow Monitoring:

  • sensor.waterflowkit_flow1_current_water_usage — Current flow rate
  • sensor.waterflowkit_flow1_total_consumption — Total volume
  • sensor.waterflowkit_flow1_water_temperature — Water temperature (if YF-B7/B6)

Environment Monitoring:

  • sensor.waterflowkit_temperature — Ambient temperature
  • sensor.waterflowkit_humidity — Ambient humidity

Example Dashboard Card - Water Overview

yaml
type: entities
title: Water Monitoring
entities:
  - entity: sensor.waterflowkit_flow1_current_water_usage
    name: Current Flow
  - entity: sensor.waterflowkit_flow1_total_consumption
    name: Total Volume
  - entity: sensor.waterflowkit_flow1_water_temperature
    name: Water Temperature
  - entity: sensor.waterflowkit_temperature
    name: Ambient Temperature
  - entity: sensor.waterflowkit_humidity
    name: Ambient Humidity

Flow Rate Gauge Card

yaml
type: gauge
entity: sensor.waterflowkit_flow1_current_water_usage
name: Water Flow
min: 0
max: 30
severity:
  green: 0
  yellow: 10
  red: 20
unit: L/min

History Graph - Daily Pattern

yaml
type: history-graph
title: Water Usage Today
entities:
  - entity: sensor.waterflowkit_flow1_current_water_usage
hours_to_show: 24

Best Practices

Installation Tips

  • Use thread seal tape (PTFE) on all threaded connections
  • Pressure test before final installation
  • Avoid installing where air bubbles can accumulate
  • Install in an accessible location for maintenance

Accuracy Tips

  • Ensure flow is within the sensor's rated range
  • Avoid very low flow rates (below minimum specification)
  • Calibrate after installation for best accuracy
  • Position sensor in a straight pipe section if possible

Multiple Sensor Setup

Using both sensors? Consider:

  • Hot and cold water lines
  • Water in vs water out (leak detection)
  • Before and after filter (filter efficiency)

ESPHome Configuration

For advanced users who want to customize the WaterFlowKit firmware.

Adopting in ESPHome

  1. Go to Home AssistantESPHome addon
  2. Your WaterFlowKit should appear — click Adopt
  3. Once adopted, you can edit the YAML configuration

Using GitHub Packages

Import directly from GitHub:

yaml
packages:
  smarthomeshop.waterflowkit: 
    github://smarthomeshop/waterflowkit/waterflowkit.yaml@main

Source Code


Common Use Cases

ScenarioKey EntitiesAutomation Ideas
Shower monitoringFlow rate, TemperatureDuration timer, temperature alerts
Garden irrigationFlow rate, TotalUsage tracking, schedule verification
Appliance trackingFlow rate, TotalWashing machine detection
Leak detectionFlow rateProlonged flow alerts
Hot water efficiencyTemperature, FlowTemperature monitoring

Integration Ideas

Combine with Other SmartHomeShop Products

ProductCombined Use
WaterMeterKitTotal + individual monitoring
WaterP1MeterKitWater + energy correlation
CeilSensePresence-based water usage

Need Help?