cancel
Showing results for 
Search instead for 
Did you mean: 

RCC_PLLSAIConfig() function has bug in STM32F469I-Discovery

704932121
Associate
Posted on January 06, 2016 at 19:57

I'm working on a usb project based on the STM32F469I-Discovery.

My project use STM32F4xx_DSP_StdPeriph_Lib_V1.6.1, however it always occurs some error when usb device plugged.Finally, i find the function RCC_PLLSAIConfig() has bug.

void RCC_PLLSAIConfig(uint32_t PLLSAIN, uint32_t PLLSAIP, uint32_t PLLSAIQ, uint32_t PLLSAIR)

{

  /* Check the parameters */

  assert_param(IS_RCC_PLLSAIN_VALUE(PLLSAIN));

  assert_param(IS_RCC_PLLSAIP_VALUE(PLLSAIP));

  assert_param(IS_RCC_PLLSAIQ_VALUE(PLLSAIQ));

  assert_param(IS_RCC_PLLSAIR_VALUE(PLLSAIR));

  RCC->PLLSAICFGR = (PLLSAIN << 6) | (PLLSAIP << 16) | (PLLSAIQ << 24) | (PLLSAIR << 28);

}

The correct is that:

void RCC_PLLSAIConfig(uint32_t PLLSAIN, uint32_t PLLSAIP, uint32_t PLLSAIQ, uint32_t PLLSAIR)

{

  /* Check the parameters */

  assert_param(IS_RCC_PLLSAIN_VALUE(PLLSAIN));

  assert_param(IS_RCC_PLLSAIP_VALUE(PLLSAIP));

  assert_param(IS_RCC_PLLSAIQ_VALUE(PLLSAIQ));

  assert_param(IS_RCC_PLLSAIR_VALUE(PLLSAIR));

  RCC->PLLSAICFGR = (PLLSAIN << 6) | (((PLLSAIP >> 1) - 1) << 16) | (PLLSAIQ << 24) | (PLLSAIR << 28);

}

#stm32f469
2 REPLIES 2
Nesrine M_O
Lead II
Posted on January 07, 2016 at 11:40

Hi kaiqin.lin,

Thank you for your feedback. The issue has been reported internally.

-Syrine-

Nesrine M_O
Lead II
Posted on January 13, 2016 at 09:14

Hi kaiqin.lin,

Your reported issue is confirmed by our team and will be fixed in coming release of the STM32cubeF4 package.

Thank you very much for your contribution to the enhancement of our STM32 related solutions.

-Syrine-