EasyManuals Logo
Home>Omron>Controller>CJ - INSTRUCTIONS

Omron CJ - INSTRUCTIONS User Manual

Omron CJ - INSTRUCTIONS
1308 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #310 background imageLoading...
Page #310 background image
3. Instructions
272
CS/CJ/NSJ Series Instructions Reference Manual (W474)
Function
BCMP(068) compares the source data (S) to the 16 ranges defined by pairs of lower and upper limit
values in B through B+31. The first word in each pair (B+2n) provides the lower limit and the second
word (B+2n+1) provides the upper limit of range n (n = 0 to 15). If S is within any of these ranges
(inclusive of the upper and lower limits), the corresponding bit in R is turned ON. If S is out of any these
ranges, the corresponding bit in R is turned OFF.
Example Programming
When CIO 0.00 is ON in the following example, BCMP(068) compares the content of D100 with the 16
ranges defined in D200 through D231 and turns ON the corresponding bits in D300 when S is within the
range or OFF when S is not within the range.
For example, bit 00 of R is turned ON if S is
within the first range (B ≤ S ≤ B+1), bit 01 of R is
turned ON if S is within the second range (B+2
≤ S ≤ B+3), ..., and bit 15 of R is turned ON if S
is within the fifteenth range (B+30 ≤ S ≤ B+31).
All other bits in R are turned OFF.
Note An error will not occur if the lower limit is
greater than the upper limit, but 0 (not
within the range) will be output to the
corresponding bit of R.
B
B+2
B+28
B+30
S
B+1
B+3
B+29
B+31
0
1
14
15
R
Inside the range?
Lower limit value Upper limit value
1 when inside the range
0 when outside of range
Comparison
data
R: D300
S: D100
D100
D200
D300
D201
D203
D205
D207
D209
D211
D213
D215
D217
D219
D221
D223
D225
D227
D229
D231
D200
D202
D204
D206
D208
D210
D212
D214
D216
D218
D220
D222
D224
D226
D228
D230
0.00
to
to
to
to
to
to
to
to
to
to
to
to
to
to
to
to

Table of Contents

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Omron CJ - INSTRUCTIONS and is the answer not in the manual?

Omron CJ - INSTRUCTIONS Specifications

General IconGeneral
BrandOmron
ModelCJ - INSTRUCTIONS
CategoryController
LanguageEnglish

Related product manuals