320 Rockwell Automation Publication 2198-UM004A-EN-P - October 2019
Chapter 12 Motion Control Applications
Figure 145 - PR Command with Application of High-speed Capture (DI9 example)
Figure 146 shows how the data is captured in the data array when the capture
function is executed. At (1) after DI9 is triggered, the capturing axis is reset to 0
and the data is stored in data array #100 because the reset function of the first
point is enabled and ID368 (P5.076) DI9FirstCaptureResetPosition is set to 0.
At the moment DI9 is triggered the second (2) and third (3) times, the position
data is written to the data arrays #101 and #102, respectively. Once the first
capture cycle is completed, the DO:CAP_OK [0x16] signal turns on and then
PR#50 (high speed position capture command) and PR#51 (motion with fixed
speed) are executed. The servo drive will execute the next cycle. The
DO:CAP_OK signal is off when procedure is completed and the capturing
amount is set to 3.
When DI9 is triggered for the fourth (1) time, the capture axis' position is not
reset and the position data of the capturing axis is written to data array #100
again. Therefore, the data written in the previous cycle is replaced. At the
moment DI9 is triggered for the fifth and sixth times, the position of capturing
axis is written to data arrays #101 and #102, respectively. As soon as the second
capture cycle is finished, DO:CAP_OK [0x16] CAP turns on and then PR#50
(high speed position capture command) and PR#51 (motion with fixed speed)
are executed.
When applying cyclic capture mode (P1.019.X = 1), the reset function is only
valid for the first cycle. Every time a cycle ends, PR#50 is executed. The first
position data that is captured in every cycle is written to the data array set by
ID328 (P5.036) NAME and then other data is written in sequence. Position data
written in the previous cycle will always be replaced by that of the next cycle.
PR#1 (I)
Write
DLY=[0] 0 ms
P5.039=0x2030
PR#3 (I)
Write
DLY=[0] 0 ms
P5.038=3
PR#4 (I)
Write
DLY=[0] 0 ms
P5.076=0
PR#2 (I)
Write
DLY=[0] 0 ms
P5.036=100
PR#50 (I)
Position
DLY=[0] 0 ms
50000 PUU
CAP
100rpm
PR#7 (I)
Speed
DLY=[0] 0 ms
50 rpm
Acc=[0] 3.33 ms
Dec=[0] 3.33 ms
PR#6 (I)
Write
DLY=[0] 0 ms
P5.039=0x203B
PR#5 (I)
Write
DLY=[10] 1 ms
P1.019=0x0001
PR#51
Speed
DLY=[0] 0 ms
50 rpm
Acc=[0] 3.33 ms
Dec=[0] 3.33 ms