cancel
Showing results for 
Search instead for 
Did you mean: 

Resource Library

Change the PDO of CYPD3177 through I2C with a MiniProg3

YiZ_31
Moderator
Moderator

Change the PDO of CYPD3177 through I2C with a MiniProg3

CYPD3177(BCR) has provided four sets of resistor divider networks are used to determine the voltage and current range that the EZ-PD BCR device will negotiate

with the USB Type-C power adapter. However, if it still cannot meet your requirement, you can change the PDO through its I2C register.

This blog gives a breif introduction on how to change the BCR register based on BCR HPI Spec.

1. Hardware Connection

pastedImage_1.png

Figure 1

Connect SCLK and SDAT of MiniProg to CY4533 as is shown in Figure 1. Set the rotary switch (SW1) to position 1 so CY4533 support 5V/0.9A by default. Use a CY4500 EZ-PD Protocol Analyzer to capture the cc communication between CY4533 and the power adapter.

pastedImage_14.png

Figure 2

As is shown in Figure 2, CY4533 request 5V/0.9A due to the max requesting VBUS set by rotary switch is 5V/0.9A.

2. Send I2C command in Bridge Control Panel to control BCR

pastedImage_32.png

Figure 3

Check the PD_STATUS register first. The value of PD_STATUS register is 00 A4 05 00. It means the explicit contract has been established between BCR and the charger. BCR is acting as a power sink and the two device both supports PD 3.0. To replace the default sink PDO, write the corresponding packet into the data memory start from 0x1800. For Byte 0-3, ASCII string “SNKP” (i.e 0x50 0x4B 0x4E 0x53) must be sent to make BCR update its sink PDO list. In this example, PDO 0 is set to 5V/0.9A and PDO 1 is set to 15V/1.75A. The remaining bytes are set to 0 because not all 7 PDOs are used.  Refer to Section 6.4 of Universal Serial Bus Power Delivery Specification for the description of Fixed Supply PDO. Figure 3 is the I2C commands sent and response from BCR.

pastedImage_46.png

Figure 4

After enabling the PDO0 and PDO1 mask by sending command to SELECT_SINK_PDO register, BCR will re-negotiate the PD contract with the power adapter. PD_RESPONSE register should be checked after sending command on command registers. 0x02 is the code for successful operation.CC communication is captured by CY4500 in Figure 4.

0 Likes
Comments
dgi_4679526
New Contributor

I have a Samsung EP-TA845 45 Watt PPS adapter, its PDOs look like this:

1: fixed PDO; vol:5000mV, current:3000mA

2: fixed PDO; vol:9000mV, current:3000mA

3: fixed PDO; vol:15000mV, current:3000mA

4: fixed PDO; vol:20000mV, current:2250mA

5: augmented PDO; vol:3300mV ~ 11000mV, current:5000mA, pow_lim=1

6: augmented PDO; vol:3300mV ~ 16000mV, current:3000mA, pow_lim=1

7: augmented PDO; vol:3300mV ~ 21000mV, current:2250mA, pow_lim=1

I would very much like to select one point in PDO5: 6 Volts @ 5 Amps . Only (A)PDO #5 can fulfil that. Could you show the HPI sequence to do that? Since the first product feature on the ez-pd-barrel-connector-replacement-bcr page is "Supports USB Type-C and Power Delivery 3.0 Programmable Power Supply", I expect there is a way to do that. I'm just not smart enough to find out how (and I have tried). With another sink device based on a microcontroller and the FUSB302 I can indeed select that point and my DC load confirms it is delivering 5 Amps.

Also is there a corrected BCR HPI Spec document? The current one is riddled with mistakes. For example the very first command in 5.1 is RESET: "Address 0x0008 Size 1-byte"; that is followed by the field names showing a guard (0x52) byte and _another_ byte. That is a size of TWO.  Back in 4.1 it say the device_mode byte is 0x92, I see 0x95, and for the silicon_id I see 0x0420 . Are there different revisions of the CYPS3177 chip?

YiZ_31
Moderator
Moderator

Hi,

BCR does support PPS. But you'll have to send the Request message by HPI at runtime. It is not possible to simply send some commands then the BCR can support PPS by itself. You'll need an EC to access the HPI of BCR in order to support PPS.

Regards,

Eddie

dgi_4679526
New Contributor

Excuse my ignorance, what is an EC? Is that an "Explicit Contract" associated with the PPS "keep alive" mechanism? So is PPS possible with the BCR if a SoC talking to the HPI and responding to events as per the keep alive mechanism?

YiZ_31
Moderator
Moderator

EC is short for embedded controller.

According to PD spec:

The SinkPPSPeriodicTimer Shall be used by the Sink’s Policy Engine to ensure that communication between the Sink and Source occurs within a bounded time of tPPSRequest when in PPS operation. In the absence of any other traffic, a Request Message requesting a PPS APDO is sent periodically as a keep alive mechanism.

BCR is able to send these messages but you need a external controller to tell BCR when to send these messages.

Version history
Revision #:
1 of 1
Last update:
‎Mar 23, 2020 12:32 AM
Updated by:
 
Contributors