ADC/AnalogWatchdog/main.c /** * @brief Configures the different system clocks. * @param None * @retval None */ void RCC_Configuration(void) { #if defined (STM32F10X_LD_VL) || defined (STM32F10X_MD_VL) || defined (STM32F10X_HD_VL) /* ADCCLK = PCLK2/2 */ RCC_ADCCLKConfig(RCC_PCLK2_Div2); #else /* ADCCLK = PCLK2/4 */ RCC_ADCCLKConfig(RCC_PCLK2_Div4); #endif /* Enable peripheral clocks --------------------------------------------------*/ /* Enable ADC1 and GPIO_LED clock */ RCC_APB2PeriphClockCmd(RCC_APB2Periph_ADC1, ENABLE); //只对ADC1进行时钟使能, //却未使能ADC12_IN14对应的端口GPIOC使能,有什么说法吗? } |
RE:ST 官方示例ADC_AnalogWatchdog缺少GPIOC时钟使能?