Omron SYSMAC CS Series Instruction & Reference Manual page 540

Hide thumbs Also See for SYSMAC CS Series:
Table of Contents

Advertisement

3. Instructions
Hint
• When bit 15 of C+1 has been set to 1, the data within the range is treated as signed binary data and
hexadecimal values 8000 to FFFF are considered negative. Thus, the results of the search will differ
depending on the data-type setting.
• MAX(182)/MIN(183) can be processed in the background. Refer to the SYSMAC CS/CJ/NSJ Series
PLC Programming Manual (W394) or the CJ2 CPU Unit Software Operation Manual (W473) for
details.
 MAX
If background execution is enabled in the PLC Setup, the PLC memory address of the word containing
the maximum value will be output to Auxiliary Area words A595 and A596 instead of IR0.
 MIN
If background execution is enabled in the PLC Setup, the PLC memory address of the word containing
the minimum value will be output to Auxiliary Area words A595 and A596 instead of IR0.
Example Programming
 MAX
When CIO 0.00 turns ON in the following example, MAX(182) searches the 10-word range beginning at
D200 for the maximum value. The maximum value is written to D300 and the PLC memory address of
the word containing the maximum value is written to IR0.
0.00
R1
506
D100
D200
C: D100
D300
C+1: D101
R1:
D200
PC memory
D201
address
100CA
D202
D203
D204
D205
D206
D207
D208
D209
0
0
0
A
Number of words
1
Always 0.
1: Outputs address to IR0.
1: Treats data as signed binary.
CS/CJ/NSJ Series Instructions Reference Manual (W474)
10 words
Decimal
equivalent
Max. value
–2
–1
–3
D: D300
IR0
000100CA

Advertisement

Table of Contents
loading

Table of Contents