2022-06-19 12:23 PM
Hi,
I have a NUCLEO-L552ZE-Q board and I am practicing/learning the USB-C protocol. All I need is to set the voltage of USB-C to a higher voltage that the charger is capable of. The default is set to 5v.
In my situation, the adapter can supply up to 12v. Below is the traces taken from Nucleo UCPD software. I am wondering how could I set the voltage of USB, either with this app or using commands. The firmware I am using is USB-PD_consumer_1port.
Thanks,
Amir
2022-06-20 10:44 AM
I could set the voltage to the highest level that the adapter is able to provide, following this tutorial:
https://wiki.st.com/stm32mcu/wiki/STM32StepByStep:Getting_started_with_USB-Power_Delivery_Sink
However, this does not set the voltage automatically whenever I plug the USB and needs me to restart the MCU sometimes. I'm wondering if you know the reason and if there is a way to set switch between voltages instead of selecting the highest voltage that this tutorial does.
Thanks
2022-06-28 10:02 AM
Hello @ashah.16
Have you looked at the wiki on PDO selection ?
In the above trace we see that you request PDO1 ie 5V.
Please share your new trace (.cpd file, using our tool) to see why you loose your contract.
Regards,
Nicolas
2022-06-29 08:55 AM
Hi Nicholas,
Thanks for the reply. Yes, I checked these and other links before posting. I added two other acceptable voltages to the list of PDOs in the Cube app for the NUCLEO-L552ZE board I have. The example code I have (USB-PD-1consumer-1port) could agree on higher voltages. However, it is not smooth. I had to restart the board or plug-unplug the cable sometimes.
It is a bit confusing for me. I was going to have a code setup from scratch, using the CUBE, and following every setting of this Example code, and I couldn't make an agreement for higher voltages. I can't understand what is going on there but I will get back to this post once I found more. Meantime, can you suggest me if there are more examples or any advice for making my own code?
Thanks
2022-07-25 07:06 PM
Dear @Nicholas
Back to this post, I wanted to know if having USB-Interface IC (such as TCPP03-M20) is mandatory for USB-PD communication between STM32L552 and USB-C adapter? I am a bit lost knowing which one of your chips is required. Could you please recommend one or more of these interface ICs that is in stock and production?
Thanks,
Amir
2022-07-26 12:53 AM
Dear @ashah.16
I think you tagged the wrong person. Anyways, I think the TCPP03-M20 just acts as a protection circuit for your USB-C. :)
Thanks,
Nicholas Ng
2022-07-27 12:22 AM
Dear Amir,
TCPP IC are required to protect system (ESD, OVP, OCP, OTP on CC and Vbus lines). They also embed specific features related to Type-C connector (HV interface, Vconn switch, …).
The table below shows features by product.
You can notice that each TCPP corresponds to a use-case :
However, TCPP03-M20 can be use for SINK as it embeds Dead batteries resistors and Vbus current specific features that are not present on TCPP01-M12 (OCP and current sense).
Best regards,
Mathieu
2022-07-27 12:26 AM
Thanks @MROUV.1
Dear @ashah.16 , have you solved the original issue ? Can you share a .cpd trace ?
If you are ok, we could close this thread and open a new one to make the thread clear ?