beautypg.com

Rockwell Automation 1785-Lx0C15 ControlNet PLC-5 Programmable Controllers User Manual User Manual

Page 48

background image

1785-UM022C-EN-P - February 2008

2-10

Planning to Use Your ControlNet PLC-5 Processor

You enable process control sample complete on a per connection
basis by setting the PCSC enable bit in the connection’s ControlNet
I/O status file entry.

When process control sample complete is enabled for a connection
and the processor is in RUN mode, newly received data for that
connection is immediately copied into your data table (even if the
processor is in the middle of a program scan) and the PCSC new data
bit is set in the connection’s ControlNet I/O status file entry. This data
will not be updated again during a program scan until you clear the
PCSC new data bit. The data is updated during housekeeping,
regardless of the state of the new data bit.

If new data is received and the PCSC new data bit is already set, then
the PCSC overflow bit is set. In this event, your data table will not be
updated. Process control sample complete uses bits 2, 3, and 4 of the
first word of the ControlNet I/O status file entry. See Appendix D for
more information about the ControlNet I/O status file.

The input data must be mapped into the DIF. PCSC is not enabled if
the input data is mapped into the discrete input image table.

0

00

01

02

0

03

04

05

0

06

07

08

0

09

10

11

12

0

13

14

15

First Word

PCSC Overflow Bit

PCSC New Data Bit

PCSC Enable Bit

Bit

Description

2—PCSC Enable

When this bit is set, the processor updates your ControlNet data input file when new data is received. Process
control sample complete can be dynamically enabled and disabled by your program during a program scan. This can
be done by setting and clearing the PCSC enable bit of the connection’s entry in the ControlNet status file. After this
bit has been set, the input data should not be read until the PCSC new data bit has been set by the processor.

3—PCSC New Data

This bit is set by the processor when the PCSC enable bit is set to one and new data has been copied to the
ControlNet data input file. To insure that you do not access this data while the processor is copying new data to the
data input file, do not access the data until the PCSC new data bit has been set by the system.
When this bit is set to one, it signifies that new data has been received and it is safe to read from your ControlNet
data input file. This data is not updated again until you clear this bit or until housekeeping occurs between program
scans.
Never set this bit to one.

4—PCSC Overflow

This bit indicates that your program is not checking the PCSC new data bit often enough to use all processor control
sample complete data that has arrived. If the PCSC new data bit has not been cleared by the time a new data sample
arrives, the PCSC overflow bit is set and the new data is not copied to the ControlNet data input file.
You must clear this bit. If you clear the PCSC New Data bit but not the PCSC overflow bit, the ControlNet data input
file is still updated when the next process control sample complete data is received.
Never set this bit to one.