Special Data - Omron CJ1W-CT021 Operation Manual

High-speed counter units
Hide thumbs Also See for CJ1W-CT021:
Table of Contents

Advertisement

Supported IOWR/IORD-Instructions
4-5-3

Special data

4-5-3-1
Captured Counter Value
Item
Captured Counter Value
4-5-3-2
Rate History Log File data
The Counter Value can be captured into the Capture Register by using a Digital
Input (Function 07 or 08) or by using the "Capture Counter Value bit" in CIO (refer
to 3-4 "Digital Input Functions" for more information). For this purpose every
Counter is equipped with a Capture Register inside the High-speed Counter Unit.
If you want to use the captured Counter Value in the PLC ladder program you have
to use the IORD-instruction that reads the value from the Capture Register of the
specific Counter.
c = Counter Number (1 or 2)
Example:
The High-speed Counter Unit is assigned Machine Number 8. You want to read
the Captured Counter Value of Counter 1 and write it to D0300 in the PLC mem-
ory.
IORD(222)
#1C02
#00020008
D0300
Note
Reading the Captured Counter Value with IORD is also supported for Simple
Counters (refer to 3-2-1 "Simple Counter").
The Rate History Log File, inside the Unit, contains up to a maximum of 64 most
recent Rate Values. If you want to use one or multiple Rate Values from the Rate
History Log File in the PLC ladder program, you have to use an IORD-instruction.
The IORD-instruction returns the specified number of Rate Values starting from
the youngest Rate Value.
Oldest Rate Value
Youngest Rate Value
IOWR
IORD
N
Y
CC1= 1C (= Counter 1), CC2= 02
S= #0008 (Machine Number) and S+1= #0002 (# words)
D= D0300 (write Captured Counter Value to D0300 and
D0301)
Rate History Log F ile:
Rate Value 1
Rate Value 2
Rate Value 3
Rate V alue R
(The Rate Values occupy 2 words each)
Control Code
CC1
CC2
cC
02
R <= 64
Section 4-5
No. of
Words
2
125

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents