EasyManua.ls Logo

Allen-Bradley ClutchBrake PLC-5 Series - How Subroutines Are Scanned

Allen-Bradley ClutchBrake PLC-5 Series
195 pages
Print Icon
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
Programming Considerations for PLC-5 Processors F–7
Publication
65566.5.1 - October 1996
How Subroutines Are Scanned
Subroutines are accessed from your main program file or from other
subroutines (nested) by means of these instructions (Figure F.2):
Jump To Subroutine (JSR) – located anywhere in your ladder logic
Subroutine (SBR) – the first instruction in the subroutine file and
the target of the JSR instruction (directs the processor scan to the
subject subroutine)
Return (RET) – returns the processor scan to the rung
immediately following the originating JSR instruction
Figure F.2
Program
Scan for an Example Jump to Subroutine and Return
SBR
] [ ] [
] [
( )
] [ ] [
( )
] [
( )
] [ ] [
( )
RET
Main Program or Subroutine
JSR
to SBRn
T
arget Subroutine
] [
( )
] [ ] [
( )
] [ ] [
] [ ] [
( )
] [
Program
Scan
] [
( )
] [ ] [
End
n

Table of Contents

Related product manuals