Files
@ 988bab1cb593
Branch filter:
Location: therm/clock.c - annotation
988bab1cb593
862 B
text/plain
Got things mostly compiling, disabled SPI and USB for now because of RAM overflow
988bab1cb593 988bab1cb593 8f02a0213d08 8f02a0213d08 8f02a0213d08 8f02a0213d08 8f02a0213d08 8f02a0213d08 8f02a0213d08 8f02a0213d08 8f02a0213d08 8f02a0213d08 8f02a0213d08 8f02a0213d08 8f02a0213d08 8f02a0213d08 8f02a0213d08 8f02a0213d08 8f02a0213d08 8f02a0213d08 8f02a0213d08 8f02a0213d08 8f02a0213d08 8f02a0213d08 8f02a0213d08 8f02a0213d08 8f02a0213d08 8f02a0213d08 |
#include "stm32f0xx_hal_conf.h"
void SystemClock_Config(void)
{
RCC_OscInitTypeDef RCC_OscInitStruct;
RCC_ClkInitTypeDef RCC_ClkInitStruct;
RCC_PeriphCLKInitTypeDef PeriphClkInit;
RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_HSI48;
RCC_OscInitStruct.HSI48State = RCC_HSI48_ON;
RCC_OscInitStruct.PLL.PLLState = RCC_PLL_NONE;
HAL_RCC_OscConfig(&RCC_OscInitStruct);
RCC_ClkInitStruct.ClockType = RCC_CLOCKTYPE_SYSCLK;
RCC_ClkInitStruct.SYSCLKSource = RCC_SYSCLKSOURCE_HSI48;
RCC_ClkInitStruct.AHBCLKDivider = RCC_SYSCLK_DIV1;
RCC_ClkInitStruct.APB1CLKDivider = RCC_HCLK_DIV1;
HAL_RCC_ClockConfig(&RCC_ClkInitStruct, FLASH_LATENCY_1);
PeriphClkInit.PeriphClockSelection = RCC_PERIPHCLK_USB;
PeriphClkInit.UsbClockSelection = RCC_USBCLKSOURCE_HSI48;
HAL_RCCEx_PeriphCLKConfig(&PeriphClkInit);
__SYSCFG_CLK_ENABLE();
}
|