/* Configures the Internal High Speed oscillator to program/erase FLASH.  */
FLASH_HSICLOCK FLASH_ClockInit(void)
/* Configures the Internal High Speed oscillator to program/erase FLASH.  */
FLASH_HSICLOCK FLASH_ClockInit(void)
{
    bool HSIStatus = 0;
    __IO uint32_t StartUpCounter = 0;
    FLASH_HSICLOCK hsiclock_status = FLASH_HSICLOCK_ENABLE;
    if ((RCC->CTRL & RCC_CTRL_HSIRDF) == RESET)
    {
        RCC->CTRL |= ((uint32_t)RCC_CTRL_HSIEN);
        do
        {
            HSIStatus = RCC->CTRL & RCC_CTRL_HSIRDF;
            StartUpCounter++;
        } while ((HSIStatus == 0) && (StartUpCounter != HSI_STARTUP_TIMEOUT));
        HSIStatus = ((RCC->CTRL & RCC_CTRL_HSIRDF) != RESET);
        if (!HSIStatus)
        {
            hsiclock_status = FLASH_HSICLOCK_DISABLE;
        }
    }
    return hsiclock_status;
}