How can we help?

Setup Custom Variable value or indicator

You are here:
< All Topics

Overview

The ability to display stored Custom Variable information within the RTV can be very useful. This will allow the RTV to Display a stored value or color right on a shop floor monitor. Using expressions to trigger what is displayed on the RTV allows for a truly customizable experience. For instance, if the machine is running with a low feed rate and you do not want that to record as a separate cycle it is possible to display a Custom Variable instead that will indicate what the feed rate is for that machine as well as a custom color associated with it. There are many possibilities and the steps below just highlight a generic example.

See end of how to for further detail regarding example expressions and how to clear out the contents. To see more information on how to add this to the RTV Grid view click here.

Steps to set up and display a custom variable value or indicator

  1. First, you will need to set a Custom Variable and name it. You can do this by selecting the DataXchange tab then click on the Variable button in the toolbar and select PCS Custom from the drop down.
  2. Create a custom variable. In this example the Custom Variable name is color:
  3. Go to Data Entry → Custom Commands. Create a custom command and name it red:
  4. Now add the custom command and assign it to a machine under Data Entry → Custom Command assignment.
  5. Next you will need to create the expression that will write to the Custom Variable. In this example this expression will trigger by the ODI screen and turn the color on the RTV Grid Red.

    Expression: ([Listener.data] = red)
    Result: [PCSDB.send_custom_variable_indicator] {color} == Red
  6. Assign the expression to the equipment.
  7. Create an RTV grid view and select the custom variable that you created.
  8. Now, when a user on the ODI screen selects red…

    …It will trigger the RTV to display a grid that is filled in red.

In the example above, to display a Custom Variable value instead of a color use the send variable value: [PCSDB.send_custom_variable_value] {VARIABLENAME} instead of the indicator variable. It is still possible to use leading “==” in the expression to set the value to be displayed. For instance, it is possible to display the the feed rate override value when using this expression.

Note: Custom Variable Indicators can be saved as color names, but that is not how they are stored. The colors are stored as their associated .NET color codes, so if you are referencing a custom variable indicator in an expression, it will need to be compared against the color code instead of the name. To determine the color code, use the following formula:

(Hex Code) - 16,777,216 = Color Code

Table of Contents