HP Proximity Card Readers

Note: This documentation is intended to be used by Workpath apps or OXPd Solutions that interface with HP Card Readers (4QL32A, 2FG93A, X3D03A, CZ208A, CE931A and CE983A) on HP Imaging and Printing devices, and as per the Terms of Service shall not be used to create a reader that emulates the HP Card Reader.

The HP Proximity Card Readers are USB-based proximity card reader systems that can be used by a Workpath app or an OXPd Solution with HP imaging and printing devices (single function, multifunction, and scanner devices) to collect proximity card information. The HP Proximity Card Reader includes the components to allow it to connect to either an external USB port or to be installed in to the HP Hardware Integration Pocket (HIP) for HP Imaging and Printing devices that support this feature.


The CZ208A and X3D03A readers can be configured to support up to 4 cards being active concurrently.
The CE931A and CE983A readers support a single card type.
All four readers share the same USB protocol defined here. See Appendix A for supported card types.

This page consists of the following sections:

Electrical and USB specific specification

The HP Card Reader is compliant to the USB 1.1 specification as an HID class device with a Vendor Specific class protocol and supports EP1 IN Interrupt (for asynchronous card data) and EP0 Control transfers (standard requests and Feature Reports).

Note: This documentation is intended to be used by Workpath apps or OXPd Solutions that interface with HP Card Readers (4QL32A, 2FG93A, X3D03A, CZ208A, CE931A and CE983A) on HP Imaging and Printing devices, and as per the Terms of Service shall not be used to create a reader that emulates the HP Card Reader.

The HP Proximity Card Readers are USB-based proximity card reader systems that can be used by a Workpath app or an OXPd Solution with HP imaging and printing devices (single function, multifunction, and scanner devices) to collect proximity card information. The HP Proximity Card Reader includes the components to allow it to connect to either an external USB port or to be installed in to the HP Hardware Integration Pocket (HIP) for HP Imaging and Printing devices that support this feature.


The CZ208A and X3D03A readers can be configured to support up to 4 cards being active concurrently.
The CE931A and CE983A readers support a single card type.
All four readers share the same USB protocol defined here. See Appendix A for supported card types.

This page consists of the following sections:

Electrical and USB specific specification

The HP Card Reader is compliant to the USB 1.1 specification as an HID class device with a Vendor Specific class protocol and supports EP1 IN Interrupt (for asynchronous card data) and EP0 Control transfers (standard requests and Feature Reports).

ValueField Description
0x12, 0x01Descriptor Length, bDescType (DEVICE)
0x10, 0x01bcdUSB Low / High (USB Version 01.10)
0x00bDeviceClass
0x00bDeviceSubClass
0x00bDeviceProtocol
0x08bMaxPacketSize (8 bytes)
0xF0, 0x03idVendor VID_LO, VID_HI
0x45, 0x00idProduct PID_LO, PID_HI
0x00, 0x01idDevice DID_LO, DID_HI
0x01String Index - Mfg = “Hewlett-Packard”
0x02String Index – Prod = “HP Proximity Reader (X3D03A,CZ208A, CE931A or CE983A)”
0x00String Index - SN = “” (none)
0x01bNumConfigurations
USB Device Descriptor
ValueField Description
0x09, 0x02Descriptor Length, bDescType (CONFIGURATION)
0x22, 0x00Length Low / High
0x01bNumInterfaces
0x01bConfigValue
0x00Config String Index
0x80bmAttributes - 100000 (Not Self Powered, No Remote Wake)
0x32MaxCurrent (2mA units)
USB Configuration Descriptor
ValueField Description
0x09, 0x04Descriptor Length, bDescType (INTERFACE)
0x00, 0x00Number of interface (0 based array), alternate setting
0x01Number of EPs used in this Ifc (beyond EP0)
0x03Interface class HID (assigned by the USB)
0x00NOT a legacy Boot Device
0x00Interface protocol (none)
0x00Index to Ifc string (none)
USB Interface Descriptor
ValueField Description
0x09, 0x21Descriptor Length, bDescType HID (class)
0x10, 0x01Class (HID) Release ver: 1.10
0x00Localized country code (none)
0x01Number of HID class descr to follow
0x22Report descriptor type (HID)
0x20, 0x00Length Low / High (bytes)
USB Class Descriptor
ValueField Description
0x07, 0x05Descriptor Length, bDescType (ENDPOINT)
0x81EP1 IN
0x03Type Interrupt
0x08, 0x00Max packet size Low / High (8 bytes)
0x0APolling interval (mS)
USB Endpoint Descriptor

Reader programming protocol

This section describes the HP Card Reader behavior, USB Feature Report protocol that can be used by solutions to interact with and control the HP Card Reader, as well as defines the data returned from the reader when a card is placed within range of the reader antenna.

Reader behavior

The HP Card Reader has five operating states:

StateDescription
ReadyThe reader is ready to read a card.
ReadingThe reader is in the process of reading a card.
GoodThe card read was a valid card.
BadThe card read was not a valid card. While the protocol supports “bad” operating status, the readers do not support “bad” reads and an unreadable card will appear as no card present.
SendingThe reader is currently sending data to the host.
Operating States

The reader can be configured to automatically have the beeper respond differently when Good or Bad data is received, and can be configured to have the LED color set uniquely for each state. Alternatively, the beeper sound and LED color can be completely controlled via a solution.


The reader can be configured to operate with different card types with up to two distinct card types being active at any one time.


The reader can be configured to either automatically return data to the interrupt endpoint, or it can be configured so that data is not automatically sent and the data can be polled for and retrieved via a feature report. The reader also has the capability to determine the age of the data so that the solution can determine whether the card data is recent enough to be trusted or has gone stale.


The reader can be configured to return command responses via a feature report on endpoint 0 or via the interrupt endpoint 1. The reader can also be configured to include the card type in the card data returned.

Power-on behavior

The power-on sequence for the reader is as follows:

  1. Initialization of hardware and memory.
  2. Light the amber LED.
  3. Enumerate the USB.
    1. Note: The LED will blink amber rapidly while the reader is enumerating. If the reader fails to enumerate after one minute, the LED will turn off, but the reader will attempt to enumerate as long as power is applied.
  4. Copy and verify the Reader Configuration from flash to RAM.
    1. If valid: The reader will sound two short beeps and light the green LED
    2. If not valid: the Factory Default Configuration is copied to RAM instead and written to the Reader Configuration area in flash. The reader will sound one long beep and light the red LED.
  5. If Automatic LED is enabled, the reader will display the Reader Ready LED.

Normal operation behavior

Following the power up sequence, the reader will behave as follows:

  1. The reader waits in the Ready State for data to be available, continuously monitoring for the placement of a card in the field of the antenna.
  2. After the card is detected, the reader begins reading data (transitioning to Reading State).
  3. While reading data, but before data read is complete, the reader will display the Reading Data LED If Automatic LED is enabled.
    1. Note: For most proximity cards the reading time is so brief (less than 150ms) that this indication may not be visible.
    2. Note: Readers that support multiple card types will first attempt to read either the prioritized card type or the first configured card type (CardType1) for the card format. If unsuccessful, it will attempt to read the second configured card type format (CardType2), then (CardType3), then (CardType4). It will continue attempting to read Card
  4. Upon completion of reading:
    1. If data read is valid (from either card type):
      1. The Data Available Flag is set.
      2. If Automatic LED Mode is enabled, the Good Data LED will be displayed.
      3. If Automatic Beep Mode is enabled, the Good Data Beep will be sounded.
      4. Data is available to send:
        1. If Silent Output is disabled:
          1. The reader will send the data in ASCII to the output port (USB End Point 1) terminated by a carriage return (0x0d).
          2. The Data Age Timer is reset to one.
          3. The Overrun Counter is incremented unless this is the first card read after receiving the Clear Data Available command
        2. If Silent Output is enabled:
          1. If reader receives Get Card Data command from the host, card reading is inhibited until receipt of the Clear Data Available command. If Automatic LED Mode is enabled, the Sending Data LED is displayed.
          2. If reader does not receive Get Card Data command from the host, the reader will wait 10 seconds and then terminate the sending data mode of operation.
        3. If the Clear Data Available command is received:
          1. The reader will not increment the Overrun Counter for the next card read.
          2. Reading of cards will be enabled.
          3. If Automatic LED Mode is enabled the Reader Ready LED will be displayed.
    2. If data read is invalid (from the configured card types), no LED or Beep indication is provided to the user, and it appears that the card was never read.
  5. After data has been received (good or bad,) the reader will wait approximately 1 second before new data can be read. After that time:
    1. If Continuous Output Mode is enabled, and data is available from the card (there is a card within the proximity field), the reader will repeat the data valid or invalid procedure approximately once per second until card data is no longer available.
    2. If Continuous Output Mode is not enabled, the reader will not respond to a card until it detects the absence of a card (there is no card within the proximity field) for one second.
  6. If the reader receives any of the following USB commands, the reader will reset and wait to enumerate:
    1. USB hibernate
    2. USB sleep
    3. USB Disconnect

Feature Report Protocol

The feature report protocol is an ASCII character based communications protocol that uses a 24 byte feature report. Communications are always initiated by the host solution. The host will send command packets, which the reader will reply to with either a response or an error.

Feature report protocol overview

The 24 byte protocol command packet is broken into three parts:

  • Command (Bytes 0 – 2) The first three bytes define the command.
    • Byte 0 – Major Command Character
    • Byte 1 - Index of array 0-10 or Sub Command
    • Byte 2 – Segment if needed or sub-command when Byte 1 is an index.
  • Payload (Bytes 3-22) The next 20 bytes are the payload, consisting of 20 bytes of ASCII Hex and/or Printable ASCII Text for 10 bytes of payload.
    • Note: All payload data representing values or bit structures will be transferred as ASCII Hex - two printable upper case 0-9, A-F characters. Some payload data may be actual ASCII strings.
  • Carriage Return Terminator (Byte 23) The final character of each packet is a carriage return (0x0D). Much of the 24-byte feature report will be unused and shall be filled with ‘00’ (0x30, 0x30) in both directions.

Feature Report Protocol Notes:

  • Transferring more than 24 bytes of data requires using more than one command/reply packet. The protocol has been designed to handle this.
    • Note: All values in the feature report protocol that cannot be represented in a single byte (for example, values greater than 255), will be presented in little Endean form (lowest-order byte first, highest-order byte last).
  • With the exception of the terminator, all characters in the protocol are Printable ASCII Text. When numeric or binary values are sent in the protocol they are sent as ASCII Hex.
  • All unused bytes of the Command Payload shall be set to ‘0’ (0x30).
  • The letter ‘O’ is not used in the command part (bytes 0 – 2) of the protocol to avoid confusion with the number ‘0’.
Sample command (QRZ command used as example)
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Command Payload Terminator
QRZ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ Carriage Return (0x0d)

The reader responds to each Command Packet with a 24-byte Response Packet or a 24-byte Error Packet. There will always be a one-to-one packet command / reply exchange. For each 24-byte packet sent by the host, the device will reply back with one 24-byte packet.

  • A Response Packet replaces the first character of the received Command Packet with an ‘R’, and any response will be in the Payload.
  • An Error Packet replaces the first byte of the Command Packet with an ‘E’, and copies the remaining 23 bytes from the Command Packet.
Sample response packet
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Response Response Data Terminator
RRZ ‘M’ ‘F’ ‘P’ ‘2’ ‘4’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ Carriage Return (0x0d)
Sample error packet
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Response Response Data – Copied from Command Terminator
ERZ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ Carriage Return (0x0d)

Host to Reader Protocol Command Summary


The following table summarizes available general protocol commands detailed in the specification:

Command DescriptionMajor Command Character (Byte 0)Index or Sub command (Byte 1)Segment or Sub command (Byte 2)Payload (Bytes 3-22)
Beep now LONG 375ms beeps count times'B''L'Count = '1' - '2''Ignored
Beep now short 125ms beeps count times'B''S'Count = '1' - '5'Ignored
Set Beeper Volume'B''V'‘0’ – ‘3’Ignored
Clear Data available flags 1,2,3'C''D''0'Ignored
Clear Overrun counter'C''Q''0'Ignored
Set flash and ram to factory defaults'F''D''0'Ignored
Read Flash config to ram'F''R''0'Ignored
Write config ram back to Flash'F''W''0'Ignored
Get Card Data'G''0''0' .. '3'Ignored
Get LED Colors'G''L''0'Ignored
Get Data Age/Overrun structure'G''Q''0'Ignored
Get SysConfig data'G''S''0'Ignored
Get SysConfig data (cards 3-4)'G''S''0'4 Bytes
Resend the last card data'P''A''S'Ignored
Query Supported Card Types'Q''C''T'Ignored
Get part number string'Q''R''Z'Ignored
Get Data ready status'Q''S''0'2 Bytes
Get Software Version numbers'Q''S''V'Ignored
Get Software Version numbers Extended'Q''S''X'Ignored
Set LED Colors'S''L''0'2 Bytes
Set SysConfig data'S''S''0'9 Bytes
Set SysConfig data (cards 3-4)'S''S''1'4 Bytes

Note: Not all commands are supported by all card readers. If the reader returns an error message, the command may not be supported.

Command timing

All commands, with the exception of Flash Write commands. return response upon receipt and parsing of the command, with commands executed in the background. Consequently, with the exception of the Beeper commands, the time interval between issuance of feature report commands shall not be less than 250ms to insure successful completion of the commands. See the Beeper Command Section for specific timing requirements of the Beeper Commands.

Configuration and reader information commands

The commands in this section are used to get information about the reader, as well as to configure the reader’s operating mode.
Note: Solutions are strongly encouraged to collect and maintain the Query Version Number (QSV) and Query Version Number Extended information for troubleshooting purposes, as well as to facilitate upgrades for potential future releases of the reader.

QRZ - Query Part Number String

This command queries the reader for the part number string of the reader. All MFP-24 readers return “MFP24000000000000000000”.

Command
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Unused Terminator
QRZ Unused Carriage Return (0x0d)
Response
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Response Response Data Terminator
RRZ ‘M’ ‘F’ ‘P’ ‘2’ ‘4’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ ‘0’ Carriage Return (0x0d)

QSV - Query Version Number

This command queries the reader for the version number of the reader firmware and boot loader firmware.

Command
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Unused Terminator
QSV Unused Carriage Return (0x0d)
Response
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Response Major Version Minor Version Number Hardware Subtype Boot Loader Version High Byte Boot Loader Version Low Byte Control CPU Extended Version Number Major Control CPU Extended Version Number Minor Control CPU Extended Version Number Control CPU Extended Version Number Variant Unused Terminator
RSV “00” – “FF” “0” – “F” “0” – “F” “00” – “FF” “00” – “FF” “00” – “FF” “00” – “FF” “00” – “FF” “00” – “FF” '0' '0' '0' '0' Carriage Return (0x0d)

QSX - Query Version Number Extended

This command queries the reader for the version number of the radio CPU firmware and RF System, as well as boot loader version.
 

WARNING: This command is not implemented on the CE931A or CE983A.

Command
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Version Index Unused Terminator
QSX "00" Unused Carriage Return (0x0d)
Response
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Response Version Index RF CPU Application Version Number RF CPU Radio Version Number Unused Terminator
RSX "00" “00” – “FF” “00” – “FF” “00” – “FF” “00” – “FF” “00” – “FF” “00” – “FF” “00” – “FF” “00” – “FF” '0' '0' Carriage Return (0x0d)
Command
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Version Index Unused Terminator
QSX "01" Unused Carriage Return (0x0d)
Response
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Response Version Index RF Bootload Version Number Unused Terminator
RSX "01" “00” – “FF” “00” – “FF” “00” – “FF” “00” – “FF” Copied from Command (‘0’) Carriage Return (0x0d)

QCT – Query Supported Card Types

This command returns the current Reader Configuration block 1 as it exists in RAM.

Note: If this command is not supported by the reader, the reader will respond with ES1.

Command
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
QCT Block # ’00-99’ Unused Carriage Return (0x0d)
Response
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
RCT Card Type Block # * 5 + 0 “0000” – “FFFF” Card Type Block # * 5 + 1 “0000” – “FFFF” Card Type Block # * 5 + 2 “0000” – “FFFF” Card Type Block # * 5 + 3 “0000” – “FFFF” Card Type Block # * 5 + 4 “0000” – “FFFF” Carriage Return (0x0d)

GS0 - Get System Configuration

This command returns the current Reader Configuration as it exists in RAM.

Command
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Unused Terminator
GS0 Unused Carriage Return (0x0d)
Response
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Response Configuration Mode Byte Beeper Configuration Byte Logical Unit ID Low Byte Logical Unit ID High Byte Card Type 1 Card Type 2 Card Type Priority Unused Terminator
RS0 “00” – “FF” “00” – “FF” “00” – “FF” “00” – “FF” “00” – “FF” “00” – “FF” “00” – “FF” "00" Carriage Return (0x0d)

The definition of the response bytes is covered in the Set System Configuration command.

GS1 - Get Extended System Configuration

This command returns the current Reader Configuration block 1 as it exists in RAM.
Note: If this command is not supported by the reader, the reader will respond with ES1.

Command
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Card Type 3 Card Type 4 unused Terminator
GS1 “0000” – “FFFF” “0000” – “FFFF” unused Carriage Return (0x0d)
Response
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Response Card Type 3 Card Type 4 Unused Terminator
RS1 “00” – “FF” “00” – “FF” “00” Carriage Return (0x0d)

The definition of the response bytes is covered in the Set System Configuration command.

GBL – Get Block Configuration

This command retrieves the Block data from the reader. Refer to Appendix C: File and Key Blocks for further information and a description of the block header.

Command
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Unused Type Index Unused/Header Terminator
GBL “00” – “FF” “00” – “FF” “00” – “FE” "00" Carriage Return (0x0d)
Response
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Response Error Type Data Terminator
RBL “00” = Success Copied From Command Block Data Carriage Return (0x0d)

Index Description:

  • 0 = sends the block header to identify the block being retrieved
  • 1-FE = returns block data.

Error code Descriptions:

  • 0 = Success
  • 2 = no block entry for that type and ID
  • 4 = block write was interrupted, invalid entry
  • 12 = data doesn’t exist for the index value.
  • -1 = invalid block type

GPX - Get Prefix Data

This command returns the current prefix to be attached to data for a configuration slot and field. (Either Secure Data or Card Serial Numbers)

Command
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Card config slot# Field # Reserved (Fill with “00”) Terminator
GPX 0 – 3 0 – 1 000000000000000000 Carriage Return (0x0d)
Response
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Response Card config slot# Field # Number of Prefix First 2 digit hex digit Second 2 digit hex digit Third 2 digit hex digit Fourth 2 digit hex digit Fifth 2 digit hex digit Sixth 2 digit hex digit Seventh 2 digit hex digit Eight 2 digit hex digit Terminator
RPX 0 - 3 0 - 1 “00” – “FF” “00” – “FF” “00” – “FF” “00” – “FF” “00” – “FF” “00” – “FF” “00” – “FF” “00” – “FF” “00” – “FF” Carriage Return (0x0d)

GFX - Get Format Options

This command returns the current data format for a configuration slot and field.

Command
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Card config slot# Field # Reserved (Fill with “00”) Terminator
GFX 0 – 3 0 – 1 000000000000000000 Carriage Return (0x0d)
Response
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Response Card config slot# Field # Flag to set case or Reverse Bytes Base Output # of digits to output Unused Terminator
RFX 0 - 3 0 - 1 “00” - “03” “00” – “FF” “00” – “FF” 000000000000 Carriage Return (0x0d)

SS0 - Set System Configuration

This command sets the current Reader Configuration in RAM. (See the Flash and RAM commands below to save the configuration that is set with this command.)

Command
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Configuration Mode Byte Beeper Configuration Byte Logical Unit ID Low Byte Logical Unit ID HighByte Card Type 1 Card Type 2 Card Type Priority Unused Terminator
SS0 “00” – “FF” “00” – “FF” “00” – “FF” “00” – “FF” “0000” – “FFFF” “0000” – “FFFF” “00” – “FF” "00" Carriage Return (0x0d)
Response
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Response Response data Terminator
RS0 Copied from command Carriage Return (0x0d)

The definition of the Response Packet elements is defined in the following sub-sections:

Configuration Mode Byte
Bit 7 Bit 6 Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 Bit 0
Beeper Automatic Mode LED Automatic Mode Continuous Output Mode Silent Output Mode Pad USB Packets Output Response on EP1 Card Type with Data Unused
Bytes 3 and 4 – Configuration Mode Byte
  • Beeper Automatic. If this bit is set, the reader will sound the good data beep after reading a card.
  • Automatic LED Mode. If this bit is set, the reader will automatically change the state of the LED according to the state that the reader is in. The state of the LED is determined by the LED Configuration.
  • Continuous Output Mode. If this bit is set, the reader will continuously output the data read from the card at a rate of approximately 1 read per second, as long as a card is present. If this bit is clear, the data will only be output once. This setting is ignored if the Silent Output Mode bit is set.
  • Silent Output Mode. If this bit is set, the reader will not autonomously output the card data. The only way to retrieve the card data will be to use the Get Card Data command.
  • Pad USB Packets. If this bit is set (and Silent Output is not enabled), the reader will pad the output packets with 0x00 so that each USB packet contains eight bytes.
  • Output Response on EP1. If this bit is set (and Silent Output is not enabled), the reader will return the command response on EP1 encapsulated in three, 8 byte packets. The format of the command response is the same as the format of the command response returned from a feature report. If this bit is set and a card is placed in the field, the card will not be read until the command response is returned. If the card is placed in the field and removed prior to the command response being returned, there will be no acknowledgement that the card was present.
  • Card Type with Data. If this bit is set, the reader will return the Card Type that was used in reading the card data. See the (Get Card Data) and (Card Data Response from End Point 1) sections (0 and 0) for more details on the effect of this bit.
Bytes 5 and 6 – Beeper Configuration Byte

These bytes are used to set the beeper behavior when Beeper Automatic mode is set. If Beeper Automatic mode is clear, this setting is ignored.

Note: The Bad Beep bit settings are ignored as the reader does not detect a bad card as being any different than no card present. These bits are recommended to be set to ‘b0000’.

Beeper Configuration Byte
Good Beep Bad Beep - Ignored
Bit 7 Bit 6 Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 Bit 0
Beep Type Number of Beeps Beep Type Number of Beeps
0 = Short, 1 = Long 0 - 7 0 = Short ,1 = Long 0 - 7
Bytes 7 - 10 – Logical Unit ID Bytes

The Logical Unit ID is used by a solution to uniquely identify a reader if multiple readers are connected to the same device.

Bytes 11 - 18 – Card Type 1 and 2 Bytes

For the CZ208A and X3D03A readers, these bytes are used to configure which two card types the reader will alternate between and process when reading card data.

Note: The two card types can be any combination of 125KHz-based cards and 13.56MHz-based cards. A complete definition of the supported card types is contained in Appendix A.

Note: In the case where only one card type is desired to be processed, Card Type 1 should be set to the desired card type and Card Type 2 shall be set to “0000”.

For the CE931A and the CE983A readers, since only one card type is used, Card Type 1 shall be left as the default and Card Type 2 is not implemented. Changing to a different value will result in the command being ignored.

Bytes 19 and 20 – Card Type Priority Byte

For the CZ208A and X3D03A readers, this byte is used when the card to be read is a combo card that has both a 125KHz and 13.56MHz card type device in the same package. The software will indicate which card type the reader is to use to read the combo card (“00” for Card Type 1 and “01” for Card Type 2).

Note: The card type has no impact on the reader’s behavior to detect two different cards that are of different types.
For the CE931A and the CE983A readers, since only one card type is used, the field is not implemented. Changing to a different value will result in the command being ignored.

For the CE931A and the CE983A readers, since only one card type is used, the field is not implemented. Changing to a different value will result in the command being ignored.

SS1 - Set System Configuration

This command sets the current Reader Configuration block 1 in RAM. The cards types default to off ’0000’. Execute the FW0 command to write the Configuration block to flash.

Note: If this command is not supported by the reader, the reader will respond with ES1.

Command
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Card Type 3 Card Type 4 Unused Terminator
SS1 “0000” – “FFFF” “0000” – “FFFF” “00” Carriage Return (0x0d)
Response
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Response Response data Terminator
RS1 Copied from command Carriage Return (0x0d)

SBL - Set Block Configuration

This command sends the Block data to the reader to read data other than the CSN from a
13.56MHz card. The blocks can vary, depending on the type of card being used.

Command
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Unused Index Header/Data Header/Data Header/Data Unused/Header Terminator
SBL "00" “00” – “FF” “00” – “FE” “00” – “FE” “00” – “FE” "00" Carriage Return (0x0d)
Response
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Response Unused Index Unused Terminator
RBL “00” Copied From Command “00”, or Type-ID-Length for index 0 Carriage Return (0x0d)

Index Descriptions:

  • An index of 0 is used to send the header. Refer to Appendix C: File and Key Blocks for a description of the Block header.
  • An index of 1 to Block length/8 is used to send the block data. Eight bytes of raw data, using 16 bytes of ASCII-encoded hexadecimal bytes, can be sent at a time.
  • An index of FF is used to tell the reader to process the block. An additional message to save configuration settings to Flash may be needed to permanently store the Block.

Note: Refer to Appendix C: File and Key Blocks for a description of specific blocks. Refer to GBL – Get Block Configuration for a description of error codes.

SPX - Set Prefix Data

This command is used to set a user defined prefixes for card data ouput. This allows a customizable header and delimiter to be placed between fields.

Command
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Card Config Slot Field # # of Prefix character 2 hex digit for ASCII value 2 hex digit for ASCII value 2 hex digit for ASCII value 2 hex digit for ASCII value 2 hex digit for ASCII value 2 hex digit for ASCII value 2 hex digit for ASCII value 2 hex digit for ASCII value Terminator
SPX 0-3 0-1 “00” – “FF” “00” – “FF” “00” – “FF” “00” – “FF” “00” – “FF” “00” – “FF” “00” – “FF” “00” – “FF” “00” – “FF” Carriage Return (0x0d)
Response
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Response Card config slot# Field # # of Prefix characters Series of 2 hex digit codes to represent ASCII values of prefix Terminator
RPX Copied From Command Copied From Command Copied From Command Copied From Command Carriage Return (0x0d)

SFX - Set Format Options

This command is used to set a user defined formatting for card data ouput. Options can be set for each card configuration and field number. The output can be set in uppercase or lowercase, and reverse the data byte before formatting.


Setting upper or lowercase hex flag (Byte 5 - 6): Only 2 flag bits are implemented. If Bit 0 is set, lowercase hex is used (if the base is set to Hex). If Bit 1 is set, the bytes are reversed.


Flags:

  • 0x00 No byte reversal, Uppercase Hex
  • 0x01 No byte reversal, Lowercase Hex
  • 0x02 Reversed Bytes, Uppercase Hex
  • 0x03 Reversed Bytes, Lowercase Hex

Defining the base output (Byte 7-8):

  • 00 – hex (default)
  • 02 – binary (not yet implemented)
  • 08 – octal (not yet implemented)
  • 0A - decimal
  • 10 – hex
  • Note: Any other value is invalid.

Defining Number of digits to output (9 – 10):

  • 00 – Output as many digits as necessary
  • xx – All other values define the number of digits output. Value will be trimmed or leading zeroes added as necessary.
Command
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Card Config Slot Field # Flag to set case or Reverse Bytes Base Output (see key) # of digits to output Reserved (Fill with 00) Terminator
SFX 0 - 3 0 - 1 “00” – “03” “00” – “FF” “00” – “FF” 000000000000 Carriage Return (0x0d)
Response
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Response Card Config Slot Field # Flag to set case or Reverse Bytes Base Output (see key) # of digits to output Reserved (Fill with 00) Terminator
RFX Copied from command 000000000000 Carriage Return (0x0d)

 

SLX - Set Accept List

This command is used to set the card bitcount that will be accepted by the card reader. Up to 9 card bitcounts can be specified, with unused entries set to “00”.
To accept all cards, specify an empty list.

Command
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Reserved 1st accepted card bit count 2nd accepted card bit count 3rd accepted card bit count 4th accepted card bit count 5th accepted card bit count 6th accepted card bit count 7th accepted card bit count 8th accepted card bit count 9th accepted card bit count Terminator
SLX “00” “00” – “FF” “00” – “FF” “00” – “FF” “00” – “FF” “00” – “FF” “00” – “FF” “00” – “FF” “00” – “FF” “00” – “FF” Carriage Return (0x0d)
Response
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Response Reserved 1st accepted card bit count 2nd accepted card bit count 3rd accepted card bit count 4th accepted card bit count 5th accepted card bit count 6th accepted card bit count 7th accepted card bit count 8th accepted card bit count 9th accepted card bit count Terminator
RLX “00” “00” – “FF” “00” – “FF” “00” – “FF” “00” – “FF” “00” – “FF” “00” – “FF” “00” – “FF” “00” – “FF” “00” – “FF” Carriage Return (0x0d)

Flash and RAM commands

The Flash and RAM commands are used to set the readers configuration in Flash or to read the configuration from Flash into RAM.

FD0 – Flash defaults into reader

This command resets the reader to the Factory Default Configuration. This is a simple way to restore the reader to a known state. This command does not change the Card Type 1 and Card Type 2 settings that have been set with SS0 command. The factory defaults are:

Automatic Beeps:Enabled
Automatic LED:Enabled
Silent Output:Disabled
Pad USB Packets:Disabled
Continuous Read:Disabled
Output Response on EP1:Disabled
Card Type with Data:Enabled
Good Beep:2 Shorts
Good Data LED:Green
Reading Data LED:None
Sending Data LED:Amber
Reader Ready LED:Red
Logical Unit ID:0x0000
Card Type 1:EF04 (CZ208A/X3D03A)
0100(CE931A)
0110 (CE983A)
Card Type 2:6F01 (CZ208A/X3D03A)
na (CE931A)
na (CE983A)
Card Priority:Card Type 1
Command
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Unused Terminator
FD0 Unused Carriage Return (0x0d)
Response
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Response Unused Terminator
RD0 Copied from command Carriage Return (0x0d)

FR0 – Flash Read Reader Configuration into RAM

The reader maintains a copy of the current reader configuration in flash memory. When the reader is powered on this configuration is copied from flash to RAM.


The configuration in RAM can be modified by commands in this protocol. This command will overwrite any changes in RAM that have not been committed to flash (FW0 command) with the Reader Configuration that has been previously stored in flash memory.


This command is a simple way to restore the reader to the last saved configuration state.

Command
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Unused Terminator
FR0 Unused Carriage Return (0x0d)
Response
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Response Unused Terminator
RR0 Copied from command Carriage Return (0x0d)

FW0 – Flash Write Configuration from RAM to Flash


The reader maintains a copy of the current Reader Configuration in flash memory. When the reader is powered on this Reader Configuration is copied from flash to RAM.


The Reader Configuration in RAM can be modified by commands in this protocol. This command will save these changes to flash memory.


Any changes to the Reader Configuration in RAM that are not written to flash will be lost the next time the reader is powered off.

Command
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Unused Terminator
FW0 Unused Carriage Return (0x0d)
Response
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Response Unused Terminator
RW0 Copied from command Carriage Return (0x0d)

Card data access commands


The card data access commands are used by a solution to detect that there is data to be read from a card and to read this data when the reader is configured in Silent Output Mode.


Note: Card data retrieved from a card is cached within the reader to facilitate read recovery. This data is not changed until a subsequent card read is performed using commands described in this section, or a solution uses the Clear Data Available command to remove the data. It is the responsibility of the solution provider to determine how to manage this data based on their security requirements.

QS0 - Query Data Ready Status command

This command queries the reader if data is available for transfer to the host, and from which card type the data has come from. “00” is returned in Data Ready if no card data is available, and “01” is returned if card data is available to be read. “00” is returned in Card Type Read if the data was provided by the card identified in the CardType1 field of the reader status, and “01” is returned if the data was provided by the card identified in the CardType1 field of the reader status.


The Clear Data Ready command clears this status.

Command
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Unused Terminator
QS0 Unused Carriage Return (0x0d)
Response
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Response Data Ready Card Type Read Unused Terminator
RS0 “00” or “01” “0000” - “FFFF” Unused Carriage Return (0x0d)

GQ0 - Get Data Age/Overrun Structure command

The reader keeps track of the age of the current card data (Data Age) and number of cards that have been read since the last time the Overrun Counter was cleared (CQ0 -Clear Overrun Counter command). This command returns the Data Age and Overrun Counter.

Note: The first card read after the CD0-Clear Data Available command is not counted in the Overrun count.

The Data Age value is in 48ms units and is set to 1 whenever a card is successfully read. The Data Age will remain at the maximum value (3145680ms) after the maximum value is reached.

Command
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Unused Terminator
GQ0 Unused Carriage Return (0x0d)
Response
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Response Low order byte of Data Age High order byte of Data Age Low order byte of Overrun Counter High order byte of Overrun Counter Unused Terminator
RQ0 “00” – “FF” “00” – “FF” “00” – “FF” “00” – “FF” Copied from Command Carriage Return (0x0d)

CD0 - Clear Data Available command

When new card data is available for the host to read, the Data Available flag is set. This command clears the Data Available flag. The Data Available flag will remain cleared until new card data is available.

The purpose of this command is to inform the reader that the host has finished transferring the card data from the reader to the host.

When the host initiates the transfer of card data (G0# commands), new card reads are inhibited. This command tells the reader that the host has finished retrieving data, and re-enables the reading of cards.

The reader keeps track of how many cards have been read since the last host transfer (Overrun Counter). This command disables incrementing the Overrun Counter for the next card read.

Command
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Unused Terminator
CD0 Unused Carriage Return (0x0d)
Response
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Response Unused Terminator
RD0 Unused Carriage Return (0x0d)

CD1 – Clear Card Data

This clears the Data Available flag, similar to CD0, and also clears the card data. A card present in the field can be re-read without leaving the field using this command. If
the card has been removed from the field before this command is issued, then a Get Card Data command will return all zeros.

Command
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Unused Terminator
CD1 Unused Carriage Return (0x0d)
Response
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Response Unused Terminator
RD1 Unused Carriage Return (0x0d)

CQ0 - Clear Overrun Counter command

This command clears the Overrun Counter.

Command
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Unused Terminator
CQ0 Unused Carriage Return (0x0d)
Response
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Response Unused Terminator
RQ0 Unused Carriage Return (0x0d)

G0# - Get Card Data command

This command transfers the data for the last card read from the reader to the host.

Because the protocol is broken into 24-byte packets it is possible that more data will be available than can be transferred with a single command.

The third byte (byte 2) of the command specifies the segment of the data to be transferred.

The following table lists what card data bits are returned in what segment:

In addition to card data, the response for the first segment contains the following data:

  • If Card Type with Data is enabled:
    • The first four bytes of the returned data (bytes 3 to 6 of segment 0) specify the card type used to read the data.
    • The next two bytes of the returned data (bytes 7 and 8 of segment 0) specify the length of the returned data in bits.
  • If Card Type with Data is disabled:
    • The first two bytes of the returned data (bytes 3 and 4 of segment 0) specify the length of the returned data in bits.
Segment Card Type with Data Setting
Disabled Enabled
Starting Bit Ending Bit Starting Bit Ending Bit
0 0 71 0 55
1 72 151 56 135
2 152 231 136 215
3 232 255 216 255
Bytes 0 & 1Byte 2Bytes 3-22Byte 23
CommandSegmentUnusedTerminator
G0'0'UnusedCarriage Return (0x0d)
Bytes
0 - 1
Byte
2
Bytes
3 - 4
Bytes
5 - 6
Bytes
7 - 8
Bytes
9 - 10
Bytes
11 - 12
Bytes
13 - 14
Bytes
15 - 16
Bytes
17 - 18
Bytes
19 - 20
Bytes
21 - 22
Byte
23
Cmd
Response
SegmentCard Type
(High Byte)
Card Type
(Low Byte)
Number
of Bits
Bits
0 – 7
Bits
8 – 15
Bits
16 – 23
Bits
24 - 31
Bits
32 - 39
Bits
40 – 47
Bits
48 – 55
Terminator
R00“00” – “FF”“00” – “FF”“00” – “FF”“00” – “FF”“00” – “FF”“00” – “FF”“00” – “FF”“00” – “FF”“00” – “FF”“00” – “FF”Carriage Return (0x0d)
Bytes
0 - 1
Byte
2
Bytes
3 - 4
Bytes
5 - 6
Bytes
7 - 8
Bytes
9 - 10
Bytes
11 - 12
Bytes
13 - 14
Bytes
15 - 16
Bytes
17 - 18
Bytes
19 - 20
Bytes
21 - 22
Byte
23
Cmd
Response
SegmentNumber
of Bits
Bits
0 – 7
Bits
8 – 15
Bits
16 – 23
Bits
24 - 31
Bits
32 - 39
Bits
40 – 47
Bits
48 – 55
Bits
56 – 63
Bits
64 – 71
Terminator
R00“00” – “FF”“00” – “FF”“00” – “FF”“00” – “FF”“00” – “FF”“00” – “FF”“00” – “FF”“00” – “FF”“00” – “FF”“00” – “FF”Carriage Return (0x0d)
Bytes 0 & 1Byte 2Bytes 3-22Byte 23
CommandSegmentUnusedTerminator
G0'1'UnusedCarriage Return (0x0d)
Bytes
0 - 1
Byte
2
Bytes
3 - 4
Bytes
5 - 6
Bytes
7 - 8
Bytes
9 - 10
Bytes
11 - 12
Bytes
13 - 14
Bytes
15 - 16
Bytes
17 - 18
Bytes
19 - 20
Bytes
21 - 22
Byte
23
Cmd
Response
SegmentBits
56 - 63
Bits
64 - 71
Bits
72 - 79
Bits
80 - 87
Bits
88 – 95
Bits
96 – 103
Bits
104 - 111
Bits
112 - 119
Bits
120 – 127
Bits
128 – 135
Terminator
R01“00” – “FF”“00” – “FF”“00” – “FF”“00” – “FF”“00” – “FF”“00” – “FF”“00” – “FF”“00” – “FF”“00” – “FF”“00” – “FF”Carriage Return (0x0d)
Bytes
0 - 1
Byte
2
Bytes
3 - 4
Bytes
5 - 6
Bytes
7 - 8
Bytes
9 - 10
Bytes
11 - 12
Bytes
13 - 14
Bytes
15 - 16
Bytes
17 - 18
Bytes
19 - 20
Bytes
21 - 22
Byte
23
Cmd
Response
SegmentBits
72 – 79
Bits
80 - 87
Bits
88 – 95
Bits
96 – 103
Bits
104 - 111
Bits
112 - 119
Bits
120 – 127
Bits
128 – 135
Bits
136 – 143
Bits
144 – 151
Terminator
R01“00” – “FF”“00” – “FF”“00” – “FF”“00” – “FF”“00” – “FF”“00” – “FF”“00” – “FF”“00” – “FF”“00” – “FF”“00” – “FF”Carriage Return (0x0d)
Bytes 0 & 1Byte 2Bytes 3-22Byte 23
CommandSegmentUnusedTerminator
G0'2'UnusedCarriage Return (0x0d)
Bytes
0 - 1
Byte
2
Bytes
3 - 4
Bytes
5 - 6
Bytes
7 - 8
Bytes
9 - 10
Bytes
11 - 12
Bytes
13 - 14
Bytes
15 - 16
Bytes
17 - 18
Bytes
19 - 20
Bytes
21 - 22
Byte
23
Cmd
Response
SegmentBits
136 - 143
Bits
144 - 151
Bits
152 - 159
Bits
160 - 167
Bits
168 – 175
Bits
176 – 183
Bits
184 - 191
Bits
192 - 199
Bits
200 – 207
Bits
208 – 215
Terminator
R02“00” – “FF”“00” – “FF”“00” – “FF”“00” – “FF”“00” – “FF”“00” – “FF”“00” – “FF”“00” – “FF”“00” – “FF”“00” – “FF”Carriage Return (0x0d)
Bytes
0 - 1
Byte
2
Bytes
3 - 4
Bytes
5 - 6
Bytes
7 - 8
Bytes
9 - 10
Bytes
11 - 12
Bytes
13 - 14
Bytes
15 - 16
Bytes
17 - 18
Bytes
19 - 20
Bytes
21 - 22
Byte
23
Cmd
Response
SegmentBits
152 - 159
Bits
160 - 167
Bits
168 – 175
Bits
176 – 183
Bits
184 - 191
Bits
192 - 199
Bits
200 – 207
Bits
208 – 215
Bits
216 – 223
Bits
224 – 231
Terminator
R02“00” – “FF”“00” – “FF”“00” – “FF”“00” – “FF”“00” – “FF”“00” – “FF”“00” – “FF”“00” – “FF”“00” – “FF”“00” – “FF”Carriage Return (0x0d)
Bytes 0 & 1Byte 2Bytes 3-22Byte 23
CommandSegmentUnusedTerminator
G0'3'UnusedCarriage Return (0x0d)
Response (Segment 3): Card Type with Data enabled
Bytes
0 - 1
Byte
2
Bytes
3 - 4
Bytes
5 - 6
Bytes
7 - 8
Bytes
9 - 10
Bytes
11 - 12
Bytes
13 - 22
Cmd
Response
Segment Bits
216 - 223
Bits
224 - 231
Bits
232 - 239
Bits
240 - 247
Bits
248 – 255
  Terminator
R0 3 “00” – “FF” “00” – “FF” “00” – “FF” “00” – “FF” “00” – “FF”   Carriage Return (0x0d)
Bytes
0 - 1
Byte
2
Bytes
3 - 4
Bytes
5 - 6
Bytes
7 - 8
Bytes
9 - 22
Byte
23
Cmd
Response
SegmentBits
232 - 239
Bits
240 - 247
Bits
248 – 255
 Terminator
R03“00” – “FF”“00” – “FF”“00” – “FF” Carriage Return (0x0d)

Not all card types are longer than 128 bits. On these readers, reading segments 2 and 3 will generate the following error response:

Bytes 0 & 1Byte 2Bytes 3-22Byte 23
CommandSegmentUnusedTerminator
E0'2' OR '3'Copied from commandCarriage Return (0x0d)

PAS - Resend Last Data command

The reader normally (except when Silent Output is disabled) outputs the card data to USB “End Point 1” once for each read of the card. This command tells the reader to resend this data.

Command
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Unused Terminator
PAS Unused Carriage Return (0x0d)
Response
Byte
0-2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
Cmd Response Unused Terminator
RAS Unused Carriage Return (0x0d)

Card Data Response from End Point 1

If the reader is configured to return data on End Point 1 (Silent Output disabled), this section describes the format of the data returned when a card is detected in the field and the card contents retrieved.

Data Format

The data is returned as a series of 8 byte end point 1 packets.

The first 5 or 9 bytes consist of:

  • a Header indicating Data Response.
  • if Card Type with Data is enabled, the Card Type from which the data was retrieved.
  • the Data Size in bits.

This followed by the data bytes that will be sent from least significant to most significant bytes.

The final byte after the data will contain the terminator (0x0d).

If the PAD USB Packets configuration bit is set, the last packet will be padded to 8 bytes with 0x00.

Card Type with Data is Enabled

Bytes 0 – 2Bytes 3 - 4Bytes 5 – 6Byte 7
HeaderCard Type (High Byte)Card Type (Low Byte)Data Size in Bits High Nibble
“R00”“00” – “FF”“00” – “FF”“1” – “F”
Byte 0Bytes 1-2Bytes 3-4Bytes 5-6Byte 7
Data Size in Bits Low NibbleByte 0 of DataByte1 of DataByte 2 of DataByte 3 of data High Nibble
(if necessary)
“0” – “F”“00” – “FF”“00” – “FF”“00” – “FF”“0” – “F”, 0x0d, nothing or 0x00

Packet #’s 3 to 6 may or may not be sent depending on number of bits of Card Data and setting of Silent Output and Pad USB Packets configuration bits.

Bytes 8,
16, 25,
or 32
Bytes 9-10,
17-18,
or 25-26
Bytes 11-12,
10-20
or 27-28
Bytes 13-14,
21-22
or 29-30
Bytes 15,
23,
or 31
Byte 3,7,11,15 Low NibbleByte 4,8 or 12 of dataByte 5, 9 or 13 of dataByte 6, 10 or 14 of dataByte 7, 11 or 15 of data High Nibble
“0” – “F”, 0x0d, nothing or 0x00“00” – “FF”, 0x0d, nothing or 0x00“00” – “FF”, 0x0d, nothing or 0x00“00” – “FF”, 0x0d, nothing or 0x00“0” – “F”, 0x0d, nothing or 0x00

Card Type with Data is disabled

Bytes 0 – 2Bytes 3 - 4Bytes 5 – 6Byte 7
HeaderData Size in BitsByte 0 of DataByte 1 of Data High Nibble
“R00”“1A” – “FF”“00” – “FF”“0” – “F”
Byte 0Bytes 1-2Bytes 3-4Bytes 5-6Byte 7
Byte 1 of Low NibbleByte 2 of DataByte 3 of Data (if necessary)Byte 4 of DataByte 5 of data High Nibble
“0” – “F”“00” – “FF”“00” – “FF”“00” – “FF”, 0x0d, nothing or 0x00“0” – “F”, 0x0d, nothing or 0x00

Packet #’s 3 to 5 may or may not be sent depending on number of bits of Card Data and setting of Silent Output and Pad USB Packets configuration bits.

Bytes 8, 16, 25, or 32Bytes 9-10,
17-18, or 25-26
Bytes 11-12,
10-20 or 27-28
Bytes 13-14,
21-22 or 29-30
Bytes 15,
23, or 31
Byte 5,9,13 Low NibbleByte 6,10 or 14 of dataByte 7, 11 or 15 of dataByte 8, 12 of dataByte 9, 13 of data High Nibble
“0” – “F”, 0x0d, nothing or 0x00“00” – “FF”, 0x0d, nothing or 0x00“00” – “FF”, 0x0d, nothing or 0x00“00” – “FF”, 0x0d, nothing or 0x00“0” – “F”, 0x0d, nothing or 0x00

Example Responses

Bit Card Pad USB Packets disabled, Card Type with Data is enabled

Card Data = 0x1A200A, Card Type Indala ASP 26 bit

Bytes 0 – 2Bytes 3 - 4Bytes 5 – 6Bytes 7 - 8
HeaderCard Type (Low Byte)Card Type (High Byte)Data Size in Bits
“R00”“FD”“02”“1A”
Bytes 0 – 1Bytes 2-3Bytes 4-5Byte 6
Byte 0Byte 1Byte 2Terminator
“0A”“20”“1A”0x0d
80 Bit Card Pad USB Packets enabled, Card Type with Data is enabled

Card Data = 0x ED 31 41 59 26 53 58 97 FA CE, Card Type F801

Bytes 0 – 2Bytes 3 - 4Bytes 5 – 6Bytes 7 - 8
HeaderCard Type (Low Byte)Card Type (High Byte)Data Size in Bits
“R00”“F8”“01”“54”
Bytes 0 – 1Bytes 2-3Bytes 4-5Byte 6
Byte 0Byte 1Byte 2Byte 3
“CE”“FA”“97”"58"
Bytes 0 – 1Bytes 2-3Bytes 4-5Byte 6
Byte 4Byte 5Byte 6Byte 7
“53”“26”“59”"41"
Bytes 0 – 1Bytes 2-3Bytes 4-5Byte 6Byte 7
Byte 8Byte 9TerminatorPaddingPadding
“31”“ED”0x0d0x000x00

LED Control commands

The LED control commands are used to control the state of the LED of the reader. There are two commands: Get LED command to read the LED color for each reader operating state, and Set LED command to set the LED color for each operating state.

The reader has four possible LED colors. Setting both the green and red LED will display amber. Clearing both the green and red LED will turn off the LED.

When the reader is configured in Automatic LED mode, the LED color can be configured for each of the operating states of the reader as follows:

LED Color Configuration Byte Low Byte   LED Color Configuration High Byte
Unused Ready   Reading Good Bad Sending
Bits 7-2 Bit 1 Bit 0   Bit 7 Bit 6 Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 Bit 0
Unused Green Red   Green Red Green Red Green Red Green Red

Note: The default LED colors are:

  • Good Data: Green
  • Reading Data: Off
  • Sending Data: Amber
  • Reader Ready: Red

Note: The Bad bits (2, 3) of the LED Color Configuration Low Byte are ignored as the reader does not detect a bad card as being any different than no card present.

When the reader Automatic LED mode is disabled, the solution can use the Set LED command to turn the LED to its desired color.

GL0 - Get LED Configuration command

This command returns the current LED configuration in RAM. Bytes 3 through 6 of the Response Packet contain the color LED to display for each of the reader’s LED states. Both the red and green LEDs set indicate the LED is set to amber. Both the red and green LEDs clear indicate the LED is off.

Bytes 0 - 2Bytes 3 - 22Byte 23
CommandUnusedTerminator
GL0UnusedCarriage Return (0x0d)
Bytes 0 - 2Bytes 3 - 4Bytes 5 - 6Bytes 7 - 22Byte 23
Command ResponseLED Color Configuration High ByteLED Color Configuration Low ByteUnusedTerminator
RL0“00” – “FF”“00” – “03”Copied from CommandCarriage Return (0x0d)

Set LED configuration

Automatic Mode

For reader control of the LED colors, enable and then use the Set LED Configuration command to set the desired LED color for each of the reader states as follows:

Bytes 0 - 2Bytes 3 - 4Bytes 5 - 6Bytes 7 – 22Byte 23
CommandLED Color Configuration Byte High ByteLED Color Configuration Low ByteUnusedTerminator
SL0“00” –“FF”“00” – “03”“0000000000000000”Carriage Return (0x0d)
Solution Control

For solution control of the LED color, disable Automatic LED Mode and then use the Set LED Configuration command to set all of the LED states to the same color as follows:

Bytes 0 - 2Bytes 3 - 4Bytes 5 - 6Bytes 7 – 22Byte 23
CommandLED Color Configuration Byte High ByteLED Color Configuration Low ByteUnusedTerminator
SL0“00”“00”“0000000000000000”Carriage Return (0x0d)
Bytes 0 - 2Bytes 3 - 4Bytes 5 - 6Bytes 7 – 22Byte 23
CommandLED Color Configuration Byte High ByteLED Color Configuration Low ByteUnusedTerminator
SL0“55”"01"“0000000000000000”Carriage Return (0x0d)
Bytes 0 - 2Bytes 3 - 4Bytes 5 - 6Bytes 7 – 22Byte 23
CommandLED Color Configuration Byte High ByteLED Color Configuration Low ByteUnusedTerminator
SL0"AA""02"“0000000000000000”Carriage Return (0x0d)
Bytes 0 - 2Bytes 3 - 4Bytes 5 - 6Bytes 7 – 22Byte 23
CommandLED Color Configuration Byte High ByteLED Color Configuration Low ByteUnusedTerminator
SL0"FF""03"“0000000000000000”Carriage Return (0x0d)

Beeper Control commands

The Beeper Control commands allow a solution to control the beeps generated by the reader. These commands are only effective if the Automatic Beep Mode is disabled in the reader’s configuration (see Set Configuration command). There are two commands that solution can use to control the beep sequence of the reader: Beep Long and Beep Short commands.

Warning: Issuance of Beeper Control command after the issuance of the first Beeper Control command faster than the time it would take the beeps to complete for the first command will result in an undetermined number of beeps occurring.

BL# - Beep Long command

This command causes the reader to sound the beeper for 1 or 2 long time periods (375ms per time period per beep).

Bytes 0 & 1Byte 2Bytes 3 - 22Byte 23
CommandNumberUnusedTerminator
BL'1' or '2'UnusedCarriage Return (0x0d)
Bytes 0 & 1Byte 2Bytes 3 - 22Byte 23
Command ResponseNumberUnusedTerminator
RL'1' or '2'Copied from commandCarriage Return (0x0d)

BS# - Beep Short command

This command causes the reader to sound the beeper for 1, 2, 3, 4, or 5 short time periods (125ms per time period per beep).

Bytes 0 & 1Byte 2Bytes 3 - 22Byte 23
CommandNumberUnusedTerminator
BS'1' - '5'UnusedCarriage Return (0x0d)
Bytes 0 & 1Byte 2Bytes 3 - 22Byte 23
Command ResponseNumberUnusedTerminator
RS'1' - '5'Copied from commandCarriage Return (0x0d)

BV0 – Set Beeper Volume

This command has been added to adjust the beeper volume to one of four levels.

  • 0 – Off
  • 1 – Low
  • 2 – Medium
  • 3 – High (default)

When received, the beeper volume is written to RAM and will be in effect at the next beeper output. Execute the FW0 command to write the beeper volume to flash.

Note: If this command is issued to a HIP1 reader, the reader will respond with EV1.

Bytes 0 & 1Byte 2Bytes 3 - 22Byte 23
CommandVolUnusedTerminator
BV'0' - '3'UnusedCarriage Return (0x0d)
Bytes 0 & 1Byte 2Bytes 3 - 22Byte 23
Command ResponseVolUnusedTerminator
RV'0' - '3'UnusedCarriage Return (0x0d)

Appendix A: Supported Card Types

This appendix defines the supported card types of the HP Card Reader.

For the CE931A and CE983A the following table applies:

Card TypeCard Type Bytes
CE931A Only: iClass Secure Sector ID0100
CE983A Only: Legic Prime or Legic Advant CSN (ISO 14443A & ISO 15693A)0110

The following table indicates card name, card number, and readers it applies to. Please note that this may not be a complete list of cards supported, and information is subject to change. Cards currently supported include:

Card Type (Card Name)Card NumberHP HIP1 Card Reader CE983A (EOL)HP HIP1 Card Reader CZ208A (EOL)HP HIP2 Card Reader X3D03AHP HIP2 Card Reader 2FG93AHP Legic Card Reader 4QL32AFrequency
AwidFA02 XXX 13.56MHz
Cardax UIDF602 XXX 13.56MHz
Russwin UIDF612 XXX 125KHz
Casi- RuscoFC02 XXX 13.56MHz
CEPAS7A01  XX 13.56MHz
CotagDF01  XX 125KHz
Deister UIDF401 XXX 125KHz
Dimpna UIDF101  XX 125KHz
EM/Marin 410xFB01 XXX 125KHz
EM/Marin EM 410X AlternateFB02 XXX 125KHz
DIGITAG (RDR-6Exx Compatible)FB11 XXX 125KHz
Felicia (NFC 3)7C02  XXX13.56MHz
GProx-II UIDF503 XXX 125KHz
GProx-II IDF504  XX 125KHz
HID ProxEF04 XX  125KHz
HID Prox UIDEF01 XXX 125KHz
HID iClass CSN7D01 XXXX13.56MHz
HID iCLASS ID (HID iCLASS SE)0100  X  125KHz
HID iCLASS SEOS0101  X  125KHz
HiTag 1 / HiTag S (RDR-6Hxx Compatible)F302 XXX 125KHz
HiTag 1 Alternate (HiTag S Alternate)F304 XXX 125KHz
HiTag 2 Primary (RDR-6Hxx Compatible)F201 XXX 125KHz
HiTag 2 AlternateF204 XXX 125KHz
IDTeck/RF LogicsE401  XX 125KHz
ID TeckAlternateE402  XX 125KHz
Indala ASP UIDFD01 XXX 125KHz
Indala ASP 26 Bit (Motorola)FD02 XXX 125KHz
Indala ASP CustomFD04 XXX 125KHz
Indala ECR CustomFD05 XXX 125KHz
Indala/Motorola ASP+ UIDED02 XXX 125KHz
Indala ASP+ CustomED05 XXX 125KHz
ioProxF902 XX  125KHz
KantechF902 XX  125KHz
RDR-785X Equivalent (ISO-14443A CSN)6F01 XXXX13.56MHz
iCLASS CSN7D01 XXXX13.56MHz
ISO-14443A CSN7F21 XXXX13.56MHz
Legic Advant CSN7F01  X  13.56MHz
Legic Advant CSN / UID7F31  X X13.56MHz
aptiQ (Mifare )-CSN only7F01  X  13.56MHz
aptiQ (Mifare DESfire EV1)-CSN7F01  X  13.56MHz
DESFire CSN (NFC Type 4)7F01  X  13.56MHz
I-tag CSN7F11 XXXX13.56MHz
MIFARE Ultralight CSN (NFC Type 2)7F01  X  13.56MHz
MIFARE® Classic(32 bits) CSN7F01  X  13.56MHz
MIFARE® DESFire CSN7F01 XXXX13.56MHz
MIFARE® DESFire EV17F01  X  13.56MHz
Oyster7F01  XXX13.56MHz
aptiQ CSN (Mifare)7F41  XXX13.56MHz
aptiQ CSN (Mifare DESfire EV1)7F01  XXX13.56MHz
MiFare CSN (Phillips, NXP)7F41 XX  13.56MHz
MiFare Ultralight CSN7F51 XX  13.56MHz
MIFARE® Plus (NXP)7F21 XXXX13.56MHz
MIFARE® Plus (ENCENTUATE)7F21  XXX13.56MHz
MIFARE DESFIRE EV1 CSN0202   X 13.56MHz
MIFARE DESFire EV1 Secure File + CSN0202   X 13.56MHz
MIFARE DESFire EV1 Secure File Data0201   X 13.56MHz
ISO-14443B7B01  XXX13.56MHz
I-Code CSN7E01 XX  13.56MHz
Infineon my-d CSN7E11 XXXX13.56MHz
ISO-15693A CSN7E21 XX  13.56MHz
SecuraKey Etag CSN (Philips)7E31 XXXX13.56MHz
Tag-It7E41 XXXX13.56MHz
IsonasFA03  X  125KHz
Legic Standard CSN (Prime)7901    X13.56MHz
Legic Advant Secure Segment (Stamp)7803    X13.56MHz
Legic Prime CSN / UID7901    X13.56MHz
Legic Prime Secure Segment (Stamp)7803    X13.56MHz
Keri UID (RDR-6k8x Compatible)F802 XX  125KHz
Keri NXT UIDF801 XXX 125KHz
Keri NXT 26 BitEA02 XXX 125KHz
Pyramid NXT UIDEA11 XXX 125KHz
Pyramid NXT 26 BitEA12 XXX 125KHz
Farpointe Data NXT UIDEA21 XXX 125KHz
Farpointe Data NXT 26 BitEA22 XXX 125KHz
RDR-758x + Legic0110X   X13.56MHz
RDR-758x Expanded (758x Equivalent + 14443B, CEPAS, NFC1, NFC3 CSN)6F02   X 13.56MHz
RDR-758x + Legic (758x Expanded - NFC1 + Legic Prime/Advant CSN)6F03    X13.56MHz
SecuraKey -01EC01 XXXX125KHz
SecuraKey -02EB02 XXX 125KHz
Radio KeyEB02 XXX 125KHz
ReadyKey Pro UIDF004 XXX 125KHz
NexwatchF712 XX  125KHz
NexKeyF722 XX  125KHz
HoneywellF722 XX  125KHz
2Smart KeyF722 XX  125KHz
QuadrakeyF722 XX  125KHz
KeyMateF722 XX  125KHz
RosslareFB21 XXX 125KHz
ParadoxE902  XX 125KHz
CDVIE912  XX 125KHz
PosTechE922  XX 125KHz
Topaz CSN (NFC 1)7F02  XX 13.56MHz
NedapE301  XX 125KHz
UrmetFC03  XX 125KHz

Note: Readers with card type containing the word "UID" will produce data when a card is presented in the field, but cannot verify if data is intended to be read by the manufacturer of the card, or if the card is encrypted. The data is returned in its raw form with no attempt to decrypt or format the data per any algorithm.

Appendix B : Card Decoding By Reader Type

This appendix describes the data encoding mechanism used by the defined cards, and which reader supports them. Note that some cards share the same card type but have different data formats.

Warning: The information in this section is provided for reference only to provide the solution developer an understanding of the data encoding and decoding of the card data returned from the HP Card Reader. This information is subject to change and may not be current.

Algorithms and terms

The following terms are useful in understanding the card data formatting and algorithms to process the data used by HP card readers.

The basic format of a card is: <Leading Parity><Facility Code><ID><Trailing Parity>

A reader decoding algorithm would typically follow:

  1. Validate that there are at least 26 bits
  2. Strip off any leading parity
  3. Strip off any trailing parity
  4. Do Wiegand Processing : Invert, Reverse bits or Bytes as necessary (see below)
  5. Capture ID bits (least significant bits for the Card Reader) and decoded per the options listed below.
  6. Remaining bits are FAC and decode per the options below.

Card Decoding Options

  • Leading Parity - Strips this many bits from the most significant bits of the raw data. This happens before any FAC/Id processing
  • Trailing Parity - Strips this many bits from the least significant bits of the raw data. This happens before any FAC/Id processing
  • Send ID – If set (Yes) the ID will be separated from the Facility Code using ID bits for the ID. If not set (No), the facility code will not be separated and all of the data will be considered ID independent of the number of ID bits.
  • ID Bits – Decode this many bits as the ID. Use the remainder as the FAC. If Send ID is not set this setting is ignored.
  • Card Size - Number of bits on the card (including parity bits). This is used when Read Only Card Size is enabled.
  • Send FAC - Output the facility code. If Send ID is not set this setting is ignored.
  • FAC Hex - Output the facility code as a hexadecimal number.
  • Fixed FAC/ID - Output a fixed number of digits for the FAC and ID. If more characters are needed the output is leading zero padded. If fewer characters are specified that are in The FAC or ID then the FAC or ID is truncated.
  • FAC Digits - If Fixed FAC/ID is enabled then this is the number of digits to use for the FAC. If Send FAC is not enabled then the FAC will not be sent.
  • ID Digits - If Fixed FAC/ID is enabled then this is the number of digits to use for the ID.
  • FAC/ID Delimiter - Output this character between the FAC and ID when the Send FAC is enabled.
  • ID Hex - Output the ID in hex.
  • Read Only Card Size - When this is enabled only cards of Card Size bits are recognized by the reader.
  • 64 Bit Math - When this is enabled the reader performs 64 bit math on the FAC, ID or entire card. On some card readers this setting causes the reader to process 80 bits rather than 64. For Card Sizes where the ID or FAC can be greater than 32 bits, enabling this option is recommended. Use of 32 bit math for data longer than 32 bits was handled by converting the most significant 32 bits and least significant 32 bits separately and then padding the most significant digits with 10 zeros and then concatenating with least significant digits. For example a card id with 0x10379052B4 would be output as 160932205236 with 64 bit math disabled and 69651681972 with 64 bit math enabled.
  • Invert Wiegand Data - In some older Wiegand installations the Wiegand lines were reversed resulting in inverted data. Due to backwards compatibility with older legacy readers this is normally enabled.
  • Reverse Wiegand Bytes - When enabled this will reverse the data bytes before FAC/Id processing (after leading and trailing parity have been removed). This is mutually exclusive with Reverse Wiegand Bits. For example:
    • Data Before Processing:
      • 00 00 00 1C 33 7C
      • 00000000 00000000 00000000 00011100 00110011 01111100
    • Data After Reverse Byte Processing:
      • 7C 33 1C 00 00 00
      • 01111100 00110011 00011100 00000000 00000000 00000000
  • Reverse Wiegand Bits - When enabled this will reverse all the data bits before FAC/Id processing (after leading and trailing parity have been removed). This is mutually exclusive with Reverse Wiegand Bytes. For example:
    • Data Before Processing:
      • 00 00 00 1C 33 7C
      • 00000000 00000000 00000000 00011100 00110011 01111100
    • Data After Reverse Bit Processing:
      • 3E CC 38 00 00 00
      • 00111110 11001100 00111000 00000000 00000000 00000000

Appendix C: File and Key Blocks

Blocks were created to pass a block of information of variable size. Blocks come in
several types, each type has its own purpose. This is primarily to access additional data
on a 13.56MHz card (other than the CSN). It can be a key to access secure data, and/or
file information to describe, at a minimum, the location, offset and length of the data to
retrieve.

The SBL or GBL command is followed by 00 and an index. An index of 00 indicates the
header is being sent. An index of 01, up to FE, is used to send the block itself. FF is used
in an SBL transaction to indicate the block transfer is done and it is to be stored in RAM.
This still needs an FW0 command to store the block permanently in Flash.

ByteNameDescription
0TypeChoose from the pre-defined types, listed below
1IDAn identifier, use the card configuration number
2LenLength of the block (not including header or command bytes)
3BSVBlock-specific value, if more information needs to be conveyed
Bytes 0 - 2Bytes 3 - 4Bytes 5 - 6Bytes 7 - 8Bytes 9 - 10Bytes 11 - 12Bytes 13 - 23Byte 23
CommandUnusedIndexTypeID card ConfigBlock data length 12UnusedTerminator
SBL000002030C0000000000Carriage Return (0x0d)

Block Type 1 – Key

Key is stored using the ID number from the block header, typically on an NXP or SE chip. The data cannot be read back. No FW0 command is needed.

ByteNameDescription
4-ndataEntire block data section is the key. 16 bytes for AES, 6 bytes for Mifare Classic, etc.

Block Type 2 – MIFARE File

ByteNameDescription
0-3AIDApplication ID for EV1, ignored for MIFARE Classic
4FilenoFile number for EV1, block number for MIFARE Classic
5KeyRefReference number of key on reader to be used (should match
Key ID used to store the key)
6EncModeEncryption Mode: 00 = plain, 01 = MAC, 03 = Encrypted
7DataOffsetOffset from start of block or file for start of data to return
8DataLenNumber of data bytes to return
9KeyNumWhich key the card should use from its list
10AuthTypeAuthentication type: 02 = 2K3DES, 04 = 3K3DES, 09 =
AES128
11KeyDivKey diversification flag
12ReservedReserved

Block Type 3 – Reserved

This Block Type is reserved.

Block Type 4 – Legic File

Description of which stamp and how many bytes to return from a Legic card containing stamp data.

Note: Offset + DataLen must not be more than the total number of data bytes available, or no data is returned.

The ID from the block header is used to indicate the configuration (1-4). Length of the block is 16 byte pairs (using Printable ASCII Text).

ByteNameDescription
0-11StampStamp address
12SegmentSegment number
13StampLenLength of stamp (range 1 to 12), set MSb (0x80) to use Segment instead of Stamp address
14OffsetOffset from start of stamp data for first byte of returned data
15DataLenNumber of data bytes to return

Example Commands:

Bytes 0-2Bytes 3-4Bytes 5-6Bytes 7 - 8Bytes 9-10Bytes 11-22Byte 23
Set block CommandIndex 0 (Header)Block Type 4ID card 1Len 16 (0x10)Terminator
SBL000004011000000000Carriage Return (0x0d)
Bytes 0-2Bytes 3-4Bytes 5-6Bytes 7 - 22Byte 23
CommandUnusedIndex 1Stamp 67 00 00 08 (remaining 8 bytes of stamp are zero)Terminator
SBL00016700000800000000Carriage Return (0x0d)
Bytes 0-2Bytes 3-4Bytes 5-6Bytes 7 - 16Bytes 17-18Bytes 19-20Bytes 21-22Byte 23
CommandUnusedIndex 2Stamp RemainderStamp Len = 4Offset = 2Length = 7Terminator
SBL00020000000000040207Carriage Return (0x0d)
Bytes 0-2Bytes 3-4Bytes 5-6Bytes 7 - 22Byte 23
CommandUnusedIndex (store in RAM)UnusedTerminator
SBL00FF0000000000000000Carriage Return (0x0d)

Appendix D : Development Considerations

Though the example in this SDK shows how to interact with the HP Card Reader using the OXPd Accessories Service, this does not mean that the reader cannot be driven by an embedded solution where a product has an embedded SDK that supports controlling an USB HID Class device. This section describes some considerations for the various product platforms when doing either OXPd Accessories or embedded development.

General Considerations

The following recommendations are applicable to development using any of the platforms covered in this section:

  1. Unless a platform does not support Interrupt End Points, to achieve the best performance and minimize resource utilization, a solution should consider using Automatic Output to read the card data from the device using the interrupt End Point as polling using the G0# command will tend to be slower and more resource intensive. The default configuration of the device enables this mode of operation. This method requires the host to listen on Endpoint 1, but removes the latency inherent in the polled method. The Silent Mode bit in the Configuration Byte must be cleared to enable automatic output. Pad USB Packets is required when the host is running Microsoft Windows, but other operating systems may also have issues with short packets as well. Therefore, it is recommended to enable the Pad USB packets bit if automatic output is used.
  2. If polling the reader, a few commands must be sent in a specific order to ensure integrity of the card data:
    • Issue the QS0 command at least twice per second to check the data ready status.
    • When the QS0 response indicates that data is available, immediately issue a G00 to lock out any new card reads. Follow this with G01, G02 as necessary to receive all data bits.
    • Optional: Issue GQ0 to check the data age and overrun count, followed by CQ0 to clear the overrun count.
    • Issue a CD0 to clear the Data Available flag and unlock the reader. If the CD0 command is not issued, card reads will be disabled for 10 seconds.
  3. Unless a platform does not support reading and writing of Feature Reports, use of Feature reports should be considered for the configuration, flash/ram, beeper control and LED control commands. The default configuration of the device enables this mode of operation.
  4. Depending on the host platform being used, it may require a complete record of data before the USB driver will release the data to the application. If this is the case, the solution should configure the reader to Pad USB Packets.