beautypg.com

3 writing tag data – Baracoda Barcode Reader User Manual

Page 57

background image

DualRunners – Communication Protocol v1.3

- 57 -

Data Capture

for Workforce

in Motion

2.3 Writing tag data

2.3 Writing tag data

2.3 Writing tag data

2.3 Writing tag data

a)

Communication diagram

The following diagram shows what needs to be done in order to write the contents of a Mifare Ultralight tag:

Terminal

BRRT or BDR Reader

b)

Data sent from the terminal to the reader

For every page that needs to be modified, the terminal needs to send a write command to the reader. It is

recommended to verify what parts of the tag data have been modified and send only the differing pages.

In order to write a page, the terminal needs to send to the reader a Write data command to the reader. This

command is described in the communication protocol guide of the reader; its code ID is 0x82. In the example

the user intends to modify page 7 (seven), so the format of the command will be as follows (in hexadecimal):

DE 00 0C 82 00 00 00 01 07 00 04 xx xx xx xx

where:

-

DE: prefix

-

00 0C: data length (12 bytes will follow)

-

82: command ID (write tag data)

-

00 00: protocol mask (it’s best to specify 00 00 for Mifare cards)

-

00: timeout for the response (0 means use default = 5s)

-

01: card type (Mifare Ultralight)

-

07: start page (7)

-

00 04: data length (4 bytes)

-

xx xx xx xx: data to be written in page 7

Send write command to

reader

Confirm that data has been

written