Universal Serial Bus OTG Controller
UG0331 User Guide Revision 15.0
297
POWERDWN then remains asserted until power is removed from the bus (indicating that the device
has been disconnected); or resume signaling; or reset signaling is detected on the bus.
•
Sending Resume Signaling:
When resume signaling occurs on the bus, first CLK must be
restarted, if necessary. The USB controller then automatically exits in Suspend mode. If the resume
interrupt is enabled, an interrupt is generated.
•
Initiating a Remote Wake-Up: If a remote wake-up is initiated by the software while the USB
controller is in Suspend mode, it should write to
to set the resume bit
to ‘1’.
Note:
If CLK has been stopped, it must be restarted before this write can occur. The software should leave this
bit set for approximately 10 ms (minimum of 2 ms, a maximum of 15 ms) before resetting it to 0. By this
time the hub should have taken over driving and resume signaling on the USB. Resume interrupt is not
generated when the software initiates a remote wake-up.
Suspend/Resume When Operating as a Host
•
Entry into Suspend mode:
When operating as a host, the USB controller can be prompted to go
into Suspend mode by setting the Suspend mode bit in
. When this bit
is set, the USB controller completes the current transaction, then stops the transaction scheduler
and frame counter. No further transactions are started and no SOF packet is generated.
If the Enable SuspendM bit in POWER_REG is set, the UTMI+ PHY goes into Low power mode;
when the USB controller goes into Suspend mode and stops XCLK.
•
Sending Resume Signaling:
When the application requires the USB controller to leave Suspend
mode, it must clear the Suspend mode bit and set the resume bit in the POWER_REG, and leave it
set for 20 ms. while the resume bit is high, the USB controller generates resume signaling on the
bus. After 20 ms, the Cortex-M3 processor or fabric master should clear the resume bit, at which
point the frame counter and transaction scheduler are started.
•
Responding to Remote Wake-Up:
If resume signaling is detected from the target while the USB
controller is in Suspend mode
,
the UTMI+ PHY is brought out of Low power mode and restarts
XCLK. The USB controller then exits Suspend mode
and automatically sets the Resume bit in
POWER_REG to ‘1’ to take over generating the resume signaling from the
target. If the resume
interrupt is enabled, an interrupt is generated.
10.2.3.3.2 Suspend/Resume by an LPM Transaction (L0 to L1 State Transition)
Suspend/Resume When Operating as a Peripheral
•
Entry into Suspend mode:
When operating as a peripheral, the USB controller never initiates an
LPM suspend (transition from the L0 state to the L1 state). Rather, the USB controller only suspends
at the request of the host. However, for this to occur, the LPM feature must be enabled by setting up
LPM_CTRL_REG (0x40043362)(Peripheral)
appropriately. The LPMEN field in LPM_CTRL_REG is
used to enable the extended and LPM transactions. The LPMXMT field in LPM_CTRL_REG is used
to instruct the hardware that it is ready to suspend and to respond to the next LPM transaction with
an ACK. In this case, the USB controller responds to the next LPM transaction with an ACK, if all
other conditions are met. The response to an LPM transaction by the USB controller is summarized
in the following table.
Table 193 •
Response to LPM Transaction as Peripheral
LPMXMT
LPMEN
Data Pending (Data Resides in
Transmit FIFOs)
Response to the Next LPM
transaction
1'b0
00
Don't Care
Timeout
1'b0
10
1'b1
00
1'b1
10
1'b0
01
Don't Care
STALL
1'b1