Three-Phase Voltage Out of Range Alarm
Raise an alarm when the voltage of any phase on a three-phase supply stays too high or too low, with the voltage of each phase in the alarm details. Catches undervoltage, overvoltage and a long voltage deviation on motor, pump and compressor feeds, switchboards and energy meters. Works with 230 V by default and with any nominal voltage, such as 120 V, set per device.
Who it’s for
Electricians, maintenance engineers and facility managers asking “is the supply voltage on this motor feed too high or too low?”, “are pumps, compressors or drives running on undervoltage or overvoltage?”, “is the voltage at this switchboard or energy meter staying inside the allowed range?” — when a voltage that stays out of range for minutes overheats motors, trips drives and shortens equipment life.
What it does
Reads the phase-to-neutral voltages of the three phases and raises a Major alarm when any phase stays outside the nominal voltage ± the tolerance for 1 minute. The defaults, 230 V ± 10 %, follow the supply voltage range of IEC 60038. The alarm details show the voltage of each phase, so you can see which phase is too high or too low. The alarm clears when every phase stays inside a narrower range, the nominal voltage ± 8 %, for 1 minute, so a voltage that moves around the limit does not raise and clear the alarm again and again.
A phase below the phase loss limit, 10 % of the nominal voltage by default (phaseLossThresholdPercent), is lost, not out of range, so this rule skips it. Phase loss is a separate alarm. A reading that is not a number, such as OFF or ERR, is skipped too. Skipped phases do not keep the alarm active: when the phase that raised it is lost or unreadable for 1 minute, or every phase is, the alarm clears.
How to set up
The rule has default values for every setting, so it works as soon as it is installed. Install on a device profile so the alarm covers every meter of that type at once and automatically picks up any new meter added later. Single-device installs are also supported.
The rule reads voltageL1, voltageL2 and voltageL3 in volts. On a supply that is not 230 V, set nominalVoltage on the meter or change its Default value (see How to customize).
How to customize
- To use keys from another source — change the Time series key on the
phaseL1,phaseL2andphaseL3arguments together (e.g.voltageL1→uL1). The script uses the argument names, so it keeps working when only the keys change. - To use different setting attribute names — change the Attribute key on the
nominal,tolerancePercent,clearTolerancePercent,lostPercent,holdMinutesandclearHoldMinutesarguments (e.g.voltageTolerancePercent→supplyTolerance). - To monitor a different supply voltage — change the Default value on the
nominalargument. For a 120 V supply in North America, setnominalto 120,tolerancePercentto 5 andclearTolerancePercentto 4, so the alarm follows Range A of ANSI C84.1 (114 to 126 V). - To change the trigger and clear ranges or the phase loss limit used when no per-device attribute is set — change the Default value on the
tolerancePercent,clearTolerancePercentorlostPercentarguments. Keep the clear tolerance smaller than the trigger tolerance. - To change how long the voltage must stay out of range or back in range — change the Default value on the
holdMinutesorclearHoldMinutesarguments. - To tune the settings at runtime without editing the rule — set the value on the entity as a regular server-side attribute. It can be edited directly from a dashboard using the Update Multiple Attributes input widget:
- Per device — set the attribute (e.g.
nominalVoltage,voltageTolerancePercent,voltageHoldMinutes) on the meter itself. The per-device value overrides the Default value. - Per customer (in deployments that use customers) — change Entity type on the relevant argument to Current owner, then set the attribute on the customer. Every meter that customer owns picks up that value.
- Per device — set the attribute (e.g.
- To make the alarm manual-clear-only — remove the Clear condition. The alarm then stays active until an operator clears it.
- To check the voltage only during set hours each week — in the Trigger conditions’ Schedule, choose Active at a specific time (or Custom for different hours per day). The schedule repeats every week. For different hours per site, add an argument that reads the schedule JSON from a server-side attribute on the device, and set its Default value to
{}so a device without the attribute raises the alarm at any time. Then switch the Schedule to Dynamic and pick that argument in Argument. - To control where the alarm shows up — toggle the propagation flags under Advanced settings.
Share Your Alarm Rule with the Community
Built a reliable alarm rule? Export it as a JSON from ThingsBoard and publish it to the IoT Hub. Share it with thousands of ThingsBoard developers and help the community react to incidents faster.