HPRT

         Host Port Control and Status Register
      
Module Instance Base Address Register Address
i_usbotg_0_DWC_otg_intreg 0xFFB00000 0xFFB00440
i_usbotg_1_DWC_otg_intreg 0xFFB40000 0xFFB40440

Size: 32

Offset: 0x440

Access: RW

Important: The value of a reserved bit must be maintained in software. When you modify registers containing reserved bit fields, you must use a read-modify-write operation to preserve state and prevent indeterminate system behavior.
Bit Fields
31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16

Reserved

PrtSpd

RO 0x0

PrtTstCtl

RW 0x0

15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0

PrtTstCtl

RW 0x0

PrtPwr

RW 0x0

PrtLnSts

RO 0x0

RESERVED

RO 0x0

PrtRst

RW 0x0

PrtSusp

RW 0x0

PrtRes

RW 0x0

PrtOvrCurrChng

RW 0x0

PrtOvrCurrAct

RO 0x0

PrtEnChng

RW 0x0

PrtEna

RW 0x0

PrtConnDet

RW 0x0

PrtConnSts

RO 0x0

HPRT Fields

Bit Name Description Access Reset
18:17 PrtSpd
Port Speed (PrtSpd)
Indicates the speed of the device attached to this port.
 2'b00: High speed
 2'b01: Full speed
 2'b10: Low speed
 2'b11: Reserved
Value Description
0x0 High speed
0x1 Full speed
0x2 Low speed
0x3 Reserved
RO 0x0
16:13 PrtTstCtl
Port Test Control (PrtTstCtl)
The application writes a nonzero value to this field to put the
port into a Test mode, and the corresponding pattern is
signaled on the port.
 4'b0000: Test mode disabled
 4'b0001: Test_J mode
 4'b0010: Test_K mode
 4'b0011: Test_SE0_NAK mode
 4'b0100: Test_Packet mode
 4'b0101: Test_Force_Enable
 Others: Reserved
Value Description
0x0 Test mode disabled
0x1 Test_J mode
0x2 Test_K mode
0x3 Test_SE0_NAK mode
0x4 Test_Packet mode
0x5 Test_force_Enable
RW 0x0
12 PrtPwr
Port Power (PrtPwr)
The application uses this field to control power to this port (write 1'b1 to set to 1'b1
and write 1'b0 to set to 1'b0), and the core can clear this bit on an over current
condition.
 1'b0: Power off
 1'b1: Power on
Value Description
0x0 Power off
0x1 Power on
RW 0x0
11:10 PrtLnSts
Port Line Status (PrtLnSts)
Indicates the current logic level USB data lines
 Bit [10]: Logic level of D+
 Bit [11]: Logic level of D-
Value Description
0x1 Logic level of D+
0x2 Logic level of D-
RO 0x0
9 RESERVED
RESERVED
RO 0x0
8 PrtRst
Port Reset (PrtRst)
When the application sets this bit, a reset sequence is
started on this port. The application must time the reset
period and clear this bit after the reset sequence is
complete.
 1'b0: Port not in reset
 1'b1: Port in reset
The application must leave this bit Set For at least a
minimum duration mentioned below to start a reset on the
port. The application can leave it Set For another 10 ms in
addition to the required minimum duration, before clearing
the bit, even though there is no maximum limit Set by the
USB standard.This bit is cleared by the core even if there is
no device connected to the Host.
 High speed: 50 ms
 Full speed/Low speed: 10 ms
Value Description
0x0 Port not in reset
0x1 Port in reset
RW 0x0
7 PrtSusp
Port Suspend (PrtSusp)
The application sets this bit to put this port in Suspend
mode. The core only stops sending SOFs when this is Set.
To stop the PHY clock, the application must Set the Port
Clock Stop bit, which asserts the suspend input pin of the
PHY.
The read value of this bit reflects the current suspend status
of the port. This bit is cleared by the core after a remote
wakeup signal is detected or the application sets the Port
Reset bit or Port Resume bit in this register or the
Resume/Remote Wakeup Detected Interrupt bit or
Disconnect Detected Interrupt bit in the Core Interrupt
register (GINTSTS.WkUpInt or GINTSTS.DisconnInt,
respectively).This bit is cleared by the core even if there is
no device connected to the Host.
 1'b0: Port not in Suspend mode
 1'b1: Port in Suspend mode
Value Description
0x0 Port not in Suspend mode
0x1 Port in Suspend mode
RW 0x0
6 PrtRes
Port Resume (PrtRes)
The application sets this bit to drive resume signaling on the
port. The core continues to drive the resume signal until the
application clears this bit.
If the core detects a USB remote wakeup sequence, as
indicated by the Port Resume/Remote Wakeup Detected
Interrupt bit of the Core Interrupt register
(GINTSTS.WkUpInt), the core starts driving resume
signaling without application intervention and clears this bit
when it detects a disconnect condition. The read value of
this bit indicates whether the core is currently driving
resume signaling.
 1'b0: No resume driven
 1'b1: Resume driven
When LPM is enabled, In L1 state the behavior of this bit is as follows:
The application sets this bit to drive resume signaling on the port.
The core continues to drive the resume signal until a pre-determined time
specified in GLPMCFG.HIRD_Thres[3:0] field. If the core detects a USB remote
wakeup sequence, as indicated by the Port L1Resume/Remote L1Wakeup Detected 
Interrupt bit of the Core Interrupt register (GINTSTS.L1WkUpInt), 
the core starts driving resume signaling without application intervention
and clears this bit at the end of resume.This bit can be set by both core or application
and also cleared by core or application. This bit is cleared by the core even if there is
no device connected to the Host.
Value Description
0x0 No resume driven
0x1 Resume driven
RW 0x0
5 PrtOvrCurrChng
Port Overcurrent Change (PrtOvrCurrChng)
The core sets this bit when the status of the Port
Overcurrent Active bit (bit 4) in this register changes.This bit can be set only by the core and the application should write 1 to clear it
Value Description
0x0 Status of port overcurrent status is not changed
0x1 Status of port overcurrent changed
RW 0x0
4 PrtOvrCurrAct
Port Overcurrent Active (PrtOvrCurrAct)
Indicates the overcurrent condition of the port.
 1'b0: No overcurrent condition
 1'b1: Overcurrent condition
Value Description
0x0 No overcurrent condition
0x1 Overcurrent condition
RO 0x0
3 PrtEnChng
Port Enable/Disable Change (PrtEnChng)
The core sets this bit when the status of the Port Enable bit
[2] of this register changes.This bit can be set only by the core and the application should write 1 to clear it.
Value Description
0x0 Port Enable bit 2 has not changed
0x1 Port Enable bit 2 changed
RW 0x0
2 PrtEna
Port Enable (PrtEna)
A port is enabled only by the core after a reset sequence,
and is disabled by an overcurrent condition, a disconnect
condition, or by the application clearing this bit. The
application cannot Set this bit by a register write. It can only
clear it to disable the port by writing 1.. This bit does not trigger any
interrupt to the application.
 1'b0: Port disabled
 1'b1: Port enabled
Value Description
0x0 Port disabled
0x1 Port enabled
RW 0x0
1 PrtConnDet
Port Connect Detected (PrtConnDet)
The core sets this bit when a device connection is detected
to trigger an interrupt to the application using the Host Port
Interrupt bit of the Core Interrupt register (GINTSTS.PrtInt).This bit can be set only by the core and the application should write 1 to clear it.The application must write a 1 to this bit to clear the
interrupt.
Value Description
0x0 No device connection detected
0x1 Device connection detected
RW 0x0
0 PrtConnSts
Port Connect Status (PrtConnSts)
 0: No device is attached to the port.
 1: A device is attached to the port.
Value Description
0x0 No device is attached to the port
0x1 A device is attached to the port
RO 0x0