FX Series Programmable Controlers Applied Instructions 5
5-8
5.1.3 SRET (FNC 02)
Operation:
SRET si
nifies the end of the current subroutine and returns the pro
ram flow to the step
immediatel
followin
the CALL instruction which activated the closin
subroutine.
Points to note:
a) SRET can onl
be used with the CALL instruction.
b) SRET is alwa
s pro
rammed after an FEND instruction - please see the CALL (FNC
01)
instruction for more details.
Mnemonic Function
Operands
Program steps
D
SRET
FNC 02
(
Subroutine
return
Returns operation
from a subroutine
pro
ram
N/A
Automaticall
returns to the step immediatel
followin
the CALL instruction which activated
the subroutine.
SRET:
1 step
Special subroutine timers:
• Because of the chance of intermittent use of the subroutines, if timed functions are
required the timers used must be selected from the ran
e T192 to T199 and T246 to
T249.
Details of usin
CALL with other pro
ram flow instructions
• Further details can be found on pa
es 7-12 and 7-13 about the combined use of different
pro
ram flow techniques (such as master control, MC etc).