EasyManuals Logo

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 #457 background imageLoading...
Page #457 background image
Rockwell Automation Publication 1756-RM003N-EN-P - October 2011 457
Program Control Instructions (JMP, LBL, JSR, RET, SBR, JXR, TND, MCR, UID, UIE, AFI, NOP, EOT, SFP, SFR, EVENT) Chapter 11
There are no restrictions, other than controller memory, on the number of nested
routines you can have or the number of parameters you pass or return.
Arithmetic Status Flags: Arithmetic status flags are affected.
Fault Conditions:
Execution:
Relay Ladder and Structured Text
Main Routine
Level 1
subroutine action_1
Level 3
subroutine action_3
Level 2
subroutine action_2
JSRJSR
JSR
SBRSBRSBR
RETRETRET
action_1
action_2 action_3
A Major Fault Will Occur If Fault Type Fault Code
JSR instruction has fewer input parameters than SBR instruction 4 31
JSR instruction jumps to a fault routine 4 or user-supplied 0 or user-supplied
RET instruction has fewer return parameters than JSR instruction 4 31
Main routine contains a RET instruction 4 31
Condition Relay Ladder Action Structured Text Action
Prescan The controller executes all subroutines regardless of rung condition. To ensure that all rungs in the subroutine are
prescanned, the controller ignores RET instructions. (that is, RET instructions do not exit the subroutine.)
· Release 6.x and earlier, input and return parameters are passed.
· Release 7.x and later, input and return parameters are not passed.
If recursive calls exist to the same subroutine, the subroutine is prescanned only the first time. If multiple calls exist
(non-recursive) to the same subroutine, the subroutine is prescanned each time.
The rung-condition-out is set to false (relay ladder only).
Rung-condition-in is false to
the JSR instruction
The subroutine does not execute.
Outputs in the subroutine remain in their last state.
The rung-condition-out is set to false.
N/A
Rung-condition-in is true The instruction executes.
The rung-condition-out is set to true.
N/A
EnableIn is set N/A EnableIn is always set.
The instruction executes.

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