beautypg.com

Program for the master (device 1, pico-link id 1) – Rockwell Automation 1760 Pico GFX-70 Controllers Quick Start User Manual

Page 50

background image

Publication 1760-QS002A-EN-P - April 2004

7-8 Lesson 5

Activating P Buttons

We have previously implemented the reading of the P buttons on device 2. We
must now further process the information obtained, i.e. the pressing of the P1
button is incremented and the counter state is reset to zero using P2. We wish
to assign the logical processing of the data in our example to the master. As we
are now in the Project View we can double-click Device 1 (Pico-Link ID 1) to
activate circuit diagram entry for the master.

Once in Circuit Diagram View, we can start directly with the reading of the
data sent from Device 2. This is implemented using the RN operand (bit input
via the bus). The operand 2RN1 reads the sent value from 1SN1 (Pico-Link
ID 2) and passes it on to a counter function block C1. Similarly, we read the
second value sent from Device 2 (Pico-Link ID 2). 2RN2 is used for resetting
the counter function block C1 to zero.

In conclusion, we can say that 2RN1 reflects the status of button P1 and 2RN2
the status of P2 of device 2.

Program for the Master (Device 1, Pico-Link ID 1)

Reading of bit values via the bus.

The RN operands must be set as follows