2017-10-17 05:02 PM
2017-10-18 05:49 AM
Hello!
systick initialized inside HAL_Init function with HSI as clock source.
Your code stops HSI , so Systick stops.
You need to reinitialize Systick , after SystemClock_Config again.
HAL_SYSTICK_Config(HAL_RCC_GetHCLKFreq()/1000); HAL_SYSTICK_CLKSourceConfig(SYSTICK_CLKSOURCE_HCLK);
2017-10-18 10:49 AM
Yes, there is
RCC_OscInitStruct.HSEState = RCC_HSE_ON;
RCC_OscInitStruct.HSIState = RCC_HSI_OFF;�?�?
In my code, but isn't HSE, the external clock, running. Why doesn't timer tick work with external, high precision, crystal clock.
I went backwards fromHAL_Init function, but did not find anything about HSI or HSE. What did I miss?
I made these changes, but it did not help. I have also tried HSE_ON/OFF and HSI_ON/OFF
HAL_Init();
/* Configure the System clock to have a frequency of 216 MHz */
SystemClock_Config();
HAL_SYSTICK_Config(HAL_RCC_GetHCLKFreq()/1000);
HAL_SYSTICK_CLKSourceConfig(SYSTICK_CLKSOURCE_HCLK);
HAL_StatusTypeDef HAL_DeInit();
HAL_ResumeTick();
MX_ADC1_Init();
�?�?�?�?�?�?�?�?
With thanks
Leif M
2017-10-18 02:19 PM
hello!
I went backwards from HAL_Init function, but did not find anything about HSI or HSE.
After Reset the default clock source for Systick is HSI.
HAL_StatusTypeDef HAL_DeInit();
This function call, resets all peripherals and stops HAL's time base.
2017-10-18 04:26 PM