description addon instructions “dte102 configuration ... · description addon instructions...

31
1 Description AddOn Instructions “DTE102_Configuration” “INACTIVE” “INPUT” “OUTPUT” “RWH_RW” DTE102 connected to Allen Bradley CompactLogix L32E revision 19.11 via the integrated Ethernet/IP interface of the CPU

Upload: trinhtu

Post on 20-Jan-2019

269 views

Category:

Documents


0 download

TRANSCRIPT

1

   

Description

AddOn Instructions

“DTE102_Configuration” “INACTIVE”

“INPUT” “OUTPUT”

“RWH_RW”

DTE102 connected to Allen Bradley CompactLogix L32E revision 19.11

via the integrated Ethernet/IP interface of the CPU

2

Table of contents 1. Preliminary note .......................................................................................................................................................... 3 2. General ........................................................................................................................................................................ 3 3. Installation ................................................................................................................................................................... 4

3.1 Setting the process interface of the DTE102 evaluation unit .............................................................................. 4 4. Configure the connection to the DTE102 evaluation unit in the RSLogix 5000 software ........................................... 5

4.1 Hardware configuration of the CompactLogix station ........................................................................................ 5 5. Import the AddOn functions to a project .................................................................................................................... 9

5.1 Integrate the AddOn instructions in the PLC program ...................................................................................... 12 6. Send the configuration data to the DTE102 evaluation unit .................................................................................... 14 7. Description of the DTE102_Configuration Instruction .............................................................................................. 16

7.1 General .............................................................................................................................................................. 16 7.2 Handling ............................................................................................................................................................ 17

7.2.1 Valid parameter numbers for iiFunctionCh1-4 ......................................................................................... 18 7.2.2 Valid parameter numbers for iiTDBLCh1-4: .............................................................................................. 18 7.2.3 Value for iiDataHoldTimeCh1-4 for use of RWH_RW AOI: ...................................................................... 18

8. Description of INACTIVE AOI ......................................................................................................................... 19 8.1 General ............................................................................................................................................... 19 8.2 Parameter description .......................................................................................................................... 19 8.3 Handling .............................................................................................................................................. 20

9. Description of INPUT AOI ............................................................................................................................. 20 9.1 General ............................................................................................................................................... 20 9.2 Parameter description .......................................................................................................................... 21 9.3 Handling .............................................................................................................................................. 21

10. Description of OUTPUT AOI .......................................................................................................................... 22 10.1 General ............................................................................................................................................... 22 10.2 Parameter description .......................................................................................................................... 23 10.3 Handling .............................................................................................................................................. 23

11. Description of RWH_RW AddOn Instruction .................................................................................................. 24 11.1 General ............................................................................................................................................... 24 11.2 Parameter description .......................................................................................................................... 25 11.3 Build-up of the communication ............................................................................................................. 27 11.4 Command processing ........................................................................................................................... 27

11.4.1 Read the UID of the tag ................................................................................................................. 29 11.4.2 Read an area of the USER memory of the tag ................................................................................. 29 11.4.3 Write an area of the USER memory of the tag ................................................................................. 29 11.4.4 Displays at the owStatus output parameter .................................................................................... 30

3

1. Preliminary note

These instructions

help to establish the communication between an RFID DTE102 evaluation unit and an Allen Bradley CompactLogix controller via the integrated Ethernet interface of the CompactLogix CPU

describe the use of the AddOn functions DTE102_Configuration, DTE102_ReadWrite, DTE102_Input and DTE102_Output in the RSLogix 5000 program.

2. General

The AddOn instructions permit easy configuration of each of the 4 channels of DTE102 in the RSLogix5000 program via the PLC software, i.e. to configure the channels as RWH_RW, input, output or as inactive. The following functions, depending on the channel setting, are supported by the respective AddOn instructions (AOI):

INACTIVE:

Read the diagnostic data of the channel in the evaluation unit

INPUT:

Read the digital signals on the C/Qi input

Read the digital signals on the I/Q input

Monitor the load at the L+ connection of the port

Read the diagnostic data of the channel of the evaluation unit

OUTPUT:

Control the digital signal on the C/Qo output

Read the digital signals on the I/Q input

Activate the increased current supply of the C/Qo port (only available for channels 3 and 4)

Monitor the load at the L+ connection of the port

Read the diagnostic data of the channel of the evaluation unit

RWH_RW:

Detect the presence of a tag

Read the UID of a tag

Read the USER memory from a tag

Describe the area of the USER memory of a tag

Switch the antenna off and on

Read the diagnostic data of the channel of the evaluation unit

4

3. Installation

3.1 Setting the process interface of the DTE102 evaluation unit

Figure 1 As a standard the DTE102 evaluation unit is configured with the IP address 192.168.0.79 and the subnet mask 255.255.255.0.

By entering the IP address in the internet explorer you get to the web interface surface to configure the network settings.

The change in the network settings must be confirmed by pressing the [submit] button.

5

4. Configure the connection to the DTE102 evaluation unit in the RSLogix 5000 software

This part of the description refers to the RSLogix software version V19.01.00 (CPR 9 SR 3).

4.1 Hardware configuration of the CompactLogix station

Figure 2

Right click on Ethernet Port LocalENB Click on New Module…

6

Figure 3

A double click on Communications opens the selection window for the communication module (Figure 4)

Figure 4

Select Generic Ethernet Module from the list and confirm with [OK]

7

Figure 5

Enter DTE102 as the name of the module (name is freely selectable) Set Comm format to Data - SINT Set the IP address of DTE102 Set Connection Parameters as shown in Figure 5 Confirm with [Apply]

Figure 6

Set the RPI time to 10 ms in the Connection tab. If the value set here is too low, this can lead to communication problems.

Click on [OK] to finish the module settings

8

Figure 7

The RSLogic software automatically creates new controller tags. They are required as input and output variables (tags) for the AddOn instructions

9

5. Import the AddOn functions to a project

Figure 8

Right click on AddOn Instructions and select Import AddOn Instruction...

Figure 9

Select the XXXX.L5X file from the respective path and click on Import

10

Figure 10

Confirm the Import Configuration with [OK] Repeat this for all required AddOn instructions.

o INACTIVE o INPUT o OUTPUT o RWH_RW

11

Figure 11

After successful import the instructions are displayed in the AddOn Instructions folder.

12

5.1 Integrate the AddOn instructions in the PLC program

Here it is described how the AddOn instructions are implemented in the user PLC program.

After the import of the AddOn instructions (functions) they can be integrated into the PLC program as a ladder element.

Figure 12

By pressing the Ins keyboard button, the selection window of the ladder elements opens In the AddOn tab you can find the instructions imported before Select DTE102_Configuration and confirm with [OK]

13

Figure 13

The instruction is integrated in the path (Rung) and can now be configured.

Repeat this process for the instructions required in the program.

o INACTIVE o INPUT o OUTPUT o RWH_RW

14

6. Send the configuration data to the DTE102 evaluation unit

The DTE102_Configuration instruction needs the current status of the Ethernet/IP communication to the DTE102 evaluation unit for the process. This requires the GSV command (Get System Value) from the existing library. The GSV command monitors the status of the configured module and passes the status on to a defined variable as DINT value. The first bit of the DINT variable is used as health bit. If the PLC program is transferred from the programming unit to the PLC, the connection to DTE102 has to be interrupted for a short time to assign the current configuration data. To do so, an SSV (Set System Value) from the existing library is used.

Figure 14

By pressing the Ins keyboard button the selection window for the ladder elements opens Select the GSV/SSV command and confirm with [OK].

15

If the GSV and SSV commands are implemented in the PLC program, they have to be linked logically as illustrated in Figure 15. The requested variables and timers, with the exception of s:fs (first scan), must be newly created.

Figure 15 A double click on the variable to be configured opens a selection window. The following parameters have to be assigned to the GSV and the SSV commands: GSV command:

Class name = Module Instance Name = DTE102 Attribute Name = EntryStatus Dest = DTE102_Status (previously defined variable)

SSV command:

Class name = Module Instance Name = DTE102 Attribute Name = Mode Source = ssv_Value (previously defined variable)

16

Description: After every new start of the PLC the Restart bit is low. This state sends the value 4 to the ssv-Value variable and starts a switch-on delay timer T_Restart. The value of the ssv-Value variable is transferred to the SSV function. This function in turn deactivates the communication to the DTE102 evaluation unit. When the T_Restart time has elapsed, the Restart variable is set. With the set Restart variable the value 0 is loaded into the ssv_Value variable. With this value the SSV function re-establishes the connection to the DTE102 evaluation unit and the DTE102_Configuration AddOn instruction is executed. It now sends the configuration data to the DTE102 evaluation unit.

7. Description of the DTE102_Configuration Instruction

Figure 16

7.1 General

During every new start and a resulting new connection, this instruction transmits the IO port configuration data defined by the user to the DTE102 evaluation unit. This depends on the controller version. Since the controllers with a revision no. < 20 cannot process any EDS files, it is necessary to transmit the configuration data to the DTE102 evaluation unit via PLC program. Each I/O port can be configured as input (parameter: 1), as output (parameter: 2), as ReadWrite (parameter: 3) or as inactive (parameter: 0).

17

Figure 17

Input parameters:

Name Type Description

iarybConfigData SINT[40] Configuration address of the DTE102 evaluation unit (DTE102:C.Data)

iiFunctionCh1 -4 INT Function definition:0 = INACTIVE IO port is deactivated 1 = INPUT reads the binary I/Q input and C/Qi of the IO port 2 = OUTPUT switches the binary "C/Qi" output of the IO port /reads the binary I/Q input of the IP port 3 = RWH_RWread the UID or the user data / write data to the user data zone of the tag

iiTDBLCh1 -4 INT Tag data block length = 4 bytes (possible entry: 1,2,4,8,16,32,64,128,255)

iiDataHoldTimeCh1-4 INT Data hold time channel 1 (input value * 10 ms.)

Table 1 Output parameters:

Name Type Description

oxConfigNoError BOOL high if an invalid function number is entered.

Table 2

7.2 Handling

The parameters of the IO ports have to be set before the transmission of the PLC software to the controller.

If the parameters are changed during the program sequence, malfunctions of the DTE102 evaluation unit may result.

If an invalid parameter number has been entered for iParaCH1 – iParaCh4, the "oxConfigNoError“ output is set to high.

The iiTDBLCh1-4 parameter is selected on the basis of the tags used.

The iiDataHoldTimeCh1-4 parameter defines, how long the data read from the tag is stored in the DTE102 transmission buffer.

18

7.2.1 Valid parameter numbers for iiFunctionCh1-4:

0 = IO port inactive

1 = IO port input

2 = IO port output

3 = IO port ReadWrite

7.2.2 Valid parameter numbers for iiTDBLCh1-4:

Block size [byte]: 1, 2, 4, 8, 16, 32, 64, 128, 256

For the required tag block size see the tag data sheet.

Example E80360:

Figure 18

Example: E80370:

Figure 19

7.2.3 Value for iiDataHoldTimeCh1-4 for use of RWH_RW AOI:

0 RWH_RW AOI keeps the receive data, as long as the ixRead read command is still active. Therefore the DataHoldTime on the configurations AOI has to be set to 0.

19

8. Description of INACTIVE AOI

Figure 20

8.1 General

This function block can be used for a channel of the DTE102 evaluation unit configured as INACTIVE. It provides the function:

Read the diagnostic data of the channel in the evaluation unit

In every PLC cycle, the function block extracts the data of the channel from the input data of the evaluation unit. If a diagnosis event occurs on the channel, the diagnostic data is read automatically and it is displayed on the output parameters. Reading the diagnostic data is asynchronous, i.e. it stretches across several PLC cycles.

8.2 Parameter description

Input parameters:

Name Type Description

iarbDTE102 ANY_ARRAY_BYTE Data field of the inputs of the evaluation unit

iiChannelNo INT Channel number (1..4)

ixConnOK BOOL Ethernet/IP connection to the evaluation unit has been established

ixAckDiag BOOL Delete the displayed diagnostic data

Table 3 Output parameters:

Name Type Description

oarbDTE102 ANY_ARRAY_BYTE Data field of the outputs to the evaluation unit

oiDiagLength INT Number of the entries in the diagnostic data

oardwDiagData ARRAY[0..3] OF DWORD Array with diagnostic data (error codes see device manual DTE102)

Table 4

20

8.3 Handling

The input data of the evaluation unit is provided to the function block at the iarbDTE102 input parameter. The oarbDTE102 output parameter refers to the output data that is transferred to the evaluation unit. The iiChannelNo input parameter determines which channel of the evaluation unit is to be processed. The ixConnOK input parameter signals to the function block that the Ethernet/IP connection to the evaluation unit has been established. Preferably, this input parameter is to be linked to the respective connection bit from the status byte of the GSV command (chapter 6). As long as the ixConnOK input parameter = FALSE, the diagnostic data displayed at the output parameters is initialised with 0. If the signal at the ixConnOK input parameter = TRUE, the function block starts to work. If the evaluation unit signals an error on the configured channel, the function block automatically adds the control signals for reading the diagnostic data to the output data to the evaluation unit. The contained diagnostic data is displayed in the oardwDiagData output parameter. The diagnostic data displayed so far is completely deleted. The oiDiagLength output parameter indicates how many diagnostic data sets are currently displayed. The error codes in the diagnostic data are described in the device manual of the evaluation unit. A rising edge on the ixAckDiag input parameter deletes the displayed diagnostic data.

9. Description of INPUT AOI

Figure 21

9.1 General

This function block can be used for a channel of the DTE102 evaluation unit configured as INPUT. It provides the following functions:

Read the digital signals on the C/Qi input

Read the digital signals on the I/Q input

Monitor the load at the L+ connection of the port

Read the diagnostic data of the channel of the evaluation unit

In every PLC cycle, the function block extracts the data of the channel from the input data of the evaluation unit and provides the data of the digital inputs of the channel at its output parameters. If a diagnosis event occurs on the channel, the diagnostic data is read automatically and it is displayed on the output parameters. Reading the diagnostic data is asynchronous and stretches across several PLC cycles. The cyclic functions of the function block are not affected. If this function block is used for a channel that is not configured as INPUT, this will lead to malfunctions of the function block.

21

9.2 Parameter description

Input parameters:

Name Type Description

iarbDTE102 ANY_ARRAY_BYTE Data field of the inputs of the evaluation unit

iiChannelNo INT Channel number (1..4)

ixConnOK BOOL Ethernet/IP connection to the evaluation unit has been established

ixAckDiag BOOL Delete the displayed diagnostic data

Table 5 Output parameters:

Name Type Description

oarbDTE102 ANY_ARRAY_BYTE Data field of the outputs to the evaluation unit

oxCQi BOOL Status of the digital input at the C/Qi port

oxIQ BOOL Status of the digital input at the I/Q port

oxOverload BOOL Overload of the voltage supply from L+

oiDiagLength INT Number of the entries in the diagnostic data

oardwDiagData ARRAY[0..3] OF DWORD Array with diagnostic data

Table 6

9.3 Handling

The input data of the evaluation unit is provided to the function block at the iarbDTE102 input parameter. The oarbDTE102 output parameter refers to the output data that is transferred to the evaluation unit. The iiChannelNo input parameter determines which channel of the evaluation unit is to be processed. The ixConnOK input parameter signals to the function block that the Ethernet/IP connection to the evaluation unit has been established. Preferably, this input parameter is to be linked to the respective connection bit from the status byte of the GSV command (chapter 6). As long as the ixConnOK input parameter = FALSE, all output parameters are initialised with 0. If the signal at the ixConnOK input parameter = TRUE, the function block starts to work. A channel of the evaluation unit configured as INPUT provides 2 digital inputs. The status of these inputs is displayed at the oxCQi and oxIO output parameters. An overload of the voltage supply from these inputs is signalled at the oxOverload output parameter. If the evaluation unit signals an error on the configured channel, the function block automatically adds the control signals for reading the diagnostic data to the output data to the evaluation unit. The contained diagnostic data is displayed in the oardwDiagData output parameter. The diagnostic data displayed so far is completely deleted. The oiDiagLength output parameter indicates how many diagnostic data sets are currently displayed. The error codes in the diagnostic data are described in the device manual of the evaluation unit. A rising edge on the ixAckDiag input parameter deletes the displayed diagnostic data.

22

10. Description of OUTPUT AOI

Figure 22

10.1 General

This function block can be used for a channel of the DTE102 evaluation unit configured as OUTPUT. It provides the following functions:

Control the digital signal on the C/Qo output

Read the digital signal on the I/Q input

Activate the increased current supply of the C/Qo port (only available for channels 3 and 4)

Monitor the load at the L+ connection of the port

Read the diagnostic data of the channel of the evaluation unit

In every cycle, the function block extracts the data of the channel from the input data of the evaluation unit and provides the data of the digital input of the channel at its output parameters. The signals for the digital output of the channel are added cyclically to the output data to the evaluation unit. If a diagnosis event occurs on the channel, the diagnostic data is read automatically and it is displayed on the output parameters. Reading the diagnostic data is asynchronous and stretches across several PLC cycles. The cyclic functions of the function block are not affected. If this function block is used for a channel that is not configured as OUTPUT, this will lead to malfunctions of the function block.

23

10.2 Parameter description

Input parameters:

Name Type Description

iarbDTE102 ANY_ARRAY_BYTE Data field of the inputs of the evaluation unit

iiChannelNo INT Channel number (1..4)

ixConnOK BOOL Ethernet/IP connection to the evaluation unit has been established

ixCQo BOOL Signal for output on the C/Qo port

ixHighCurrent BOOL Activate the increased voltage supply of the C/Qo port

ixAckDiag BOOL Delete the displayed diagnostic data

Table 7 Output parameters:

Name Type Description

oarbDTE102 ANY_ARRAY_BYTE Data field of the outputs to the evaluation unit

oxIQ BOOL Status of the digital input at the I/Q port

oxOverload BOOL Overload of the voltage supply from L+

oiDiagLength INT Number of the entries in the diagnostic data

oardwDiagData ARRAY[0..3] OF DWORD Array with diagnostic data

Table 8

10.3 Handling

The input data of the evaluation unit is provided to the function block at the iarbDTE102 input parameter. The oarbDTE102 output parameter refers to the output data that is transferred to the evaluation unit. The iiChannelNo input parameter determines which channel of the evaluation unit is to be processed. The ixConnOK input parameter signals to the function block that the Ethernet/IP connection to the evaluation unit has been established. Preferably, this input parameter is to be linked to the respective connection bit status byte of the GSV command (chapter 6). As long as the ixConnOK input parameter = FALSE, all output parameters are initialised with 0. If the signal at the ixConnOK input parameter = TRUE, the function block starts to work. A channel of the evaluation unit configured as OUTPUT provides 1 digital output and 1 digital input. The status of the input is displayed at the oxIO output parameter. The signal at the ixCQo input parameter is entered in the output data to the evaluation unit and controls the digital output of the channel. The signal at the ixHighCurrent input parameter is only considered for channels 3 and 4 and transferred to the evaluation unit. An overload of the voltage supply from the input or the output is signalled at the oxOverload output parameter. If the evaluation unit signals an error on the configured channel, the function block automatically adds the control signals for reading the diagnostic data to the output data to the evaluation unit. The contained diagnostic data is displayed in the oardwDiagData output parameter. The diagnostic data displayed so far is completely deleted. The oiDiagLength output parameter indicates how many diagnostic data sets are currently displayed. The error codes in the diagnostic data are described in the device manual of the evaluation unit.

24

A rising edge on the ixAckDiag input parameter deletes the displayed diagnostic data.

11. Description of RWH_RW AddOn Instruction

Figure 23

11.1 General

This function block can be used for a channel of the DTE102 evaluation unit configured as RWH_RW. The data can be read from a tag or saved on a tag by means of a connected RFID antenna.

If this function block is used, the Data Hold Time parameter must be set to 0 at DTE102_Configuration Instruction (chapter 7) for parameter setting of the channel.

The function block provides the following functions:

Detect the presence of a tag

Read the UID of a tag

Read the USER memory from a tag

Describe the area of the USER memory of a tag

Switch the antenna off and on

Read the diagnostic data of the channel of the evaluation unit

Writing the UID is not possible. The trial is acknowledged with an error message.

25

If this function block is used for a channel that is not configured as RWH_RW, this will lead to malfunctions of the function block. The function block extracts the data of the channel from the input data of the evaluation unit and evaluates it. Control signals for reading or writing a tag are added to the output data to the evaluation unit. If a diagnosis event occurs on the channel, the diagnostic data is read automatically and it is displayed on the output parameters. The communication has to follow a defined process. Figure 24 illustrates this on the basis of a flow chart.

Figure 24 To make command processing more user-friendly, the DTE102_RWH_RW function block was developed. This function block processes the above-mentioned command protocol automatically.

11.2 Parameter description

Input parameters:

Name Type Description

iarbDTE102 SINT[250] Data field of the inputs of the evaluation unit

iiChannelNo INT Channel number (channel 1 .. 4)

ixConnOK BOOL Ethernet/IP connection to the evaluation unit has been established

ixAntOff BOOL Switch off the antenna

ixUserMem BOOL Access to the USER memory of the tag

ixRead BOOL Rising edge starts reading from the tag

ixWrite BOOL Rising edge starts writing to the tag

iiRdWrStartAddr INT Start address in the USER memory of the tag for reading/writing

iiRdWrLength INT Number of bytes to be read/written

iarbSendBuf ANY_ARRAY_BYTE Area with the data to be written

Table 9

26

Output parameters:

Name Type Description

oarbDTE102 SINT[250] Data field of the outputs to the evaluation unit

oxBusy BOOL Function block is busy, no new command possible

oxDone BOOL Function completed without error

oxError BOOL Error detected

owStatus WORD Status information or error code (see chapter 11.4.4)

oiDiagLength INT Number of the entries in the diagnostic data

oardwDiagData ARRAY[0..3] OF DWORD Array with diagnostic data

oxTagPresent BOOL Tag detected

oiRcvdLength INT Number of bytes read

oarbRcvBuf ANY_ARRAY_BYTE Receive buffer for the data read

Table 10

27

11.3 Build-up of the communication

The input data of the evaluation unit is provided to the function block at the iarbDTE102 input parameter; the oarbDTE102 output parameter refers to the output data that is transferred to the evaluation unit. The iiChannelNo input parameter determines which channel of the evaluation unit is to be processed. The ixConnOK input parameter signals to the function block that the Ethernet/IP connection to the evaluation unit has been established. Preferably, this input parameter is to be linked to the respective connection bit status byte of the GSV command (chapter 6). As long as the ixConnOK input parameter = FALSE, the oxBusy = TRUE and owStatus = 0x1000 output parameters are output. All other output parameters are initialised with 0.

Set the ixConnOK input parameter = TRUE: The communication with the configured channel of the evaluation unit is activated. The signals for the data exchange are synchronised.

The ixAntOff input parameter = FALSE activates the antenna

If the data exchange was synchronised and the antenna activated, the oxBusy = FALSE output parameter is output. The function block is now ready for the data exchange with a tag.

ixConnOK

ixAntOff

oxBusy

oxDone

oxError

owStatus 0x1000 0x2*** 0x3000 0x7000

Figure 25

11.4 Command processing

The DTE102_RWH_RW function block is a function block working in an asynchronous way, i.e. processing stretches across several function block calls. The processing state of the function block is displayed on the owStatus output parameter. As long as the connected antenna detects a tag, the oxTagPresent output parameter is set. If the function block displays FALSE at the oxBusy output parameter, it is ready for a new command.

Define via the ixUserMem input parameter, if the USER memory or the UID of the tag should be accessed.

Indicate the USER memory area in the iiRdWrStartAddr and iiRdWrLength input parameters.

A rising edge on the ixRead or ixWrite input parameter starts reading of or writing to the tag. The displayed diagnostic data is deleted and the receive buffer defined at the oarbRcvBuf output parameter is initialised.

During processing the oxBusy output parameter is TRUE. The progress of command processing is displayed in the owStatus output parameter. With completion of the command, the oxBusy = FALSE output parameter is output. The result of processing is indicated in the oxDone and oxError output parameters. It is kept as long as the triggering ixRead or ixWrite input parameter is

28

TRUE, min. however for one PLC cycle. The result is displayed as follows:

No error occurred during processing: oxDone = TRUE oxError = FALSE owStatus = 0x0000 oiRcvdLength = indicates the number of the data read The data read is stored in the receive buffer defined by the oarbRcvBuf output parameter.

Error occurred during processing oxDone = FALSE oxError = TRUE owStatus indicates an error code. The possible error codes are listed in Table 12.

As an example, the signal characteristics are shown in Figure 26.

No error occurred

Error occurred

ixConnOK

ixRead

oxBusy

oxDone

oxError

owStatus

0x7

00

0

0X

7**

*

0x0

00

0

0x7

00

0

0X

7**

*

0x0

00

0

0x7

00

0

0X

7**

*

0x8

***

0x7

00

0

0X

7**

*

0x8

***

0x7

00

0

Figure 26 If the evaluation unit signals an error on the configured channel, the function block automatically adds the control signals for reading the diagnostic data to the output data to the evaluation unit. The contained diagnostic data is displayed in the oardwDiagData output parameter. The diagnostic data displayed so far is completely deleted. The oiDiagLength output parameter indicates how many diagnostic data sets are currently displayed.

29

11.4.1 Read the UID of the tag

Set the ixUserMem input parameter = FALSE

If the antenna detects a tag (oxTagPresent = TRUE), its UID is provided in the receive buffer. The length of the UID is displayed at the oiRcvdLength output parameter. This data is deleted if the tag leaves the antenna field or if the ixUserMem input parameter is set = TRUE.

11.4.2 Read an area of the USER memory of the tag

An area of the USER memory of a tag is read as follows:

Set the ixUserMem input parameter to TRUE

Indicate the address in the USER memory of that tag as from where reading is to be effected at the iiRdWrStartAddr input parameter

Set the number of the bytes to be read at the iiRdWrLength input parameter

The rising edge at the ixRead input parameter adopts the iiRdWrStartAddr and iiRdWrLength input parameters and starts reading from the tag.

The data read by the tag is stored in the receive buffer. If the indicated data length cannot be transferred within one single read cycle, the function block automatically carries out several read cycles with the corresponding address offsets in the source and target buffer. That means that the length of the data to be read is only limited by the receive buffer indicated and the memory of the tag. On completion of the command, the result of processing is displayed (see chapter 11.4). The total length of the data is displayed in the oiRcvdLength output parameter. The data is kept as long as the oxDone output parameter is set.

11.4.3 Write an area of the USER memory of the tag

An area of the USER memory of a tag is written on as follows:

Set the ixUserMem input parameter to TRUE

Enter the data to be written in the send buffer set at the iarbSendBuf output parameter

Indicate the address in the USER memory of that tag as from where the data is to be written at the iiRdWrStartAddr input parameter

Set the number of bytes to be transferred at the iiRdWrLength input parameter

The rising edge at the ixWrite input parameter adopts the iiRdWrStartAddr and iiRdWrLength input parameters and starts writing on the tag memory.

If the indicated data length cannot be transferred within one single write cycle, the function block automatically carries out several write cycles with the corresponding address offsets in the source and target buffer. That means that the length of the data to be written is only limited by the transmit buffer indicated and the memory of the tag.

The data in the send buffer must not be changed while the command is being processed.

On completion of the command, the result of processing is displayed (see chapter 11.4).

30

11.4.4 Displays at the owStatus output parameter

Status displays

owStatus Description

0x0000: Function completed without error

0x1000 Waiting for ixConnOK input parameter = TRUE

0x2000

0x2101 0x2102 0x2103

0x2201 0x2202 0x2203

0x2402 0x2403

Check start-up signals for the data exchange

Activate the start-up of the USER memory mode Synchronise the start-up of "read USER memory" Complete the start-up of "read USER memory"

Activate the start-up of the USER memory mode Synchronise the start-up of "write USER memory" Complete the start-up of "write USER memory"

Synchronise the start-up of "read diagnostic data" Complete the start-up of "read diagnostic data"

0x3000 Wait for ixAntOff input parameter = FALSE

0x7000

0x7101 0x7102 0x7103

0x7201 0x7202 0x7203

0x7301 0x7302 0x7303

0x7401 0x7402 0x7403

Wait for the start of a command

Activate the USER memory mode Read the USER memory Complete reading of the USER memory

Activate the USER memory mode Write to the USER memory Complete writing to the USER memory

Activate the UID access Read UID Complete reading UID

Complete change to USER memory or UID Read diagnostic data Complete reading the diagnostic data

0x8*** Error code (see Table 12)

Table 11

31

Error codes

owStatus Description

0x8000 Evaluation unit indicates an error; evaluate the diagnostic data in the oardwDiagData output parameter. For the error codes see the device manual.

0x8101 0x8102 0x8103 0x8104 0x8105 0x8106

iiChannelNo input parameter invalid iarbDTE102 input parameter invalid oarbDTE102 input parameter invalid Different sizes of the iarbDTE102 input parameter and oarbDTE102 output parameter iarbSendBuf input parameter invalid oarbRcvBuf output parameter invalid

0x8201 0x8202

ixConnOK input parameter = FALSE during data transmission Timeout; evaluation unit does not react

0x8301 0x8302 0x8303 0x8304 0x8305 0x8306 0x8307

Start of a command while the function block is busy (oxBusy = TRUE) Start of a command with antenna switched off (ixAntOff = TRUE) Simultaneous start of the read and write command Start of a command without tag in the antenna field iiRdRwLength input parameter <= 0 or greater than the defined receive buffer (oarbRcvBuf) iiRdRwLength input parameter <= 0 or greater than the defined send buffer (iarbSendBuf) Write UID is not supported by the system

0x8401 (oarbRcvBuf) receive buffer too small for cyclically read UID

Table 12