EasyManuals Logo
Home>Allen-Bradley>Controller>Logix5000

Allen-Bradley Logix5000 Reference Manual

Allen-Bradley Logix5000
708 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #490 background imageLoading...
Page #490 background image
490 Rockwell Automation Publication 1756-RM003N-EN-P - October 2011
Chapter 12 For/Break Instructions (FOR, FOR...DO, BRK, EXIT, RET)
Return (RET)
The RET instruction returns to the calling FOR instruction.
Operands:
Relay Ladder
None
Description:
When enabled, the RET instruction returns to the FOR instruction. The FOR
instruction increments the Index value by the Step size and executes the
subroutine again. If the Index value exceeds the Terminal value, the FOR
instruction completes and execution moves on to the instruction that follows the
FOR instruction.
The FOR instruction does not use parameters. The FOR instruction ignores any
parameters you enter in a RET instruction.
You could also use a TND instruction to end execution of a subroutine.
Arithmetic Status Flags: Not affected
Fault Conditions:
Execution:
IMPORTANT
Do not place a RET instruction in the main routine. If you place a RET
instruction in the main routine, a major fault occurs
(type 4, code 31).
A major fault will occur if Fault type Fault code
Main routine contains a RET instruction 4 31
Condition: Relay Ladder Action
Prescan The rung-condition-out is set to false.
Rung-condition-in is false The rung-condition-out is set to false.
Rung-condition-in is true Returns the specified parameters to the calling routine.
The rung-condition-out is set to true.
Postscan The rung-condition-out is set to false.

Table of Contents

Other manuals for Allen-Bradley Logix5000

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Allen-Bradley Logix5000 and is the answer not in the manual?

Allen-Bradley Logix5000 Specifications

General IconGeneral
BrandAllen-Bradley
ModelLogix5000
CategoryController
LanguageEnglish

Related product manuals