AT32F425
Series Reference Manual
2022.03.30
Page 403
Ver 2.01
indicate normal completion of the transfer.
Bit 18: 0
XFERSIZE
0x00000
rw
Transfer size
For an OUT transfer, this field indicates the number of data
bytes the host sends during a transfer.
For an IN transfer, this field indicates the buffer size that
the application has reserved for the transfer.
For an IN transfer (periodic and non-periodic), the
application must program this field as an integer multiple
of the maximum packet size.
20.6.5 Device-mode registers
These registers are applicable in device mode only. They are not supported in host mode due to unknown
access results. Some of the registers affect all the endpoints, while some affect only one endpoint.
20.6.5.1 OTGFS device configure register (OTGFS_DCFG)
This register configures the controller in device mode after power-on or after certain control commands
or enumeration. Do not change this register after initial programming.
Bit
Register
Reset value
Type
Description
Bit 31: 13 Reserved
0x0110
resd
Kept at its default value.
Bit 12: 11 PERFRINT
0x0
rw
Periodic frame interval
This field indicates the time within a frame at which the
periodic frame end interrupt is generated. The application
can use this interrupt to determine if the synchronous
transfer has been completed in a frame.
00: 80% of the frame interval
01: 85% of the frame interval
10: 90% of the frame interval
11: 95% of the frame interval
Bit 10: 4
DEVADDR
0x00
rw
Device address
The application must program this field every time a
SetAddress command is received.
Bit 3
Reserved
0x0
resd
Kept at its default value.
Bit 2
NZSTSOUTHSHK
0x0
rw
Non-zero-length status OUT handshake
The application can use this field to select the handshake
the controller sends on receiving a non-zero-length data
packet during a control transfer’ status stage.
1: Send a STALL handshake on a non-zero-length status
OUT transfer and do not send the received OUT packet to
the application
0: Send the received OUT packet to the application (zero-
length or non-zero-length), and send a handshake based
on the NAK and STALL bits in the device endpoint control
register.
Bit 1: 0
DEVSPD
0x0
rw
Device speed
This field indicates the speed at which the application
needs the controller to enumerate, or the maximum speed
the application can support. However, the actual bus
speed is determined only after the entire sequence is
complete, and is based on the speed of the USB host to
which the controller is connected.
00: Reserved
01: Reserved
10: Reserved
11: Full speed (USB1.1 transceiver, clock is 48MHz)
20.6.5.2 OTGFS device control register (OTGFS_DCTL)
Bit
Register
Reset value
Type
Description
Bit 31: 12 Reserved
0x00000
resd
Kept at its default value.
Bit 11
PWROPRGDNE
0x0
wo
Power-on programming done
The application uses this bit to indicate that the register
configuration is complete after a wakeup from power-down
mode.
Bit 10
CGOUTNAK
0x0
wo
Clear global OUT NAK