cancel
Showing results for 
Search instead for 
Did you mean: 

Is there an example for the ll_ucpd driver?

MCseh.377
Associate II

I am developing on the STM32U5 family and i need to use UCPD. As far as I know the UCPD middleware is no supported on this family, so I need to implement my functionality using the LL driver for the UCPD module. I am not experienced with usb power delivery. It would be nice to see and example of the ll_ucpd usage.

1 ACCEPTED SOLUTION

Accepted Solutions

Hi @MCseh.377​ 

It looks like a link problem. Undefined symbols as USBPD_PE_Init, are expected to be present in the USBPD Core library.

Please check that you have such lib in the objects of your project : below picture is an example of USBPD MW lib in case of IAR Ewarm project.


_legacyfs_online_stmicro_images_0693W00000biUp5QAE.pngRegards

View solution in original post

3 REPLIES 3
Guenael Cadier
ST Employee

Hi @MCseh.377​ 

I confirm that STM32U5 embeds a UCPD peripheral for USB Power Delivery feature support. The STM32CubeU5 package contains USBPD Middleware (USB Power Delivery Stack + U5 Device) that is illustrated in some USBPD applications running on STM32U5 boards.

USBPD Middleware is provided in following directory in the STM32CubeU5 package : Middlewares\ST\STM32_USBPD_Library or here on Github.

Application example are provided for each board in Projects\<Board Name>\Applications\USBPD directory. For example you could find an example of a SNK application for STM32U5 Discovery board (B-U585I-IOT02A) here.

Regards

MCseh.377
Associate II

Thank you @Guenael Cadier​ for your help,

I checked the example and I followed this tutorial to set up my usbpd sink device:

https://youtu.be/-vsJhNIaHxE

However after code generation i cannot build the project.

I am using STM32U575-Nucleo board, building it with the cubemx generated Makefile.

I get the following errors:


_legacyfs_online_stmicro_images_0693W00000biUYjQAM.pngI don't find definitions for these functions, only declarations in the header files.

Can you help me where I messed up? :)

Thanks and best regards,

Mark

Hi @MCseh.377​ 

It looks like a link problem. Undefined symbols as USBPD_PE_Init, are expected to be present in the USBPD Core library.

Please check that you have such lib in the objects of your project : below picture is an example of USBPD MW lib in case of IAR Ewarm project.


_legacyfs_online_stmicro_images_0693W00000biUp5QAE.pngRegards