Knowledge Base
Article

System variables field definitions

Edit

System variables field definitions

Description

A system variable is a named value on the logger that Smart Alerts, Plant Control and the System Variables widget read. This article explains each field on the System Variables tab of the logger. For the procedures, see Set up System Variables.

Variable Kinds

  • User: a value that you set. Its ID is user. followed by 12 random letters.
  • DDP (device data point): one field of one installed device. Its ID is device., then the serial number and the field name.
  • Computed: the result of a formula over other values. Its ID is calc. followed by 8 random letters.
  • Plant: a live Plant Control value. It is not on this tab, and the logger does not save it.
  • Digital IO: a digital input or output of the logger. It is not on this tab, and the logger does not save it.

User Defined Variables

The table on the User sub-tab.

  • Name: the name that shows in every value list.
  • Desc: the description.
  • Ui Comp Type: the type of control in the Value cell.
  • Value Type: the type of the value.
  • Value: the current value.
  • Unit: free text. Value lists show it after the name.
  • Last Modified: the date and time of the last change.
  • Last Modified By: the client ID that made the last change.
  • Last Modified Note: shows Created for a row added with Add Row. After an MQTT command, it shows the note of the command, or Changed via MQTT.
  • ID: the ID that formulas and Plant Control use.
  • Row menu: has Edit Options and Remove.
  • save icon: sends the row to the logger.
  • Add Row: in the table menu. Adds a row named changeme with the value -1.

Ui Comp Types

  • Number: a number box.
  • Switch: a check box. A ticked box is 1, and a clear box is 0. The cell shows = 1 or = 0 after the box.
  • Drop Down: a list of the options that you set in Edit Options.

Value Types

  • Number: a decimal number.
  • Boolean: on or off. Smart Alerts show the states as On and Off. Formulas read on as 1 and off as 0. From LoggerV 9.351, Plant Control also reads on as 1 and off as 0.
  • String: text. A formula uses it only if the text is a number.

The Edit Item List dialog, from Edit Options in the row menu.

  • Value: the number that the variable stores.
  • Name: the text in the list.
  • plus icon: adds an option. Its Value is the number of options that the list already had.
  • bin icon: removes the option.
  • save icon: keeps the options and saves the row.

Device Data Points

The table on the DDP sub-tab.

  • Name: the field name. It is editable.
  • Desc: the field description. It is editable.
  • Serial Number: the serial number of the device.
  • Value: the device value, read-only. The logger rounds a decimal value down to 2 decimal places.
  • Unit: the unit of the field.
  • Row menu: has Remove, which takes the field off this tab. The device does not change.
  • save icon: sends Name and Desc to the logger.
  • Add DDP: in the table menu. It opens All available DDPs.

All Available DDPs

The dialog from Add DDP.

  • Columns: Name, Desc, Serial Number, Model, Unit.
  • Row menu: has Add, which moves the field to the DDP sub-tab.
  • Storage clusters: the dialog lists the fields of each storage cluster that has recorded data today. The Model column shows Storage Cluster.
  • Not listed: fields that you already added, nested fields, and fields of deleted devices.

Computed Variables

The table on the Computed sub-tab.

  • Name: the name in every value list.
  • Desc: the description.
  • Formula: read-only here. Use Edit Formula to change it.
  • Unit: free text. Value lists show it after the name.
  • Value: the result, or invalid.
  • Last Modified Note: shows Created or Updated.
  • Row menu: has Edit Formula and Remove.
  • save icon: sends Name, Desc and Unit to the logger.
  • Add Row: in the table menu. It opens New computed variable.

Last Modified, Last Modified By and ID are the same as on the User sub-tab.

Computed Variable Dialog

  • Heading: New computed variable, or Edit computed variable.
  • Name: required.
  • Unit (optional): shows after the result.
  • Formula: numbers and operators show as text, and values show as chips.
  • + - * / ( ): keys that add the operator.
  • Insert value: opens the value list. The { key does the same.
  • edit as text: shows the whole formula as text, with each value as {id}.
  • Result line: shows Start with a number or a value, Checking..., the result followed by (live), or the error.
  • Create variable, Save variable: saves the variable.
  • Cancel: closes the dialog and saves nothing.

Formula Value List

  • Search values...: filters by name or ID.
  • Groups: Plant, Device data points, Digital IO, User variables. A group with no values does not show.
  • (offline): shows after a value that has no valid reading at the moment.
  • (missing): shows on a chip for a value that the logger no longer has.
  • No values match: the search found nothing.

Formula Grammar

  • Numbers: digits and a decimal point.
  • Operators: + - * /. Multiplication and division come first.
  • Brackets: ( and ).
  • Minus sign: allowed before a number, a value or a bracket.
  • Value: the ID in braces, for example {plant.PC_0.loadW}.
  • Not allowed: comparisons, functions and computed variables.
  • Length: up to 256 characters.
  • Values: up to 10 different values.
  • Boolean value: 1 for on, 0 for off.
  • Result: rounded down to 2 decimal places.
  • Invalid result: division by zero, or a value that is offline or missing.
  • Calculation: the logger works out the result every second, by default.

Consumers

  • System Variables widget: user variables, device data points and computed variables. See the System Variables widget article.
  • Smart Alerts: all kinds, in the groups Plant, Computed, Device data points, Digital IO and User variables. See Set up a Smart Alert.
  • Plant Control: the System Variable source of an expression. The Select Variable dialog has User, DDP and Computed. From LoggerV 9.351, to compare a Boolean variable, use a Fixed Value of 1 for on or 0 for off. Before LoggerV 9.351, Plant Control cannot compare a Boolean variable.
  • Formulas: use every kind except Computed.
  • MQTT client: sends all system variables on the variables topic. An MQTT command can set the value of a user variable. See MQTT topics and payloads field definitions.

Tips

  • The Value columns show the values from when the page loaded.
  • If the logger reconnects, or you save or delete a computed variable, the tables reload and you lose unsaved row edits.
  • When you delete a computed variable, the prompt says: Anything using it will show as invalid.

Related articles