User manual

118 CY4672 Reference Design Guide, Document # 001-16968 Revision **
Software Guide
9.2.3.5 CHidTrayDevice Class Methods
The CHidTrayDevice class is derived from the CHidDevice class and is the class used to interface
with WirelessUSB devices.
9.2.3.6 CHidTrayManager Class Methods
The CHidTrayManager class is derived from the CHidManager class and is used to manage Wire-
lessUSB devices.
9.3 Development Environment
The following tools are required to build and develop the Wireless USB Software application.
Microsoft Visual C++ .NET
Windows Driver Development Kit (DDK)
A Microsoft Windows based PC is used for tool execution.
The Microsoft Visual C++ .NET solution file can be found at the following location:
.\WirelessUSBSysTray\WirelessUSBTray.sln
Table 9-8. CHidTrayDevice Methods
Method Type Description
RequestNewUsageValues() Public This method sets up and issues a Set Feature request to the HID
device, which now simply requests the wireless device to provide
an update of its battery level the next time it communicates with the
USB bridge.
UpdateUsageValues() Public This method retrieves the latest usage values from the USB
bridge, which includes wireless channel, wireless PN code, last
reported battery level, and signal strength.
UpdateDeviceInfo() Public This method makes a call to update the HID device usage values
and displays a warning message (if enabled).
GetUsageIDValue() Public This method extracts the value of the provided Usage ID from the
feature data.
VerifyHidDevice() Public This method is called to verify that the HID device is one that
should be added to the list; right now this is done by making sure
the
usage page reported is WIRELESSUSB_USAGEPAGE and
the
usage reported is either
WIRELESSUSB_USAGE_KEYBOARD or
WIRELESSUSB_USAGE_MOUSE.
Table 9-9. CHidTrayManager Methods
Method Type Description
NewHidDevice() Protected This method creates a new HID device, initializes it, and adds it to the
list of existing HID devices.
DeleteHidDevice() Protected This method removes the HID device from the list and deletes the
HID device.
[+] Feedback