Examples library
Nine automations that cover most of what a house actually asks for. Each one is built from blocks that already exist in Flows — nothing here needs custom code.
1.How to read these
Every example follows the same shape, and every one is built on the Flows page of Installer Studio.
- Blocks are dragged from the menu at the top of the Flows canvas, then wired by dragging from an output dot to an input dot.
- Device trigger blocks watch one property of one device. Device action blocks write to one.
- Nothing runs until you press Deploy. After that the flow lives on the server and keeps working with the internet unplugged.
- Blocks that hold a state — flip-flops, delayed on/off, the alarm, the lighting and fan-coil controllers — have a Rem switch. Rem on means the block comes back after a reboot exactly as it was; Rem off means it starts fresh.
2.Corridor light on motion, only after dark
The classic. Motion turns the light on, but only in the evening and at night — during the day the corridor has enough daylight and the customer finds it annoying.
What you need
- A motion sensor device with a
motionproperty. - A light the server can switch.
- The site location set, so the server knows when sunset is.
How to build it
- Add a Device trigger: the motion sensor, property
motion, trigger equals true. - Add a Time condition: reference solar, event
sunset, operator after. Leave the offset at 0, or set −30 to start half an hour before sunset. - Add a Logic AND and wire both of the above into it.
- Add a Delayed on/off block. Wire the AND output into its
Trinput. Set Doff to 120 seconds — how long the light stays on after the last motion. - Add a Device action: the light, action set, value from connection. Wire the delayed block's
Ooutput into it. - Press Deploy.
3.Staircase light with a timeout
A push button lights the staircase for two minutes, and any further press restarts the two minutes rather than switching it off.
What you need
- A push button as a device with a boolean property.
- A light.
How to build it
- Add a Device trigger on the button, trigger changed — it emits a short pulse on every press.
- Add a Delayed on/off block, Don 0 and Doff 120 seconds. Wire the pulse into
Tr. - Wire its
Ooutput into a Device action on the light. - Deploy.
- Each new press re-triggers the block, so the two minutes start again — exactly what a staircase needs.
- To let a long press force it off, wire a second trigger into the block's
Offinput.
4.A room with moods and a central off
One room with several light circuits, a few saved moods (Bright, Dinner, TV), and a single button in the hall that switches every room off when leaving.
What you need
- Two or more light circuits in the room — switched, dimmed or RGB.
- A wall button for the room, and one for the hall.
How to build it
- Add a Lighting Controller block. Set Circuits to how many lights the room has.
- Wire each circuit output
Lc1,Lc2… to a Device action on the matching light. - Add moods with + in the block. For each mood set what every circuit should do — a level for dimmers, a colour for RGB, on/off for switched lights.
- Wire the room button into
Moodto step through moods, or intoOnandOfffor plain control. - Add a Lighting Controller Central block, open it and select every room controller it should command.
- Wire the hall button into the central block's
Offinput. - Deploy.
P (presence) and Mo (motion) inputs with their own timeouts, so the same block can do the corridor example for a whole room. Every input, output and parameter is listed in the Lighting Controller reference.5.Fan-coil room with a window contact
A room kept at temperature by a fan coil, which stops when a window is opened and resumes when it is closed.
What you need
- A room temperature sensor.
- A fan-coil unit — on/off, fan speed and heat/cool mode.
- A window contact.
How to build it
- Add a Fan Coil (AC) block.
- Wire the temperature sensor into
Tc. - Set Setpoint to the target temperature and Deadband to how far it may drift before the unit reacts (0.5 °C is a sensible start).
- Leave Mode on Auto so it heats or cools depending on which side of the setpoint the room is.
- Wire the window contact into
Win. While that input is active the block holds the unit off. - Wire the outputs:
OnOff,Fan,ModeandTseach to a Device action on the fan coil. - Deploy.
6.Blinds that follow the sun
South-facing blinds go down when the afternoon sun hits the glass, and come back up in the evening.
What you need
- A blind with a position property.
- Ideally a weather station or outdoor brightness sensor; without one, time alone works.
How to build it
- Add a Time condition: solar, event
noon, operator after — the sun is on that façade from midday. - If you have a brightness sensor, add a Device trigger on it with trigger above and a threshold in lux, and combine both with a Logic AND.
- Wire the result into a Device action on the blind: action position, value 30 — down far enough to shade, not so far the room goes dark.
- Add a second Time condition: solar,
sunset, after, wired to another Device action setting position 100. - Deploy.
7.Alarm with entry and exit delay
Arming gives 30 seconds to leave; coming home gives time to disarm before the siren sounds. Interior sensors are bypassed when armed in stay mode so the family can move around at night.
What you need
- An alarm device.
- Motion sensors and window/door contacts.
- A siren output.
How to build it
- Add an Alarm block and pick the alarm device.
- Add a point for each sensor with Add motion sensor and Add window/door sensor, then wire each physical sensor into the matching input.
- Set Exit delay to 30 seconds — the grace period after arming.
- Set Entry delay to the seconds the customer needs to reach the keypad. Leave it at 0 if the siren should sound immediately.
- Wire the
Sirenoutput to the siren device, andNotifyto a Notification block so the panel shows what happened. - Deploy.
- Stay vs away: arming to stay bypasses the motion sensors and watches only doors and windows. Arming to away watches everything.
- Rem: turn it on if the system must still be armed after a power cut. With Rem off the alarm comes back disarmed — safer for commissioning, wrong for a finished site.
- During the exit delay, sensor activity is ignored on purpose — the customer walking out of their own front door must not start anything.
- Every input, output and parameter is listed in the Alarm reference.
8.Water leak shut-off
A leak sensor under the sink closes the main valve and tells everyone, immediately and without conditions.
What you need
- A leak sensor.
- A motorised valve the server can close.
How to build it
- Add a Device trigger on the leak sensor, trigger equals true.
- Wire it to a Device action that closes the valve.
- Wire the same trigger to a Notification block with a message like "Water leak detected — main valve closed" and severity set to the highest level.
- Deploy.
9.Holiday presence simulation
While the family is away, a few lights come on in the evening so the house does not look empty.
What you need
- Two or three lights in rooms visible from the street.
- A way to say "we are away" — a scene, a button, or the alarm being armed to away.
How to build it
- Add a Memory flag set block with a key such as
holiday, driven by the button or scene that starts holiday mode. - Add a Time condition: solar,
dusk, after. - Add a Memory flag get on
holidayand combine it with the time condition in a Logic AND. - Wire the result to the living-room light, and through a Delay block of a few minutes to a second light, so they do not all switch together.
- Add a second time condition for the hour the lights should go off, wired to actions that switch them off.
- Deploy.
holiday flag can also lower the heating setpoint and arm the alarm.10.Tell the customer something happened
Anything worth knowing — a door left open, a freezer warming up, a failed automation — shows up on the panel instead of being discovered later.
What you need
- Whatever sensor the message is about.
How to build it
- Add the Device trigger for the condition — for example a freezer temperature with trigger above −15.
- Add a Delayed on/off with Don of 600 seconds, so a door opened for a minute does not raise an alarm.
- Wire it to a Notification block. Write the message in the customer's language and set a cooldown so it cannot repeat every few seconds.
- Deploy.