AnsweredAssumed Answered

Configuration USB ports HS in FS mode

Question asked by le_cam.guillaume on Aug 12, 2011
Latest reply on Aug 24, 2011 by loeffel.raphael


I am working on USB applications on a STM32F207IG. The usb communication works in FS with the port PA9, PA11 and PA12, in HS with the ULPI. But I need to USE the ports PB13 (Vbus) , PB 14 (DM) and PB15 (DP). They are HS pins configured in FS mode.

Here how I configured these pins:

 RCC_AHB1PeriphClockCmd( RCC_AHB1Periph_GPIOB, ENABLE ); 
  GPIO_InitStructure.GPIO_Speed = GPIO_Speed_100MHz; 
  GPIO_InitStructure.GPIO_Mode = GPIO_Mode_AF; 
  GPIO_InitStructure.GPIO_OType = GPIO_OType_PP; 
  GPIO_InitStructure.GPIO_PuPd = GPIO_PuPd_NOPULL; 
  //Configure VBUS DM DP Pins 
  GPIO_InitStructure.GPIO_Pin = GPIO_Pin_13 | GPIO_Pin_14 | GPIO_Pin_15; 
  GPIO_Init( GPIOB, &GPIO_InitStructure ); 
  GPIO_PinAFConfig( GPIOB, GPIO_PinSource13, GPIO_AF_OTG2_FS );  // vbus 
  GPIO_PinAFConfig( GPIOB, GPIO_PinSource14, GPIO_AF_OTG2_FS ); // D- 
  GPIO_PinAFConfig( GPIOB, GPIO_PinSource15, GPIO_AF_OTG2_FS ); // D+ 
  RCC_APB2PeriphClockCmd( RCC_APB2Periph_SYSCFG, ENABLE ); 
  RCC_AHB1PeriphClockCmd( RCC_AHB1Periph_OTG_HS, ENABLE ); 

Unfortunatly, it is not working. Can you help me ?

Thank you.