Hi Yannis,
I verified your branch with samples/subsys/usb/cdc_acm on my customized STM32F429 board, and found enumeration issues:
[6176209.029339] usb 1-1.5.2.1: new full-speed USB device number 30 using ehci-pci
[6176209.437330] usb 1-1.5.2.1: device not accepting address 30, error -32
[6176209.525325] usb 1-1.5.2.1: new full-speed USB device number 31 using ehci-pci
[6176209.933339] usb 1-1.5.2.1: device not accepting address 31, error -32
[6176209.933545] usb 1-1.5.2-port1: unable to enumerate USB device
I double checked your code again and found you removed the following two lines on the line 247 which I had recommended:
LL_AHB1_GRP1_DisableClockLowPower(RCC_AHB1LPENR_OTGHSULPILPEN);
LL_AHB1_GRP1_EnableClockLowPower(RCC_AHB1LPENR_OTGHSLPEN);
Without these two lines, the USB_OTG_HS port doesn't work, can't be enumerated.
After adding those two lines, the usb was correctly enumerated and the cdc_acm works well:
[6176395.476959] usb 1-1.5.2.1: new full-speed USB device number 32 using ehci-pci
[6176395.587715] usb 1-1.5.2.1: New USB device found, idVendor=2fe3, idProduct=0100
[6176395.587729] usb 1-1.5.2.1: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[6176395.587732] usb 1-1.5.2.1: Product: Zephyr CDC ACM sample
[6176395.587734] usb 1-1.5.2.1: Manufacturer: ZEPHYR
[6176395.587736] usb 1-1.5.2.1: SerialNumber: 0.01
[6176395.588150] cdc_acm 1-1.5.2.1:1.0: ttyACM2: USB ACM device
So, can you add those two lines back to your branch?
Best Regards,
Jun
On 7/10/18, 01:30, "devel@... on behalf of Yannis Damigos" <devel@... on behalf of giannis.damigos@...> wrote:
Hi Jun and Aurelien,
I created the following branch in my repository to add support for OTG
HS: https://github.com/ydamigos/zephyr/commits/stm32_otg_hs
It was tested on stm32f429 SoC by Jun and on STM32F723E-DISCO by Aurelien.
I updated my repository following your comments. Could you test it
again because I don't have the hw?
Before opening a PR upstream I would like to add support for the
boards you tested it. Could you open a pull request to my branch?
Please note that only one interface should be enabled at a time, OTG
FS or OTG HS. The driver will raise an error if both are enabled.
The USB API should change if we want to have them both enabled.
Yannis