675
Subroutines Section 3-18
Variations
Applicable Program Areas
Operands N: Subroutine number
Specifies the subroutine number between 0 and 255 decimal.
Operand Specifications
Description MCRO(099) calls the subroutine with the specified subroutine number just like
SBS(091). Unlike SBS(091), MCRO(099) operands S and D can be used to
change bit and word addresses in the subroutine, although the structure of
the subroutine is constant.
When MCRO(099) is executed, the contents of S through S+3 are copied to
A600 through A603 (macro area inputs) and the specified subroutine is exe-
cuted. When the subroutine is completed, the contents of A604 through A607
(macro area outputs) are copied to D through D+3 and program execution
continues with the next instruction after MCRO(099).
Variations Executed Each Cycle for ON Condition MCRO(099)
Executed Once for Upward Differentiation @MCRO(099)
Executed Once for Downward Differentiation Not supported
Immediate Refreshing Specification Not supported
Block program areas Step program areas Subroutines Interrupt tasks
OK OK OK OK
Area N S D
CIO Area --- CIO 0 to CIO 6140
Work Area --- W0 to W508
Holding Bit Area --- H0 to H508
Auxiliary Bit Area --- A0 to A444
A448 to A956
A448 to A956
Timer Area --- T0000 to T4092
Counter Area --- C0000 to C4092
DM Area --- D0 to D32764
Indirect DM addresses
in binary
--- @ D0 to @ D32767
Indirect DM addresses
in BCD
--- *D0 to *D32767
Constants 0 to 255 (decimal) ---
Data Registers ---
Index Registers ---
Indirect addressing
using Index Registers
--- ,IR0 to ,IR15
–2048 to +2047,IR0 to –2048 to
+2047,IR15
DR0 to DR15,IR0 to IR15
,IR0+(++) to ,IR15+(++)
,–(– –)IR0 to ,–(– –)IR15