DM163010 Microchip Technology, DM163010 Datasheet - Page 20

BOARD DEMO PICDEM USB

DM163010

Manufacturer Part Number
DM163010
Description
BOARD DEMO PICDEM USB
Manufacturer
Microchip Technology
Datasheet

Specifications of DM163010

Processor To Be Evaluated
PlC16C745/765
Interface Type
USB
Lead Free Status / RoHS Status
Lead free / RoHS Compliant
Lead Free Status / RoHS Status
Lead free / RoHS Compliant, Lead free / RoHS Compliant
PICDEM™ USB User’s Guide
DS41174A-page 16
2.1.6
0x05, 0x01
0x09, 0x05
0xA1, 0x01
0x09, 0x01
0xA1, 0x00
0x09, 0x30
0x09, 0x31
0x15, 0x00
0x26, 0xFF, 0x00
0x75, 0x08
0x95, 0x02
0x81, 0x02
0xC0
0x05, 0x09
0x19, 0x01
0x29, 0x06
0x15, 0x00
0x25, 0x01
0x75, 0x01
0x95, 0x06
0x81, 0x02
0x95, 0x02
0x81, 0x03
0xC0
This report descriptor describes the packet format for the USB data. The data
Gameport Translation
Translating the bits from the physical hardware to the USB buffer is very sim-
0 - 255, the descriptor calls for a range of 0 - 255. The descriptor, shown
below in HEX form, is in the gamepad descriptor file (usb_ch9.asm).
is filled from Least Significant Byte, Least Significant bit through to the Most
Significant Byte, Most Significant bit. The first field found will be the first bit/
byte. In the report descriptor above, the first data is 8 bits (the REPORT_SIZE
is 8) and it is the X axis (the first USAGE of the physical collection is X). So the
first byte on the bus will be the X axis value. The second byte will be the Y
axis. The third byte will be button A in bit 0, followed by button B in bit 1, and
so on. Because every USB transaction must be in whole number bytes, the
data is padded by one constant report, 2-bits long.
ple. Because we set the logical minimum and maximum to be 0 to 255, it
exactly matches the scaling of the analog-to-digital converter. So first, we
convert the X and Y axis and store the values in the first two buffer locations.
Secondly, we read the six buttons and store the values in the third buffer loca-
tion in bits 0-5. Lastly, we inform the serial interface engine that data is
available and wait for the host PC to come pick it up.
USAGE_PAGE (Generic Desktop)
USAGE (Game Pad)
COLLECTION (Application)
END_COLLECTION
USAGE (Pointer)
COLLECTION (Physical)
END_COLLECTION
USAGE_PAGE (Button)
USAGE_MINIMUM (Button 1)
USAGE_MAXIMUM (Button 6)
LOGICAL_MINIMUM (0)
LOGICAL_MAXIMUM (1)
REPORT_SIZE (1)
REPORT_COUNT (6)
INPUT (Data,Var,Abs)
REPORT_COUNT (2)
INPUT (Constant,Var,Abs)
USAGE (X)
USAGE (Y)
LOGICAL_MINIMUM (0)
LOGICAL_MAXIMUM (255)
REPORT_SIZE (8)
REPORT_COUNT (2)
INPUT (Data,Var,Abs)
©
2001 Microchip Technology Inc.

Related parts for DM163010