MiFare Protocol Guidefor metraTec MiFare Readers and ModulesDate: June 2009Version: 1.0metraTec MiFare Protocol Guide
3.4. Wake Up (WAK)The wake up command ends the power save mode. Reader will restore its last state prior to the standby. If successful it returns GMO
e.g. Set pin 0 high: WOP<SPACE>00<SPACE>HI<CR>e.g. Set pin 0 low: WOP<SPACE>00<SPACE>LOW<CR>Response, if succe
3.8. Cyclic Redundancy Check Off (COF)This command turns off the Cyclic Redundancy Check (CRC) of the computer-to-reader communication. This is the de
SSK<SPACE>23<SPACE>FFFFFFFFFFFF<CR>Possible Error Response:UPA<CR> Unknown parameterEDX<CR> Location fail, or other cha
SKU<SPACE>{Type}<SPACE>[Loc]<CR>Parameter DescriptionType The type of the key:TEMP chooses the temporary keySTAT chooses the static
4. General ISO 14443A CommandsThis list gives an overview of the existing commands that can be used with any transponder that is based on ISO14443A,
IVF 02<CR>Possible error codes:UPA<CR> Unknown parameter4.2. Select Tag (SEL)Before you can exchange data with a MiFare chip, the transpo
Sometimes it is useful to work with all cards in the field. For this purpose an optional parameter “CYC” exists. When using the “CYC” parameter it is
C2DF6084<CR>Possible error codes:UPA<CR> Unknown parameterTNR<CR> Tag not responding (left the field since the INV command)4.3. Rea
CMD Custom Read Command, one hexadecimal byteTable 5: Read command parameter descriptionResponse, if successful:Number of lines is equal to the number
Table of ContentList of Abbreviations...4
command also has a direct write mode, marked with the first parameter “DRT”. The number of bytes will not be checked in this mode and it depends on th
WDT<SPACE>00112233445566778899AABBCCDDEEFF<SPACE>18<CR>Possible error codes:UPA<CR> Unknown parameterEHX<CR> The string
5. MiFare Classic CommandsThis section describes commands only to be used with MiFare Classic (1K or 4K) chips.Command Name DescriptionAUT Authentica
Response, if successful:OK!<CR>Examples:Direct authentication of block 8 (sector 2) with keytype B and key FFFFFFFFFFFFhAUT<SPACE>DRT<S
Block 13 (sector 3) is authenticated and all blocks of this sector should be returnedGAB<SPACE>ALL<CR>Response:0 1 0<CR> (Block 12 i
There are different ways to manipulate data in the sector trailer by using these modes: Set key and Access Bits (SKA) Set Keys Only (SKO) Direct ov
Examples:Write Key A (665544332211), Key B (112233445566) and block mode 3 (1 1 0) for block 2STM<SPACE>SKA<SPACE>2<SPACE>1<SPAC
C1, C2, C3 BCD-Coded Mode, 0 or 1KeyA MiFare authentication key A; 6 Bytes hexadecimal coded ASCII-string (16 chars)KeyB MiFare authentication key B;
Increment - adds a value (given as parameter) to the value present in a chosen block (inputblock) and writes the result to the outputblock. (Mode 3)
VAL<SPACE>INIT<SPACE>SAB<SPACE>00202000<SPACE>05<CR>Possible error codes:UPA<CR> Unknown ParameterNMA<CR> No
5.2. Get Access Bit (GAB)...235.3. Sector Trailer Manip
Parameter DescriptionMOD Selected either increment (INC) or decrement (DEC) VALUE unsigned hexadecimal value (summand/subtrahend)Inputblock 1 decimal
5.4.3. RestoreThis command is used for powerful backups. If the input –and outputblock are not the same, this command restores the result written in t
6. AppendixAppendix 1: CRC Calculation// this function calculates a CRC16 over a unsigned char Array with, LSB first// @Param1 (DataBuf): An Array, w
BNW Block Not WritableBAE Block Access ErrorBNA Block Not AuthenticatedAKW Access bits or Keys not WritableUKB Use Key B for authenticationUKA Use Ke
Sector Block Absolute Block Nr Funktion15 3 63 Sector Trailer (Key A, access bits, Key B)15 2 62 Data15 1 61 Data15 0 60 Data… … … …0 3 3 Sector Trail
one or both of the keys for each block. That means, that e.g. you can use Key A in your customer application which is only able to read the data, but
Block Mode 0: This is the transport configuration (delivery state). In this mode the block is readable and all data manipulating commands are enabled.
7. Version ControlVersion Change by Date1.0 created KD 11.3.2009metraTec MiFare Protocol Guide
Contact / SupportmetraTec GmbHWerner-Heisenberg-Str. 1D-39106 MagdeburgTel.: +49 (0)391 251906-00Fax: +49 (0)391 251906-01Email: [email protected]
List of AbbreviationsATQA Answer to request, ISO 14443A – a number code showing some information on the card. See Appendix for examples.PICC Proximity
1. IntroductionThis document describes the metraTec firmware protocol for all metraTec RFID readers that work with RFID transponders according to ISO
1.2.Further DocumentsFor an even deeper understanding of the operating principle it might be useful to read all datasheets and norms regarding your tr
2. Communication PrincipleThe communication between the reader and the host system is based on ASCII strings. Each string is terminated with a carria
3. Reader InstructionsThis list gives an overview of all the existing instructions that directly influence the reader itself. All commands that are c
3.2. Revision (REV)The revision command requests the device type and hard- and software revision of the reader. The reader returns its device type and
Comments to this Manuals