USB on-the-go full-speed (OTG_FS) RM0351
1628/1693 DocID024597 Rev 3
1. Put the core in the Global OUT NAK mode.
2. Disable the required endpoint
– When disabling the endpoint, instead of setting the SNAK bit in OTG_DOEPCTL,
set STALL = 1 (in OTG_DOEPCTL).
The STALL bit always takes precedence over the NAK bit.
3. When the application is ready to end the STALL handshake for the endpoint, the
STALL bit (in OTG_DOEPCTLx) must be cleared.
4. If the application is setting or clearing a STALL for an endpoint due to a
SetFeature.Endpoint Halt or ClearFeature.Endpoint Halt command, the STALL bit must
be set or cleared before the application sets up the Status stage transfer on the control
endpoint.
Examples
This section describes and depicts some fundamental transfer types and scenarios.
• Bulk OUT transaction
Figure 512 depicts the reception of a single Bulk OUT Data packet from the USB to the AHB
and describes the events involved in the process.
Figure 512. Bulk OUT transaction
After a SetConfiguration/SetInterface command, the application initializes all OUT endpoints
by setting CNAK = 1 and EPENA = 1 (in OTG_DOEPCTLx), and setting a suitable
XFRSIZ and PKTCNT in the OTG_DOEPTSIZx register.
069
LQLW BRXWBHS
2
8
7
$
&
.
5;)/9/ LQW UL
:UBUHJ27*B'2(376,=[
:UBUHJ27*B'2(3&7/[
E\WHV
2
8
7
1
$
.
[DFWB
;)5&
L
Q
W
U
;)56,=
U
LGOH XQWLO LQWU
UFYBRXW BSNW
LGOH XQWLO LQWU
2Q QHZ [IHU
RU 5[),)2
QRWHP SW\
;)56,=
E\WHV
3.7&17
(3(1$
&1$.
+RVW 86% 'HYLFH $SSOLFDWLRQ
3.7&17
27*B'2(3&7/[1$.