Skip to content

Hysteresis

The Hysteresis operation converts a fluctuating numeric input into a stable boolean output using two thresholds. The output switches to true when the input exceeds Threshold High and back to false when it drops below Threshold Low. Within the dead band (between the thresholds), the output retains its current state. The execution path automatically stops whenever the output does not change.

Hysteresis operation

Inputs

PortTypeRequiredDescription
InInteger or FloatYesThe numeric value to compare against the thresholds.

Outputs

PortTypeDefaultDescription
OutBooleanInitial Output Statetrue when above the high threshold, false when below the low threshold.

Properties

NameTypeDefaultDescription
Threshold HighNumber22.0Input must exceed this value to transition from false to true.
Threshold LowNumber20.0Input must fall below this value to transition from true to false.
Initial Output StateBooleanfalseStarting output value on first run or after state reset.
On ErrorComboStop this branchPer-op On Error verb (Stop this branch / Continue with the last value / Continue with the fallback). See the Error Handling guide.

State on Reload

Output is preserved across restarts within the configured time window. Saved state is discarded if either Threshold High or Threshold Low changed. In that case the output starts from Initial Output State.


  1. Validate input — The input must be numeric (Integer or Float). A non-numeric value or an unconnected input invokes the On Error verb.

  2. Evaluate state —

    • If current state is false and input > Threshold High → output becomes true.
    • If current state is true and input < Threshold Low → output becomes false.
    • Otherwise (input is within the dead band) → output stays the same.
  3. Path continuation — The execution path continues only when the output changes. If the output is the same as before, the path stops.


Assume Threshold High: 22.0, Threshold Low: 20.0, Initial Output State: false.

Current state: false   In: 25.0

25.0 > 22.0 → output transitions to true. Path continues.


  • Stable on/off control for heating, cooling, or lighting systems
  • Preventing relay “chatter” when sensor readings fluctuate near a threshold
  • Converting noisy analog signals into clean digital events

Hysteresis can hit these errors: an unconnected input, or a non-numeric value on the input (the Type mask catches most of these earlier).

Any of these triggers the On Error verb you picked. See the Error Handling guide for the common On Error model; Hysteresis’s options are:

VerbWhat it does
Stop this branch (default)This Node and its dependents stop; Out keeps its value and reads as a failed update.
Continue with the last valueDependents run on the value Out already holds, not stamped as new; it reads as a failed update.
Continue with the fallbackDependents run on Out’s per-output Fallback, stamped as this run’s value; it reads as a failed update. The Editor refuses a Task where the Fallback is unset.

Out carries the per-output Fallback you set in Settings under the Out port, like any other Output — Nil until you set one. Setting it to match the Initial Output State keeps a failed run consistent with how the Node started.

The built-in dead-band stop — “input is within the band, output doesn’t change, Path stops” — is part of the denoiser’s normal behaviour and is not an error.


  • Threshold Low must be strictly less than Threshold High; otherwise validation fails.
  • The built-in path-stop on unchanged output cannot be disabled.
  • Only unit-threshold hysteresis is supported (no multi-level).