225
High-speed Counters
Section 5-2
Set the target values so that they do not occur at the peak or trough of count
value changes.
Range Comparison
The specified interrupt task is executed when the high-speed counter PV is
within the range defined by the upper and lower limit values.
• The comparison conditions (upper and lower limits of the range) are regis-
tered in the comparison table along with the corresponding interrupt task
number. The specified interrupt task will be executed once when the high-
speed counter PV is in the range (Lower limit
≤
PV
≤
Upper limit).
• A total of 8 ranges (upper and lower limits) are registered in the compari-
son table.
• The ranges can overlap.
• A different interrupt task can be registered for each range.
• The counter PV is compared with the 8 ranges once each cycle.
• The interrupt task is executed just once when the comparison condition
goes from unmet to met.
Restrictions
When more than one comparison condition is met in a cycle, the first interrupt
task in the table will be executed in that cycle. The next interrupt task in the
table will be executed in the next cycle.
Note
(1) The range comparison table can be used without starting an interrupt
task when the comparison condition is met. The range comparison func-
tion can be useful when you just want to know whether or not the high-
speed counter PV is within a particular range.
Use the Range Comparison Condition Met Flags to determine whtether
the high-speed counter PV is within a registered range.
(2) When the count direction (incrementing/decrementing) changes at a PV
that matches a target value, or when starting the target value comparison
at a PV that matches a target value, the next target value cannot be
matched in that direction.
Set the target values so that they do not occur at the peak or trough of
count value changes.
Target value 1
Target value 2
Target value 1
Target value 2
Match not recognized.
Match
Match
Match
No. 255
No. 000
No. 000
No. 255
High-speed counter PV
Comparison is executed
without regard to the
order of the ranges in
the table.
Upper limit 1
Lower limit 1
Upper limit 2
Lower limit 2
Interrupt task that is started.
Time
Comparison table
Upper limit 1
Lower limit 1
Interrupt task = 000
Upper limit 2
Lower limit 2
Interrupt task = 255
Summary of Contents for CP1H CPU UNITS - PROGRAMMING 05-2007
Page 2: ......
Page 3: ...CP1H X40D CP1H XA40D CP1H Y20DT D CP1H CPU Unit Operation Manual Revised March 2009...
Page 4: ...iv...
Page 10: ...x...
Page 18: ...xviii...
Page 22: ...xxii...
Page 34: ...xxxiv Conformance to EC Directives 6...
Page 174: ...140 CP series Expansion I O Unit Wiring Section 3 6...
Page 370: ...336 Analog I O XA CPU Units Section 5 5...
Page 552: ...518 Trouble Shooting Section 8 7...
Page 595: ...561 Sample Application Section 9 12 Network Settings Network Tab Network Settings Driver Tab...
Page 598: ...564 Sample Application Section 9 12...
Page 642: ...608 Standard Models Appendix A...
Page 652: ...618 Dimensions Diagrams Appendix B...
Page 745: ...711 Connections to Serial Communications Option Boards Appendix F Connecting to Unit...
Page 746: ...712 Connections to Serial Communications Option Boards Appendix F...
Page 776: ...742 PLC Setup Appendix G...
Page 778: ...744 Specifications for External Power Supply Expansion Appendix H...
Page 786: ...752 Revision History...