Sample 1

This example can be used for different RFID readers (Balluff, Baltech, Deister, Leuze, Pepper+Fuchs).

The example is tested with the Balluff BIS M 401 and Leuze electronic RFM32 models.
In the project, an RFID reader was connected to a 1-channel serial EL6001 (on an EK1100). Other serial terminals can also be used. When using KL terminals, the call of the Serial Line Control in the program code must be adapted. (see chapter RFID Reader Connection)
The project can also be used for two RFID readers. The sample program is already prepared for two RFID readers. Only the second linking in the TwinCAT system manager needs to be carried out.

The example project contains the call of the RFID function block with different commands. The most important commands were implemented in this example. This includes, among other things, reading and writing from the RFID transponder memory.
After program start, the appropriate RFID reader manufacturer must be selected via the local enumeration eManufacturer.
The command type can be selected by means of the local enumeration eCommand.
To start the call, the local variable bExecute must be set once to TRUE.
The results of the query are then indicated at the outputs of the RFID function block.
Alternatively, the operation can be done with the visualization integrated in the example:

Sample 1 1:
Sample 1 2:

Depending on the RFID reader model, the GetReaderVersion and GetConfig (if necessary also SetConfig) commands must be executed first, in order to make correct communication with the RFID reader possible.

For further information on the RFID reader communication sequence, please refer to the chapter Handling the RFID function block.

Project Download: TcRFID_Sample01.zip