Rockwell Automation Publication 56RF-UM001A-EN-P - October 2011
69
RSLogix 5000 Code Examples
Chapter 9
Rung 2
Start – With the output channel properly initialized, the Start bit enables the
rung to begin execution.
EQU RFID_1:I:Command[0].Command =0 – When an output command is
updated, the interface block returns that command back to the input command.
If the input command is zero (it was set in Rung 1), then the EQU output goes
HI and enables the subsequent MOV command.
MOV x to RFID_1:O:Command[0].Command – Moving a non-zero value into
the output command byte instructs the RFID block to execute the command.
Rung 3
Rung 3 ensures that another command is not initiated while a command is busy.
Start – The Start bit enables the rung to begin execution.
RFID_1:I:Channel[0].Busy – When the command begins execution, the Busy
bit goes HI. This contact closes and the rung is executed.
InProgress – When command begins execution, an In-Progress bit is latched ON.
Start – This contact is opened, as the command has transitioned from start to
busy.
Rung 4
Rung 4 confirms the completion of the command, as the interface block moves a
value into the input channel command location.
InProgress – This contact closes when the read command begins execution.
RFID_1:I:Channel[0].Busy – This contact will be open while the command is in
process.
EQU RFID_1:I:Channel[0].Command = Upon completion of the command
the interface block copies the value from output command to the input
command. If the input command value equals the value of the command, the
EQU output goes HI.
InProgress – This bit is unlatched when the command is successfully completed.
The routine is now ready for the next RFID tag or other routine.