cancel
Showing results for 
Search instead for 
Did you mean: 

Is it possible to setup a USB-C only power connection (fixed CC resistors) while having the USBPD lib active?

Lvan .4
Associate II

I have set up the USBPD lib on my system to manage USB power delivery messages and set up power contracts in both the source and sink directions. Now that this seems to work well, I also want the system to work with a USB-C only power source (non-PD).

I have a power source that is capable of supplying 3A at 5V, and have connected a 10K Rp resistor between a CC line and VBUS.

On connecting the source I expected (hoped) the USBPD stack to trigger a connection event, sample the CC lines and conclude that after a while of no CC responses end up in the USBPD_POWER_IMPLICITCONTRACT state based on the Rp resistor value. Instead it triggers a connect event and goes to the USBPD_POWER_DEFAULT5V state. Then after a while of no CC response it tries to hard-reset the bus and panics because the requested voltage (0V) does not match the bus voltage (5V).

So my question is how is this normally handled? Is is possible to have the USBPD stack be happy with a fixed Rp resistor, and is it possible for the USBPD stack to return the capabilities of that source (based on Rp) to the application?

I did find something in this wiki, but it skips using the USBPD stack alltogether while this is functionality that I also need to maintain. So that is not so useful to me.

1 ACCEPTED SOLUTION

Accepted Solutions
Nicolas P.
ST Employee

Hello @Lvan .4​ 

Yes this is normal. Your device gives the source the chance to send the source capabilities, if it can.

And after 3 hard reset (to try to wake the source up 🙂 ) he believes that the source is not PD compliant. There is no panic 🙂

You can see in picture below what is normal behavior.

0693W00000WL7w7QAD.pngDo you have the same trace ?

Then reading TYPEC_VSTATE_CC value in register UCPD_SR, you can know what is the Rp set by the source.

Hope this helps.

Regards,

Nicolas

View solution in original post

2 REPLIES 2
Nicolas P.
ST Employee

Hello @Lvan .4​ 

Yes this is normal. Your device gives the source the chance to send the source capabilities, if it can.

And after 3 hard reset (to try to wake the source up 🙂 ) he believes that the source is not PD compliant. There is no panic 🙂

You can see in picture below what is normal behavior.

0693W00000WL7w7QAD.pngDo you have the same trace ?

Then reading TYPEC_VSTATE_CC value in register UCPD_SR, you can know what is the Rp set by the source.

Hope this helps.

Regards,

Nicolas

Yes my program flow follows the same path as your trace shows. That clears it up a lot, thanks!