beautypg.com

Minimizing the scan time – Rockwell Automation 1747-PT1, D1747NP002 Hand-Held Terminal User Manual

Page 81

background image

Chapter 4
Data File Organization and Addressing

4–25

Minimizing the Scan Time

You can keep the processor scan time to a minimum by economizing on the
use of instructions addressing the M0 or M1 files. For example, XIC
instruction M0:2.1/1 is used in rungs 1 and 2 of figure 1 below, adding
approximately 2 ms to the scan time if you are using a Series B processor. In
the equivalent rungs of figure 2, XIC instruction M0:2.1/1 is used only in
rung 1, reducing the scan time by approximately 1 ms.

Figure 1. XIC instructions in rungs 1 and 2 are addressed to the M0 data file.
Each of these instructions adds approximately 1 ms to the scan time (Series
B processor).

Figure 2. These rungs provide equivalent operation to those of figure A by
substituting XIC instruction B3/10 for XIC instruction M0:2.1/1 in rung 2. Scan
time is reduced by approximately 1 ms (Series B processor).

1

] [

B3

12

] [

M0:2.1

1

( )

B3

14

] [

M0:2.1

1

( )

B3

10

2

] [

B3

12

] [

B3

10

( )

B3

14

] [

M0:2.1

1

( )

B3

10

1

2

The following figure illustrates another economizing technique. The COP
instruction addresses an M1 file, adding approximately 4.29 ms to the scan
time if you are using a Series B processor. Scan time economy is realized by
making this rung true only periodically, as determined by clock bit S:4/8
(clock bits are discussed in chapter 27). A rung such as this might be used
when you want to monitor the contents of the M1 file, but monitoring need
not be on a continuous basis.

[OSR]

B11

0

COP

COPY FILE
Source

#M1:4.3

Dest

#N10:0

Length

6

] [

S:4

8

S:4/8 causes the #M1:4.3
file to update the #N10:0 file
every 2.56 seconds.