Putting it all together:
The background for this project is that I want to monitor how long my drinking water well pump is running for. The well is 85m deep into the ground water, but it is possible to pump faster than it refills if the water is left running for some reason (found out the hard way…). To avoid that ever happening again I have set up a pump monitor which will let me know if there is a problem. I could also measure more accurately how much water is actually used if instead of monitoring the pump, I installed a water meter that sends an impulse for each volume that passes through. For me it is adequate to monitor the pump, and not the actual water volume so I haven’t installed a meter at this time.
- After inclusion go to the zwave management panel
- Select the FIBARO System FGBS222 Smart Implant in the Nodes pane
- In the Node Config Options pane select “20: Input 1 operating mode”
- Choose the Config Value “Normally open alarm input” and click on “SET CONFIG PARAMETER”

- Now when you connect (and disconnect) the yellow wire of the implant to ground you should see messages in the zwave log, and events in the Logbook
- Now set up home-assistant:
We add a virtual binary switchpump_pressure_switchwhich will turn off and on as Input 1 opens and closes, in configuration.yml include:
input_boolean:
pump_pressure_switch:
name: "Well pump"
initial: "off"
and, also in configuration.yml, to measure the time the pump is on we create a history_stats sensor:
sensor:
- platform: history_stats
name: Pump duration last 24 hours
state: 'on'
entity_id: input_boolean.pump_pressure_switch
type: time
end: '{{ now() }}'
duration:
hours: 24
and now to switch the virtual pump switch (input_boolean) in automations.yml include:
- id: button_1_pressed
alias: 'Implant Button 1 Pressed'
trigger:
- platform: numeric_state
entity_id: sensor.fibaro_system_fgbs222_smart_implant_burglar
above: 1
below: 3
action:
- service: input_boolean.turn_on
data:
entity_id: input_boolean.pump_pressure_switch
- id: button_1_released
alias: 'Implant Button 1 Released'
trigger:
- platform: numeric_state
entity_id: sensor.fibaro_system_fgbs222_smart_implant_burglar
below: 1
action:
- service: input_boolean.turn_off
data:
entity_id: input_boolean.pump_pressure_switch
You should now see the state of pump_pressure_switch (ymmv) change as the yellow (input 1) circuit of the Fibaro implant is opened and closed. You will also see the automation changing the state in the Logbook. The history_stats sensor will keep track of how long the pump is on (or switch is closed).
Hope this helps others.