Mac OS X Reference Library Apple Developer
Search

IOUSBHIDDriver

Inherits from:
Declared In:

Overview

Driver that matches to USB HID devices.

Discussion

This class can be overriden to provide for specific behaviors.



Functions

SuspendPort

Suspends the port for this device or optionally sets a timeout to suspend after a period of inactivity.


SuspendPort


Suspends the port for this device or optionally sets a timeout to suspend after a period of inactivity.

public

virtual IOReturn SuspendPort( bool suspendPort, UInt32 timeoutMS = 0);
Parameters
suspendPort

Boolean value. true = suspend the port, false = resume the port.

timeoutMS

Value in milliseconds If value is non-zero, the port will be suspended after the timeout milliseconds have passed without any read completions.

Return Value

The IOReturn value from the IOUSBDevice::Suspend() call.

Discussion

This call can be used to immediately suspend/resume a port or to enable the suspension of the port after a period of inactivity. If called with suspendPort = true (no timeout parameter), the HID driver will immediately suspend the port, after aborting any outstanding reads on the interrupt pipe. If called with suspendPort = true and timeout != 0, it will suspend the port after the timeout number of ms have passed without any read completions. If called with suspendPort = false, the port will be immediately resumed and the reads will be re-issued. If a timeout was enabled, it will be cancelled.

 

Did this document help you? Yes It's good, but... Not helpful...

Last Updated: 2010-07-29