In addition to the control commands sent to Devices during operation, three unique signaling conditions can be issued by the Host: Reset, Suspend or Restore a suspended Device.
During the enumeration process the Host issues a Reset signal to the Device. This USB Reset is not to be confused with a hardware or power-on reset. The purpose of the USB Reset is to set the software state of the Device so enumeration can proceed.
Devices recognize a Reset condition when both D- and D+ are both held low (SE0) for 10 ms. In some cases the Device is able to detect the Reset within 2.5 µs, however the Host will maintain the Reset condition for the entire 10 ms.
To initiate a reset, D+ and D- are held low by the Hub. Having the Hub hold the data lines low allows the Host to continually service the other devices and avoid having Devices enter suspend mode for lack of activity on D+ and D-. The Host causes the Hub to reset a Device by issuing a SET_PORT_FEATURE(PORT_RESET) control command to the Hub.
A Device will enter the SUSPEND state when no start-of-frame signal is received for three consecutive frames. The application software running in the Device is usually notified when a Suspend occurs and may take action to reduce power consumption. When in Suspend mode the Device will draw no more than 50 ma. Suspended Devices are able to respond to Reset and Resume commands.
The Host can cause one enumerated Devices to be suspended by issuing a
SET_PORT_FEATURE(PORT_SUSPEND) control command to the Hub attached to the Device to be suspended.
The sequence to resume a Device's operation is to assert a K-state on D+ and D- for 20 ms. (The K-state is defined in the USB specification and is determined by the USB speed).
A Suspended device may be returned to an operating state (i.e. Resumed) in one of two ways:
- If the Device has the remote resume feature set after at least 5 ms in the Suspend state, the Device can initiate the process of resuming normal operation. To begin resumption the Device asserts the K-state on D+ and D- for between 1 and 15 ms. The Host ( ie. HUB) will detect this state and take over controlling D+ and D- in 1 ms for the remainder of the 20 ms. After 20 ms the Device will resume normal operation.
- The Host can resume a device by sending a CLEAR_PORT_FEATURE( PORT_SUSPSEND) to the Hub connected to the Device. This will cause the Hub to drive the K-state on D+ and D- for 20 ms.