Repeat/until loop block, 4 repeat/until loop block – Nematron Pointe Controller User Manual

Page 160

Advertising
background image

Chapter 5: Developing Controller Programs

Pointe Controller User Guide

158

5.7.4 Repeat/Until Loop Block

The Repeat/Until Loop block represents a repetitive
process, where the block checks the condition at the
bottom of the loop, ensuring that the chart executes
the sequence of instructions at least once. If the
condition at the bottom of the loop is true, program
flow continues at the next block in the chart. If the

condition is false, control returns to the top of the loop.

PROPERTY

WHAT YOU ENTER

Caption

User label for the block.

Line Labels

Until/Done/Repeat or Until/On/Off as the labels for the block and

outgoing flowlines.

Yield

Yes or No to specify whether, when the condition tests false,
program flow should immediately return to top of the loop or
yield to the next listed Flow Chart. Use this option with caution,
since it essentially disables all other charts while the program
executes the loop.

A block that yields (Yes) runs all other charts in your

Chart List

,

then returns to the top of the loop that yielded and retests the
block’s condition. A block that does not yield (No) continues to
check the condition, uninterrupted.

Condition Type

Type of Condition:

Expression – Build a conditional expression using the

Build Condition

dialog.

Diag Fault Bit Test – Select an Input, Memory, or Output
tag and test to see if its

Diag Fault Bit

is set or clear.

If the condition evaluates true, then the Done/On line is followed.
If the condition evaluates false, then the Repeat/Off line is
followed.

Repeat/Until Loop Block Example

Before reaching this decision block, the program increments the value of Input_2.
The decision block then determines if Input_2 is greater than or equal to 20. If

Advertising