Hi,
I’m trying to enable Selective Suspend for my device (a digitizer).
It has 2 HID endpoints, working with HIDClass.sys, and 1 bulk endpoint, working with a UMDF driver, based on the FX2 sample.
According to the post "How to enable USB selective suspend and system wake in the UMDF driver for a USB device "
I have added to the inf file the following lines:
[OsrUsb_Device_AddReg]
HKR,“LowerFilters”,0x00010008,“WinUsb” ; FLG_ADDREG_TYPE_MULTI_SZ | FLG_ADDREG_APPEND
HKR,“DeviceIdleEnabled”,0x00010001,1
HKR,“DefaultIdleState”,0x00010001,1
HKR,“DefaultIdleTimeout”,0x00010001,5000
HKR,“UserSetDeviceIdleEnabled”,0x00010001,1
HKR,“SystemWakeEnabled”,0x00010001,1
These entries were added in HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Enum\USB\VID_xxxx&PID_xxxx&MI_02\6&1832b87c&0&0002\DeviceParameters
I also enabled USB Selective Suspend setting in Vista’a control panel.
I attached a USB analyzer to see if the device enters suspend mode. I’ve waited the 5000msec specified in the inf, and it didn’t (I expected to see a trace such as Figure 3 which appears in the “Power saving of using USB Selective Suspend Support Whitepaper”, with a SET_FEATURE DEVICE_REMOTE_WAKEUP command, and later suspend. Remote Wakeup is enabled for this device in the device manager).
I also put a breakpoint in the firmware to see if enters this state. It didn’t reach it.
I uninstalled the bulk UMDF driver, to see if the HIDs alone, based on the standard HID driver will enter suspend after 5000msec. They didn’t.
I’ve noticed that in the registry entries of the HID eps, the values and keys specified above do not appear.
According to the Troubleshooting tip in the post, I found that:
The box: “Allow the computer to turn off this device to save power” is:
In the USB Root Hub the device is connected to: checked.
Under it, in USB Composite Device, there are no power options.
Under it, for the bulk driver the box appears and is checked.
For the HID endpoints, this box does not appear (No Power Management pane exists).
I checked my UMDF code, the driver does not try to claim power policy ownership, and I do not use power-managed queues.
My questions are:
- Should I enable somewhere Selective Suspend for the HIDs? BIOS\Registry perhaps?
- Is the test I perform (waiting for 5000msec and checking the trace in the USB analyzer\waiting for suspend state in the firmware) enough\correct? Is there a better test?
Thanks,
Gadi