User manual
114
Important Note: locking the data prevents further write access to that data and is irreversible. The data can still
be read by the Host. All data is locked on a block wide (4 byte) basis. Make sure you have written all the data
you want to a block before locking it.
The data bytes are the numbers or characters you want to store on the RF card. The data stream is terminated
by a carriage return or a Boca command starting delimiter character.
The <RFW1,4,0>BOCA SYSTEMS(CR) command would be used to program 12 bytes starting at block 4. The
12 bytes would be comprised of values 42h,4Fh,43h,41h,20h,53h,59h,53h,54h,45h,4Dh,53h. The data is not
locked.
The <RFW2,8,1>01020322(CR) command would be used to program 4 bytes starting at block 8. The 4 bytes
would be comprised of values 01h,02h,03h,22h (Note it is using 2 byte ASCII format). The data would be
locked in block 8.
The difference between Binary mode and ASCII mode can be a little confusing. Another example may be
helpful.
Binary format example - the <RFW1,4,0>12345678(CR) command would be used to program 8 bytes starting at
block 4. The 8 bytes would be comprised of values of 31h,32h,33h,34h,35h,36h,37h,38h. The data is not
locked.
If you sent the same command using ASCII format it would produce just 4 data bytes of 12h,34h,56h and 78h.
Special OTP (One-Time Programming) Block –
Block 3 (4 bytes) on the MIFARE Ultralight card is a bit-wise modified, one-time only programming area that can
be used for a 32 bit counter. The region is initially programmed to ‘0’. Each bit can be individually programmed
to a ‘1’ but once set, the process is irreversible. Each time you write data to this block it is bit-wise ‘or-ed’ with
the current contents of the OTP bytes. You can also lock the entire block, thereby preventing any more
accesses to this region.
The <RFW2,3,0>000000FF(CR) command would be used to program the 4 bytes of the OTP block with a
counter value of 255 (FFh). The count would not be locked. Note this is using 2 byte ASCII format.
TEMPORARY RF KEY COMMAND - <RFK00,#,#,#,#,#,#> Note: those are zeros after the RFK. RFK00 will
change key A. RFK01 will change key B.
Note: This command is only for Mifare 1K tags.
This command specifies what security key value should be used when authenticating a Mifare 1K tag. All Mifare
1K tags must be authorized before performing a read or write operation. This is handled automatically by the
printer using the permanent flash value it has stored for key A.. Normally, a tag contains two keys (A and B) per
sector that can be used for authentication. Since key B is usually readable, the printer initially uses key A. If the
temporary Key command is sent, the printer will use that value for authentication.
The key functions are controlled by the access conditions set for each sector. Note: The key values and access
condition bits for each sector can be changed by writing directly to the appropriate bytes in the sector trailer.
Please refer to the Mifare 1K specification for a more detailed description.
If key B is desired for authentication, then the access bits must be changed accordingly and the proper RFK01
command sent to the printer.
Warning: Writing incorrect information to these blocks can permanently disable the sector concerned.
Mifare 1K tags are shipped with a factory default key A value called the Transport Configuration. The printer
uses the Philips Transport Key A value (FF,FF,FF,FF,FF,FF). If there are errors using the tag, try changing the
key A value to another typical value like A0,A1,A2,A3,A4,A5.
Ex: change key A value to Infineon Transport Configuration before reading 16 bytes from block 1.
<RFK00,A0,A1,A2,A3,A4,A5><RFR1,1,16,1>