上行端口,可以理解为 Device。UFP 从 VBUS 中取电,并可提供数据。典型设备是 U 盘,移动硬盘。
(3)DRD(Dual Role Data)
双角色端口,DRD 既可以做 DFP 也可以做 UFP,也可以在 DFP 与 UFP 间动态切换。
Type-C 的 Power Role
根据 USB PORT 的供电(受电)情况,USB Type-C 将 port 划分为 Source、Sink 、DRP(Dual-Role-Power)
姓名
年龄
Sink
Port asserting Rd on CC and when attached is consuming power from VBUs
Source
Port asserting Rp on CC and when attached is providing power over VBus
DRP(Dual-Role-Power)
A USB port that can operate as either a Source or a Sink
4、硬件原理图
5、Type-C Data Bus Routing
6、Type-C Attach/Detach Detection
代码语言:javascript
复制
Pull-Up Resistance (Rp)
Power: Source,Provider
Data: DFP,Host
Vconn Source: for eMark IC
Pull-Down Resistance (Rd)
Power: Sink, Consumer
Data: UFP,Device
功能图详细说明
Source
initially the Source has VBUS disabled.
The Source supplies pull-up resistors (Rp) on CC1 and CC2 and monitors both to detect a Sink. The presence of an Rd pull-down resistor on either pin indicates that a Sink is being attached. The value of Rp indicates the initial USB Type-C Current level supported by the host.
The Source uses the CC pin pull-down characteristic to detect and establish the correct routing for the USB SuperSpeed data path and determine which CC pin is intended for supplying VCONN.
Once a Sink is detected, the Source enables VBUS and VCONN.
The Source can dynamically adjust the value of Rp to indicate a change in available USB Type-C Current to a Sink.
The Source monitors the continued presence of Rd to detect Sink detach. When a detach event is detected, the Source removes, if supplied, VBUS and VCONN, and returns to step 1.
If the Source supports advanced functions (USB Power Delivery and/or Alternate Modes), USB PD communication is required.
Sink
The Sink terminates both CC1 and CC2 to GND using pull-down resistors.
The Sink determines that a Source is attached by the presence of power on VBUS.
The Sink uses the CC pin pull-up characteristic to detect and establish the correct routing for the USB SuperSpeed data path.
The Sink can optionally monitor CC to detect an available higher USB Type-C Current from the Source. The Sink shall manage its load to stay within the detected Source current limit.
If the Sink supports advanced functions (USB Power Delivery and/or Alternate Modes), USB PD communication is required.
The Source supplies pull-up resistors (Rp) on CC1 and CC2
The Sink supplies pull-down resistors (Rd) on CC1 and CC2
After Source detect Rd on CC (Sink is detected), the Source enables VBUS
7、Timing Parameters
8、State Diagram
代码语言:javascript
复制
1. No TA/Device Connected、Detached or cable only
HW-DRP toggling
SW-idle
2.TA Connected stage1
HW-detected Rp/Rd,expose as Sink/Source,alert SW cc-change
SW-receive cc-change, waiting for tCCDebounce to make sure it's not a noise
3.TA Connected stage2
HW-detected Vbus_valid alert SW ps_change
SW-after tCCDebounce, check vbus; if valid alert system TA connected and start PD communication;