Rslogix 5000 code examples – Rockwell Automation 56RF RFID System User Manual User Manual

Page 67

Advertising
background image

Rockwell Automation Publication 56RF-UM001A-EN-P - October 2011

67

Chapter

9

RSLogix 5000 Code Examples

This chapter contains examples of routines that will run in RSLogix 5000.

The examples are written for an RF transceiver connected to the “0” connector
on the RF interface block. A momentary switch is connected to the Digital Input
connector. The switch is used to enable the routine to allow the user to repeat the
routine easily.

In the examples, the RFID block is identified as “_RFID1”

Main Routine

A partial listing of the Main Routine is shown below. The Main Routine sets the
run bit. In program mode, the run bit is 0; and 1 for run mode. The remaining
blocks jump to the various subroutines to execute the commands. In Rung 1, the
momentary switch turns on Digital Output 0, which turns on an LED to confirm
that the user has pressed the momentary switch.

Advertising