Usb Hid Protocol; Hid Packeting; Sending Usb Hid Messages To The Host; Receiving Usb Data From The Host - Magtek iDynamo 5 Gen III Programmer's Manual

Secure card reader, commands
Hide thumbs Also See for iDynamo 5 Gen III:
Table of Contents

Advertisement

2 - Connection Types
2.4

USB HID Protocol

This section defines how the device communicates with the host over the USB HID interface.

2.4.1 HID Packeting

The data transmitted in commands, responses, and notifications can be substantial, with a size limit of 64
kilobytes (64K bytes). However, the USB HID interface utilized by V5 restricts messages to 64 bytes.
Therefore, to accommodate larger messages, we employ specific methods to segment them into multiple
64-byte packets. The segmentation approach varies depending on the message type to ensure
compatibility with legacy V5. Below is the core structure of a USB HID packet.
Table 2-2 HID Packet Definition
Data Offset
ID
2 bytes
2 bytes

2.4.2 Sending USB HID Messages to the Host

The device makes data available to the host using one or more Input Reports over a USB Interrupt IN
pipe. The host will poll the device at the configured Polling Interval to see if Input Reports are ready. The
device must respond to polls with a USB NAK when no Input Reports are available.
Data Messages sent by the device use Input Report ID 0x01.
Notification Messages sent by the device use Input Report ID 0x02.

2.4.3 Receiving USB Data from the Host

The host sends commands using a Set Feature Report and sends a Get Feature Report to the device to
retrieve a synchronous response when appropriate. Feature reports use report ID 0x01.
The host should send both Feature Report types using the default Control pipe using a blocking call to the
operating system's native USB libraries. The device NAKs the Status page of a Set Feature Report until
it finishes the requested operation, and if it does not respond, the operating system will generally time out
and report failure. This method ensures that as soon as the device has fulfilled the command request
embedded in the Set Feature Report, the host software can immediately call a follow-up Get Feature
Report to retrieve the command.
In very rare cases, the host may simply send a Get Feature Report directly without a preceding Set
Feature Report. The Commands documentation specifies these special cases if they exist.

2.4.4 Command Packets

Commands are sent to the device using USB Set Feature Reports using Report ID 1.
Table 2-3 Standard Command Format
Command
Parameter Data Len Parameter Data
2 bytes
2 bytes
Sending commands to the device over a packeted interface (maximum parameter size is 64k (0xFFFF).
Standard command format gets broken down into packets for interfaces that do not support unlimited
length messages. This is compatible with the V5 extended command protocol.
The number ranges shown in packets assume the interface is USB with a maximum message size of 64
bytes.
iDynamo 5 Gen III| Secure Card Reader | Programmer's Manual (COMMANDS)
Complete Data Len
2 bytes
0-64k bytes
Page 11 of 48 (D998200587-101)
Data Segment
varies

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the iDynamo 5 Gen III and is the answer not in the manual?

Questions and answers

Table of Contents