STM32P407: usbStart() not working

ChibiOS public support forum for topics related to the STMicroelectronics STM32 family of micro-controllers.

Moderator: RoccoMarco

Post Reply
jeremie.delaitre
Posts: 26
Joined: Fri Oct 05, 2012 3:16 pm
Been thanked: 1 time

STM32P407: usbStart() not working

Post by jeremie.delaitre »

Hi,

I'm trying to use the USB OTG (HS) of my Olimex STM32P407 board but calling usbStart(&USBD2, &myconf) never returns.

In otg_core_reset() (ChibiOS/os/hal/platforms/STM32/OTGv1/usb_lld.c, line 137), the core reset loop never ends:

Code: Select all

while ((otgp->GRSTCTL & GRSTCTL_CSRST) != 0)


Any idea?

(to be noted that I've modified the board to use SDIO instead of the SPI for the SDCard, but it doesn't seem to conflict with the USB OTG HS stuff)
User avatar
Giovanni
Site Admin
Posts: 14891
Joined: Wed May 27, 2009 8:48 am
Has thanked: 1202 times
Been thanked: 996 times

Re: STM32P407: usbStart() not working

Post by Giovanni »

It could be something in the board configuration, the driver does not exit from the SW reset procedure, the OTG could be stuck because some signal. Verify on the board schematic if there is something conflicting with the HS port.

Giovanni
jeremie.delaitre
Posts: 26
Joined: Fri Oct 05, 2012 3:16 pm
Been thanked: 1 time

Re: STM32P407: usbStart() not working

Post by jeremie.delaitre »

Thank you for the hint, and sorry for the late response :)
I've finally got some time to work on this and the problem was elsewhere... I just forgot to initialize properly some event sources...
Post Reply