34
Rockwell Automation Publication 2080-UM004C-EN-E - March 2015
Appendix 4
High Speed Counter – 2080-MOT-HSC
Per Pulse
The Per Pulse rate method can be very accurate if the time between pulses is large
compared to the timer clock (1
μ
s for 2080-MOT-HSC). A timer is used to
measure the time between the two successive pulses. This value is reported to the
backplane as HSC_PULSE_WIDTH_Bn after each pulse. The user may invert
this value to derive a rate.
Per Pulse rate = 1 / HSC_PULSE_WIDTH_B
However, when the time between pulses shrinks, two factors can distort the Per
Pulse calculation of rate values:
•
The time between pulses is closer to measuring the clock’s frequency,
making the granularity of the time increments have a greater effect on rate
inaccuracy.
•
Also, the rate may be calculated many times over during the course of one
backplane scan time. This means that the rate data is obtained at a
backplane scan is only that of the very last pair of pulses and disregards the
other rate calculations that have happened during that interval. This is
especially problematic if the pulses during the update time are unevenly
spaced, the reported rate could be based entirely on two pulses which are
extremely close together (a very high rate) but a third pulse was separated
by a greater time (low rate).
You must understand these limitations when using HSC_PULSE_WIDTH_Bn
to derive a rate.
1 ms
1 ms
1 ms
1
2
3
4
1
2
1000 Hz
2000 Hz
1
1000 Hz
PresentCount_n
⌂
Count
PresentRate_n
0
Per Pulse Errors
(1)
Real pulses
(note 1.9999 can
be rounded to 2)
Pulses
reported by
module
Real
Frequency
Reported
Frequency
% Error
2
1
500 kHz
1 MHz
100%
9
10
111 kHz
100 kHz
11.1%
101
100
9.901 kHz
10.000 kHz
1.00%