Timing blocks
Six blocks that deal with time: four that delay or stretch a signal, and two that watch the clock on their own.
1.Choosing the right one
They look similar in the menu and behave very differently.
| Block | Use it when you want | Driven by |
|---|---|---|
| Delay | The same value, later. | Its input |
| Timer | Something to run for a fixed length of time. | Its input |
| Delayed pulse | A short pulse, some time after an event. | Its input |
| Delayed on/off | Separate delays for switching on and off — the staircase timer. | Its input |
| Time condition | "Is it after sunset?" as a true/false you can gate with. | The clock, every minute |
| Schedule | Something to happen at a set time or on set days. | The clock, every minute |
2.Delay
Passes whatever arrives through to the output, later.
| Detail | |
|---|---|
| Input | One input, any type of value. |
| Output | The same value that arrived — not a true/false. A temperature in, the same temperature out. |
| Parameter | Seconds — how long to wait. Default 5. |
- It reacts to every value, true or false. Unlike the other timing blocks it does not ignore a falsy input.
- A new value while it is already waiting restarts the countdown and the older value is forgotten — only the latest one is ever delivered.
3.Timer
Runs for a set duration when triggered.
| Detail | |
|---|---|
| Input | One input. A falsy value is ignored completely — it does not stop a running timer. |
| Output | True / false. |
| Parameters | Duration (s), default 10 · Output when done, default true. |
The two shapes
- Output when done = true. Nothing happens at the trigger; after the duration the output goes true once. Use it as "in ten minutes, do this".
- Output when done = false. The output goes true immediately and false after the duration. Use it as "be on for ten minutes".
4.Delayed pulse
Waits, then emits a short pulse.
| Detail | |
|---|---|
| Input | One input. A falsy value is ignored. |
| Output | Goes true for the pulse length, then false. |
| Parameters | Delay (s) before the pulse, default 2 · Pulse (s) how long it stays true, default 0.5 (minimum 0.1). |
5.Delayed on/off
Separate delays for switching on and for switching off. This is the staircase timer, and the most used timing block.
| Pin | Direction | Description |
|---|---|---|
| Tr | Input | Trigger. A rising edge starts the on-delay; a falling edge starts the off-delay. |
| Off | Input | Dominating. While high the output is forced false and every pending delay is cancelled. |
| O | Output | The resulting on/off state. |
| Parameter | Description | Default |
|---|---|---|
| Don (s) | How long after Tr rises before the output goes on. | 1 |
| Doff (s) | How long after Tr falls before the output goes off. | 1 |
| Rem | Keeps the output and any pending delay across a restart. | 0 |
Staircase behaviour
Set Don to 0 and Doff to the time the light should stay on. Each press makes Tr rise and fall; the fall starts the off-delay, and a new press before it expires cancels it and starts the cycle again. That is why repeated presses extend the light instead of switching it off.
Tr drops again — a brief touch still switches the light on after Don. Only Off cancels it. (The off-delay is checked against Off when it fires, so an Off raised during the wait does suppress the switch-on.)6.Time condition
True or false depending on the time of day — either a clock time or a sun event.
| Parameter | Options | Default |
|---|---|---|
| Operator | before · after · at · before-or-equal · after-or-equal | after |
| Reference | A clock time, or a sun event | time |
| Time | The clock time, as HH:mm | 18:00 |
| Sun event | sunrise · sunset · dawn · dusk · noon | sunset |
| Offset (min) | Minutes added to the sun event; negative for before. | 0 |
It works two ways at once
- On its own, it re-checks the clock every minute and emits only when the answer changes — so a standalone "after sunset" node fires once, at sunset.
- As a gate, when something arrives on its input it answers immediately with true or false. That is how you put it in front of a Logic AND.
- On deploy it works out the current answer without firing anything, so re-deploying a flow at nine in the evening does not switch the garden lights on.
The sun events
- Sunrise / sunset — the sun on the horizon. Dawn / dusk — civil twilight, roughly half an hour either side, which is usually what "it is getting dark" really means for lighting.
- Noon — the midpoint between that day's sunrise and sunset.
7.Schedule
A source block with no input: it fires on the calendar.
| Mode | What you set | What it emits |
|---|---|---|
| Daily | One time of day. | True only, at that minute, every day. There is no matching false. |
| Weekly | A start and end time per weekday. | True at each start, false at each end. |
| Custom | Specific calendar dates with time windows. | True at each start, false at each end. |
8.What survives a restart
Worth knowing before you rely on a long delay.
| Event | What happens to a running delay or timer |
|---|---|
| Server restart | Pending timers are saved with their due time and re-armed on boot with whatever time is left. |
| Server was off past the due time | The timer fires almost immediately on boot, carrying the value it was holding. There is no "too late, skip it" rule. |
| Re-deploying the flow | Pending delays are dropped — a half-finished delay is gone. A Delayed on/off with Rem on keeps its output (the light stays as it was); with Rem off it starts from off. |
| Delayed on/off with Rem off | Starts fresh with the output off, regardless of what it was doing. |