Table 222. Resume Event Detection - ST STM32G0 1 Series Reference Manual

Table of Contents

Advertisement

RM0444
[RXDP,RXDM] status
A device may require to exit from suspend mode as an answer to particular events not
directly related to the USB protocol (for example a mouse movement wakes up the whole
system). In this case, the resume sequence can be started by setting the L2RES bit in the
USB_CNTR register to 1 and resetting it to 0 after an interval between 1 ms and 15 ms (this
interval can be timed using ESOF interrupts, occurring with a 1 ms period when the system
clock is running at nominal frequency). Once the L2RES bit is clear, the resume sequence is
completed by the host PC and its end can be monitored again using the RXDP and RXDM
bits in the USB_FNR register.
Note:
The L2RES bit must be anyway used only after the USB peripheral has been put in suspend
mode, setting the SUSPEN bit in USB_CNTR register to 1.
Suspend and resume in Host mode
The basics of the suspend and resume mechanism has been described in the previous
section.
From the host stand-point, suspend is entered by writing the SUSPEN bit in USB_CNTR.
When suspend entry is confirmed, SUSPRDY (also in USB_CNTR) is set.
Once in suspend, and when the application want to resume the bus, this can be done by
setting the L2RES bit in USB_CNTR to 1.
Below in
According to the different line states after a wakeup event, the interpretation of the event
and the suggested behavior are shown. Note that, this table here is somewhat expanded
when compared to the previously shown device table, as the host may encounter both full
speed and low speed devices which use different line states for both suspend and resume.
Universal serial bus full-speed host/device interface (USB)

Table 222. Resume event detection

"00"
Root reset
"10"
None (noise on bus)
"01"
Root resume
"11"
Not allowed (noise on bus)
Table
223, the different actions recommended after a wakeup event are indicated.
Wakeup event
RM0444 Rev 5
Required resume software action
None
Go back in Suspend mode
None
Go back in Suspend mode
1281/1390
1307

Hide quick links:

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the STM32G0 1 Series and is the answer not in the manual?

Questions and answers

Subscribe to Our Youtube Channel

Table of Contents

Save PDF