/* RNG MSP Initialization This function configures the hardware resources used in this example.  */
void HAL_RNG_MspInit(RNG_HandleTypeDef *hrng)
/* RNG MSP Initialization This function configures the hardware resources used in this example.  */
void HAL_RNG_MspInit(RNG_HandleTypeDef *hrng)
{
  RCC_PeriphCLKInitTypeDef PeriphClkInit = {0};
  if(hrng->Instance==RNG)
  {
    PeriphClkInit.PeriphClockSelection = RCC_PERIPHCLK_RNG;
    PeriphClkInit.RngClockSelection = RCC_RNGCLKSOURCE_HSI48;
    if (HAL_RCCEx_PeriphCLKConfig(&PeriphClkInit) != HAL_OK)
    {
      Error_Handler();
    }
    __HAL_RCC_RNG_CLK_ENABLE();
  }
}