cancel
Showing results for 
Search instead for 
Did you mean: 

usbpd change from sink to source soft reset

H V N D
Associate II

my stm32 set default is sink. when Phone connected, it's sink and the nego finish. after that, I change it to source to charge this phone, but it's soft reset.

please refer trace attach

5 REPLIES 5
H V N D
Associate II

@Yohann M.​  this is behavior:

  • In DRP mode, if STM32 is fixed SRC default, soft reset appear
  • If STM32 is fixed SNK default, soft reset not appear, I can Power Role Swap anytime

Please tell me the reason

thanks

Nicolas P.
ST Employee

Hello HVND.

Thanks for the trace.

The soft reset is sent because the accept from the source comes too late.

The accept should come between 24 and 30ms.

Here we get it 51ms after the power role swap request is sent. What is the phone used ?

I see no link with the default role.

What is the MCU used ? (SYSTICK value ?)

Hi @Nicolas P​ 

I'm testing with Xiaomi Redmi Node 7

SYSTICK  I fix PLL 64Mhz

Do you have another device to test with ?

Do you have an another external tool to have a protocol trace ?

Yohann M.
ST Employee

Dear @H V N D​ 

Regarding your SOFT reset, what it is strange is that the port partner answers to the power role swap after the expiration of the tSenderResponse timer (set to 27ms in our library). It is why we have a soft reset after receiving the accept message:

0693W000002ljoNQAQ.png

ACCEPT is received 50ms after the gooodCRC of PR_SWAP.

Problem is linked to your port partner.

Can you try to test with another port partner?

Regards

Yohann