AT32WB415
Series Reference Manual
2022.04.13
Page 346
Ver 2.00
the port into test mode, and the port gives a corresponding
signal.
0000: Test mode disabled
0001: Test_J mode
0010: Test_K mode
0011: Test_SE0_NAK mode
0100: Test_Packet mode
0101: Test_Force_Enable
Others: Reserved
Bit 12
PRTPWR
0x0
rw
Port power
The application uses this bit to control power supply to this
port (by writing 1 or 0)
0: Power off
1: Power on
Note: This bit is not associated with interfaces. The
application must follow the programming manual to set this
bit for various interfaces.
Bit 11: 10 PRTLNSTS
0x0
ro
Port line status
Indicates the current logic status of the USB data lines.
Bit [10]: Logic level of D+
Bit [11]: Logic level of D–
Bit 9
Reserved
0x0
resd
Kept at its default value.
Bit 8
PRTRST
0x0
rw
Port reset
When this bit is set by the application, a reset sequence is
started on this port. The application must calculate the time
required for the reset sequence, and clear this bit after the
reset sequence is complete.
0: Port not in reset
1: Port in reset
The application must keep this bit set for a minimum
duration defined in Section 7.1.7.5 of USB 2.0 specification
to start a reset on the port. In addition to this, the
application can make this bit set for another 10 ms to the
minimum duration, before clearing this bit. There is no
maximum limit set by the USB standard.
Bit 7
PRTSUSP
0x0
rw1s
Port suspend
The application sets this bit to put this port in suspend
mode. In this case, the controller only stops sending SOF.
The application must set the port clock stop bit in order to
disable the PHY clock.
The read value of this bit reflects the current suspend
status of the port.
This bit is cleared by the controller when a remote wakeup
signal is detected or when the application sets the port
reset bit or port resume bit in this register, or sets the
resume/remote wakeup detected interrupt bit or
disconnect detected interrupt bit in the controller interrupt
register.
The controller can still clear this bit, even if the device is
disconnected with the host.
0: Port not in suspend mode
1: Port in suspend mode
Bit 6
PRTRES
0x0
rw
Port resume
The application sets this bit to drive resume signaling on
the port. The controller continues to trigger the resume
signal until the application clears this bit. If the controller
detects a USB remote wakeup sequence (as indicated by
the port resume/remote wakeup detected interrupt bit of
the controller interrupt register), the controller starts driving
resume signaling without the intervention of the
application.
The read value of this bit indicates wehter the controller is
currently driving resume signaling.
0: No resume triggered
1: Resume triggered