# Definition of terms for transitions, actions and conditions¶ ## Comments to the picture¶

• Marker 1: Boolean expression in a condition for a Continuous action with assignation condition.
• Marker 2: A Boolean symbol is written by a Stored action on activation.
• Marker 3: An analog symbol is written by a Stored action on activation.
• Marker 4: A BOOL symbol for a Continuous action.

## Write an analog symbol¶

A analog symbol can be written with a Stored action

Notes:

• Arithmetic operations: addition (+), subtraction (-), multiplication (*) and division (/).
• If you divide by zero, the result is set to the maximum value of the data type.

Info

The expression is calculated from left to right. Point-before-bar calculation must be prioritized with brackets.

Examples:

Assignment Remarks
AO0:=100 The value 100 (decimal) is written to the analog symbol AO0.
AO0:=Value1 The value of Value1 is written
AO0:=AO0+1 There is written the result of AO0+1
AO0:=Value1 + Value2 The result of the addition is written
AO0:=Value1 * Value2 The result of the multiplication is written
AO0:=Value1 + Value2 - Value4 etc.
AO0:=Value1 * (Value2 + Value3) etc.
AO0:=Value1 * (Value2 * (Value3*Value4)) / Value5 etc.

## Boolean expression¶

A Boolean expression must be specified in transitions and Action conditions. See marker 1.

Notes:

• Possible binary operations: AND (*), OR (+)
• Modifiers: Rising edge (↑), Falling edge (↓), Negation (!)
• Comparisons can be combined with AND, OR.

Info

A comparison must always be made in square brackets (see examples below).

Info

In the Boolean expression '*' causes a AND operation and a '+' causes a OR operation.

Info

The expression is calculated from left to right. AND- before OR must be prioritized with parentheses

Examples for Boolean expressions:

Boolean expression Comments
I2 Only a boolean symbol is specified.
I0*I1 AND conjunction between two Boolean symbols
I0+I1 OR conjunction between two Boolean symbols
I0*I1*(I2+I3) AND and OR combination with parentheses
(I0*I1)+(I2*I3) The result of two AND conjunctions are OR combined
↑I0 Rising edge of I0
↓I0 Falling edge of I0
!I0 Negated query of I0 (Will be displayed by a horz. line in Grafcet)
↓I0*I1 Falling edge of I0 AND I1
2s/(I0*I1)+I2 If I0 AND I1 are TRUE, a time starts (2 sec.). The expression is TRUE if I2 is TRUE OR the time is expired and I0 and I1 are still TRUE
I0*[Value1>Value2] I0 must be TRUE and Value1 must be greater than Value2. Comparators must be in square brackets.
I0*[Value1>Value2+10] I0 must be TRUE and Value1 must be greater than Value2+10. This example also makes it clear why a comparison must be in square brackets. The plus sign is an addition within the parenthesis and an OR conjunction outside the parenthesis.
[Value1>Value2] * [Value3<Value3] An AND conjunction of two comparators.
[Value1=Value2] Comparison on equal
[Value1!=Value2] Comparison to different
[Value1>Value2] Comparison on bigger
[Value1<Value2] Comparison to less than
[Value1>=Value2] Comparison on greater than or equal to
[Value1<=Value2] Comparison on less than or equal to

## Write a Bool-Symbol¶

A Boolean symbol can be written with a stored action. See marker 2

Syntax:

Bool-Symbol:=Boolean expression

Explanation of Boolean expression (see above).

## Grafcet-Studio and the Standard DIN EN 60848¶

This Grafcet features are not yet supported by Grafcet-Studio:

• ~~Forcing of a partial Grafcet to the current situation (Freeze command)~~
• Edge of a bracket term. Sample: ↑(I0*I1). Edge of operands are possible: ↑I0
• ~~Time limited action: This is not supported !(6s/X28) in a continuous action with condition.~~
• Query of step duration. Example for step "1"="T1" (../See DIN EN 60848)