Process interfacing via an automation system (PLC, PC)
10.9 Sample programs
10.9
Sample programs
10.9.1
Introduction
Examples
● Example 1: Program for interfacing the reader with a SIMATIC controller using FB79
● Example 2: Program for archiving diagnostic information on a PC/PG
10.9.2
Example 1: Program for interfacing the reader with a SIMATIC controller using
FB79
You will find the program described here on the manual/commissioning CD in
Examples\SIMATIC.
Including FB79 in a STEP 7 program
In the accompanying STEP 7 program, the FC1 function contains a simple example for
outputting the result string. You can execute a program change using the FC2 function.
When supplied, only FC1 is called in OB1. To activate FC2, you will need to either delete the
first network with the FC1 call or skip it.
Note
You may only assign the value W#16#0081 for the COMMAND parameter (output result
string) when bit 2 (corresponds to the RDY signal) is set to TRUE in the status byte.
Otherwise the "Illegal mode" error will result.
Process interfacing
The reader is connected with a programmable logic controller via PROFINET IO. A light
barrier or a Bero is used additionally for triggering and must be read in via a digital input
module. The received data is stored in data block DB48 in bytes 0 to 500.
330
SIMATIC MV420 / SIMATIC MV440
Operating Instructions, 04/2013, A5E02371045-06