Mitsubishi Electric MELSEC iQ-R Series Programming Manual page 913

Hide thumbs Also See for MELSEC iQ-R Series:
Table of Contents

Advertisement

Processing details
• These instructions search the same data as the 16-bit binary data of (s2) in (n) data starting from (s1), and store the search
result in (d) to (d)+4.
• When the same data exists, five devices starting from (d) store the number of the same data, first and last positions of the
same data, maximum value position, and minimum value position.
• When the same data does not exist, five devices starting from (d) store the number of the same data, first and last positions
of the same data, maximum value position, and minimum value position. In this case, however, 0s are stored in three
devices starting from (d) (which store the number of the same data, first and last positions of the same data).
• When there are two or more maximum or minimum values in the searched data, the last position of the maximum/minimum
values is stored.
• If the value specified in (n) is 0, no processing is performed.
• The following table shows example of configuration of search result table and data. (n=10)
Searched device
Searched data
(s1)
(s1) value
(example)
(s1)
100
(s1)+1
111
(s1)+2
100
(s1)+3
98
(s1)+4
123
(s1)+5
66
(s1)+6
100
(s1)+7
95
(s1)+8
210
(s1)+9
88
• The following table shows the search result table obtained by the above example.
Device number
(d)
(d)+1
(d)+2
(d)+3
(d)+4
Operation error
There is no operation error.
Comparison data
Data position
(s2) value
(example)
100
0
1
2
3
4
5
6
7
8
9
Description
3
0
6
5
8
Search result
Maximum value
Match (d)
(d)+4
 (First position)
 (Last position)
Search result item
Number of the same data
Position of the same data (first position)
Position of the same data (last position)
Minimum value position (last position)
Maximum value position (last position)
7 APPLICATION INSTRUCTIONS
7.20 Data Processing Instructions
Minimum value
(d)+3
7
911

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents