Microchip Technology MPLAB Starter Kit for PIC18F MCU DM180021 DM180021 User Manual

Product codes
DM180021
Page of 46
The Demonstration Application
© 2009 Microchip Technology Inc.
 
DS51852A-page 13
2.4
USB HID CUSTOM DEVICE DEMO
The HID Custom Device demo enables generic USB data transfer to and from an 
attached device. Although the HID class normally is used for interface products, such 
as keyboards and mice, the HID interface can also be used for other data transfer 
purposes. The precompiled application provided with the starter kit is meant to be used 
with the PC application project, HID PnP Demo.exe, provided on the CD-ROM disc 
that comes with the kit.
If the USB device has been plugged in and has successfully enumerated, the device 
should be detected automatically by the demo PC application. Figure 2-5 shows how 
the PC application appears in Windows XP.
After the device enumerates, the PC application reads the raw data from the touch 
pads, the accelerometer (three axes acceleration and temperature) and the 
potentiometer. The state of the touch pads (pressed or not) is displayed in the Visual 
tab; all of the raw data is displayed in the Numeric tab.
FIGURE 2-5:
HID DEMO APPLICATION, VISUAL (LEFT) AND 
NUMERIC TABS