I'm unable to run Chibios on custom board with STM32F103 MCU. The board has external 10 MHz high speed clock and according to the datasheet stm32f103 has maximum operating frequency 72 MHz which I was unable to achieve with 10 MHz so I decide to switch in to Internal 8 MHz clock. Here is my mcucfg.h settings:
Code: Select all
/*
* HAL driver system settings.
*/
#define STM32_NO_INIT FALSE
#define STM32_HSI_ENABLED TRUE
#define STM32_LSI_ENABLED FALSE
#define STM32_HSE_ENABLED FALSE
#define STM32_LSE_ENABLED FALSE
#define STM32_SW STM32_SW_PLL
#define STM32_PLLSRC STM32_PLLSRC_HSI
#define STM32_PLLXTPRE STM32_PLLXTPRE_DIV1
#define STM32_PLLMUL_VALUE 9
#define STM32_HPRE STM32_HPRE_DIV1
#define STM32_PPRE1 STM32_PPRE1_DIV2
#define STM32_PPRE2 STM32_PPRE2_DIV2
#define STM32_ADCPRE STM32_ADCPRE_DIV4
#define STM32_USB_CLOCK_REQUIRED TRUE
#define STM32_USBPRE STM32_USBPRE_DIV1
#define STM32_MCOSEL STM32_MCOSEL_NOCLOCK
#define STM32_RTCSEL STM32_RTCSEL_NOCLOCK
#define STM32_PVD_ENABLE FALSE
#define STM32_PLS STM32_PLS_LEV0
every time when I run debug in ChibiStudio it get stuck and when I suspend debug session it stops on "ST_ENABLE_CLOCK()" (in disassembly window) on sdInit() (in hal.c). Any idea what can be wrong?