Equipment symbol
A symbol is an equipment drawing from the symbol library: pumps, fans, valves, tanks, heat exchangers, motors and more. The symbol paints itself by state: the “running”, “stopped” or “fault” color by the state and fault tags; tanks and the thermometer fill by the level tag, impellers and fan blades rotate while the equipment runs. “Mirror” turns the pump outlet the other way.
Ready-made objects with a faceplate (motor, valve, PID controller) are in the object library — there the symbol is already wired to tags and alarms.
Properties
Section titled “Properties”Besides the properties of every element — name, position, size, tooltip, rotation, transparency and the operate right:
| Property | Values | Default | Description |
|---|---|---|---|
Symbol |
symbol | pump.centrifugal |
Symbol |
StateTag |
tag name | State tag. Running / open — by the condition below; empty — the symbol in the «Stopped» color | |
RunCondition |
text | «Running» condition. Empty — TRUE or greater than zero. «= 3», «<> 0», «> 5» — comparison; «2..5» — range; «1;3;5» — one of the values; «bit 3» — word bit; «js: value == 3 || value == 5» — JavaScript expression | |
FaultTag |
tag name | Fault tag. Bool: fault — the symbol turns red | |
LevelTag |
tag name | Level tag. For tanks and thermometer: fill by value | |
Minimum |
number | 0 |
Level from |
Maximum |
number | 100 |
Level to |
Label |
text | Label | |
RunningColor |
#RRGGBB |
#3C9A5F |
“Running” color |
StoppedColor |
#RRGGBB |
#C3C9CF |
“Stopped” color |
FaultColor |
#RRGGBB |
#D32F2F |
“Fault” color |
LiquidColor |
#RRGGBB |
Medium color. Liquid in a tank, flow in a pipe; empty — default symbol color | |
Mirror |
true / false |
false |
Mirror. Mirror horizontally: pump outlet to the left |
Stretch |
true / false |
false |
Stretch. The symbol fills its frame completely, without keeping proportions (for example, a tall narrow tank) |
Animate |
true / false |
true |
Rotation when running. The impeller and fan blades rotate while the equipment is running |
From scripts
Section titled “From scripts”Item.Type = Symbol. Any property is read and changed by name: Item.RunningColor = "#D32F2F". The common element members (Visible, Enabled, Value, Raise, Apply…) are described in Elements from scripts.
Events
Section titled “Events”Mouse, hover, focus and keyboard — as for any element (see Events and functions).
Examples
Section titled “Examples”The state tag value. A symbol has no Tag property, so Item.Value is not available for it; the state tag comes from StateTag.
var pump = Screen.Items("Pump1");HMI.ShowMessage(pump.Label + ": " + (Tags(pump.StateTag).Value ? "running" : "stopped"));Maintenance mode: the symbol is grey and does not rotate while the unit is out for repair.
var s = Screen.Items("Fan2");var service = Tags("Fan2.Service").Value;s.Animate = !service;s.StoppedColor = service ? "#8A9199" : "#C3C9CF";