The Formula Block evaluates a user-defined equation and outputs the result of the evaluation as a True/False, numeric, or an instrument type output. You can also define any number of input ports that can be used in the user-defined equation.
Example Using the Formula Block
To create an equation for the Formula Block:
Double-click the Formula Bock to open its block settings.
In the Formula setting, click Click to edit formula.
Define the inputs to the block. For each input you want to feed into the block:
Drag the Input Connector variable onto the canvas.
In the Add Input dialog, set the Label name for the input, and select the appropriate Input Type.
Drag and arrange the other operators and variables to define the equation's logic. For more information about creating equations, see the Building Formulas topic.
When finished, click OK in the Formula Builder.
Click OK in the Block Settings.
The Formula Block is updated on the canvas to reflect the input ports.
To change default block settings, double-click the block to open the Block Editor.
|Name||Name to display beneath the block on the ADL canvas|
|BodyColor||Background color of the block|
Equation used to calculate the value of the block
If not yet defined, the field displays a Click to edit formula link that opens the Formula Builder.
|Description||Optional text to explain how the block is used|