I am a started for Keil uvision5 and also the embbeded software. Now I have a problem with the builing under uvision5. The project is created following the normal procedure, and the main.c file is used from the standard examples of STmicroelctronics,
\STM32F10x_StdPeriph_Examples\GPIO\IOToggle
But when I building the project, many of the indentifiers are reported as indecleard, seems the header file "STM32F10x_gpio.h" is not included sucessfully to the project. But in the main.c file, the header file "stm32f10x.h" is included. That is quite strange. Could anyboday can help me? Thanks in advance!
Here is the main.c file.
/** ****************************************************************************** * @file GPIO/IOToggle/main.c * @author MCD Application Team * @version V3.5.0 * @date 08-April-2011 * @brief Main program body. ****************************************************************************** * @attention * * THE PRESENT FIRMWARE WHICH IS FOR GUIDANCE ONLY AIMS AT PROVIDING CUSTOMERS * WITH CODING INFORMATION REGARDING THEIR PRODUCTS IN ORDER FOR THEM TO SAVE * TIME. AS A RESULT, STMICROELECTRONICS SHALL NOT BE HELD LIABLE FOR ANY * DIRECT, INDIRECT OR CONSEQUENTIAL DAMAGES WITH RESPECT TO ANY CLAIMS ARISING * FROM THE CONTENT OF SUCH FIRMWARE AND/OR THE USE MADE BY CUSTOMERS OF THE * CODING INFORMATION CONTAINED HEREIN IN CONNECTION WITH THEIR PRODUCTS. * * <h2><center>© COPYRIGHT 2011 STMicroelectronics</center></h2> ****************************************************************************** */ /* Includes ------------------------------------------------------------------*/ #include "stm32f10x.h" //#include "stm32_eval.h" /** @addtogroup STM32F10x_StdPeriph_Examples * @{ */ /** @addtogroup GPIO_IOToggle * @{ */ /* Private typedef -----------------------------------------------------------*/ /* Private define ------------------------------------------------------------*/ /* Private macro -------------------------------------------------------------*/ /* Private variables ---------------------------------------------------------*/ GPIO_InitTypeDef GPIO_InitStructure; /* Private function prototypes -----------------------------------------------*/ /* Private functions ---------------------------------------------------------*/ /** * @brief Main program. * @param None * @retval None */ int main(void) { /*!< At this stage the microcontroller clock setting is already configured, this is done through SystemInit() function which is called from startup file (startup_stm32f10x_xx.s) before to branch to application main. To reconfigure the default setting of SystemInit() function, refer to system_stm32f10x.c file */ /* GPIOD Periph clock enable */ RCC_APB2PeriphClockCmd(RCC_APB2Periph_GPIOD, ENABLE); /* Configure PD0 and PD2 in output pushpull mode */ GPIO_InitStructure.GPIO_Pin = GPIO_Pin_0 | GPIO_Pin_2; GPIO_InitStructure.GPIO_Speed = GPIO_Speed_50MHz; GPIO_InitStructure.GPIO_Mode = GPIO_Mode_Out_PP; GPIO_Init(GPIOD, &GPIO_InitStructure); /* To achieve GPIO toggling maximum frequency, the following sequence is mandatory. You can monitor PD0 or PD2 on the scope to measure the output signal. If you need to fine tune this frequency, you can add more GPIO set/reset cycles to minimize more the infinite loop timing. This code needs to be compiled with high speed optimization option. */ while (1) { /* Set PD0 and PD2 */ GPIOD->BSRR = 0x00000005; /* Reset PD0 and PD2 */ GPIOD->BRR = 0x00000005; /* Set PD0 and PD2 */ GPIOD->BSRR = 0x00000005; /* Reset PD0 and PD2 */ GPIOD->BRR = 0x00000005; /* Set PD0 and PD2 */ GPIOD->BSRR = 0x00000005; /* Reset PD0 and PD2 */ GPIOD->BRR = 0x00000005; /* Set PD0 and PD2 */ GPIOD->BSRR = 0x00000005; /* Reset PD0 and PD2 */ GPIOD->BRR = 0x00000005; /* Set PD0 and PD2 */ GPIOD->BSRR = 0x00000005; /* Reset PD0 and PD2 */ GPIOD->BRR = 0x00000005; /* Set PD0 and PD2 */ GPIOD->BSRR = 0x00000005; /* Reset PD0 and PD2 */ GPIOD->BRR = 0x00000005; /* Set PD0 and PD2 */ GPIOD->BSRR = 0x00000005; /* Reset PD0 and PD2 */ GPIOD->BRR = 0x00000005; /* Set PD0 and PD2 */ GPIOD->BSRR = 0x00000005; /* Reset PD0 and PD2 */ GPIOD->BRR = 0x00000005; /* Set PD0 and PD2 */ GPIOD->BSRR = 0x00000005; /* Reset PD0 and PD2 */ GPIOD->BRR = 0x00000005; /* Set PD0 and PD2 */ GPIOD->BSRR = 0x00000005; /* Reset PD0 and PD2 */ GPIOD->BRR = 0x00000005; } } #ifdef USE_FULL_ASSERT /** * @brief Reports the name of the source file and the source line number * where the assert_param error has occurred. * @param file: pointer to the source file name * @param line: assert_param error line source number * @retval None */ void assert_failed(uint8_t* file, uint32_t line) { /* User can add his own implementation to report the file name and line number, ex: printf("Wrong parameters value: file %s on line %d\r\n", file, line) */ /* Infinite loop */ while (1) { } } #endif /** * @} */ /** * @} */ /******************* (C) COPYRIGHT 2011 STMicroelectronics *****END OF FILE****/
Do I understand you correct that the tools did not produce one single error message? Or was it you that decided that no error message was interesting enough that you would include it in your post? Isn't that quite strange?
Yes, there are numerous errors and warnings reported by uvision5,now most of them are post below,
Rebuild target 'Target 1' compiling main.c... main.c(39): error: #20: identifier "TIM_TimeBaseInitTypeDef" is undefined TIM_TimeBaseInitTypeDef TIM_TimeBaseStructure; main.c(40): error: #20: identifier "TIM_OCInitTypeDef" is undefined TIM_OCInitTypeDef TIM_OCInitStructure; main.c(95): error: #20: identifier "TIM_CounterMode_Up" is undefined TIM_TimeBaseStructure.TIM_CounterMode = TIM_CounterMode_Up; main.c(97): warning: #223-D: function "TIM_TimeBaseInit" declared implicitly TIM_TimeBaseInit(TIM3, &TIM_TimeBaseStructure); main.c(100): error: #20: identifier "TIM_OCMode_PWM1" is undefined TIM_OCInitStructure.TIM_OCMode = TIM_OCMode_PWM1; main.c(101): error: #20: identifier "TIM_OutputState_Enable" is undefined TIM_OCInitStructure.TIM_OutputState = TIM_OutputState_Enable; main.c(103): error: #20: identifier "TIM_OCPolarity_High" is undefined TIM_OCInitStructure.TIM_OCPolarity = TIM_OCPolarity_High; main.c(105): warning: #223-D: function "TIM_OC1Init" declared implicitly TIM_OC1Init(TIM3, &TIM_OCInitStructure); main.c(107): warning: #223-D: function "TIM_OC1PreloadConfig" declared implicitly TIM_OC1PreloadConfig(TIM3, TIM_OCPreload_Enable); main.c(107): error: #20: identifier "TIM_OCPreload_Enable" is undefined TIM_OC1PreloadConfig(TIM3, TIM_OCPreload_Enable); main.c(113): warning: #223-D: function "TIM_OC2Init" declared implicitly TIM_OC2Init(TIM3, &TIM_OCInitStructure); main.c(115): warning: #223-D: function "TIM_OC2PreloadConfig" declared implicitly TIM_OC2PreloadConfig(TIM3, TIM_OCPreload_Enable); main.c(121): warning: #223-D: function "TIM_OC3Init" declared implicitly TIM_OC3Init(TIM3, &TIM_OCInitStructure); main.c(123): warning: #223-D: function "TIM_OC3PreloadConfig" declared implicitly TIM_OC3PreloadConfig(TIM3, TIM_OCPreload_Enable); main.c(129): warning: #223-D: function "TIM_OC4Init" declared implicitly TIM_OC4Init(TIM3, &TIM_OCInitStructure); main.c(131): warning: #223-D: function "TIM_OC4PreloadConfig" declared implicitly TIM_OC4PreloadConfig(TIM3, TIM_OCPreload_Enable); main.c(133): warning: #223-D: function "TIM_ARRPreloadConfig" declared implicitly TIM_ARRPreloadConfig(TIM3, ENABLE); main.c(136): warning: #223-D: function "TIM_Cmd" declared implicitly TIM_Cmd(TIM3, ENABLE); main.c(150): warning: #223-D: function "RCC_APB1PeriphClockCmd" declared implicitly RCC_APB1PeriphClockCmd(RCC_APB1Periph_TIM3, ENABLE); main.c(150): error: #20: identifier "RCC_APB1Periph_TIM3" is undefined RCC_APB1PeriphClockCmd(RCC_APB1Periph_TIM3, ENABLE); main.c(153): warning: #223-D: function "RCC_APB2PeriphClockCmd" declared implicitly RCC_APB2PeriphClockCmd(RCC_APB2Periph_GPIOA | RCC_APB2Periph_GPIOB | main.c(153): error: #20: identifier "RCC_APB2Periph_GPIOA" is undefined RCC_APB2PeriphClockCmd(RCC_APB2Periph_GPIOA | RCC_APB2Periph_GPIOB | main.c(153): error: #20: identifier "RCC_APB2Periph_GPIOB" is undefined RCC_APB2PeriphClockCmd(RCC_APB2Periph_GPIOA | RCC_APB2Periph_GPIOB | main.c(154): error: #20: identifier "RCC_APB2Periph_GPIOC" is undefined RCC_APB2Periph_GPIOC | RCC_APB2Periph_AFIO, ENABLE); main.c(154): error: #20: identifier "RCC_APB2Periph_AFIO" is undefined RCC_APB2Periph_GPIOC | RCC_APB2Periph_AFIO, ENABLE); main.c(164): error: #20: identifier "GPIO_InitTypeDef" is undefined GPIO_InitTypeDef GPIO_InitStructure; main.c(168): error: #20: identifier "GPIO_Pin_6" is undefined GPIO_InitStructure.GPIO_Pin = GPIO_Pin_6 | GPIO_Pin_7 | GPIO_Pin_8 | GPIO_Pin_9; main.c(168): error: #20: identifier "GPIO_Pin_7" is undefined GPIO_InitStructure.GPIO_Pin = GPIO_Pin_6 | GPIO_Pin_7 | GPIO_Pin_8 | GPIO_Pin_9; main.c(168): error: #20: identifier "GPIO_Pin_8" is undefined GPIO_InitStructure.GPIO_Pin = GPIO_Pin_6 | GPIO_Pin_7 | GPIO_Pin_8 | GPIO_Pin_9; main.c(168): error: #20: identifier "GPIO_Pin_9" is undefined GPIO_InitStructure.GPIO_Pin = GPIO_Pin_6 | GPIO_Pin_7 | GPIO_Pin_8 | GPIO_Pin_9; main.c(169): error: #20: identifier "GPIO_Mode_AF_PP" is undefined GPIO_InitStructure.GPIO_Mode = GPIO_Mode_AF_PP; main.c(170): error: #20: identifier "GPIO_Speed_50MHz" is undefined GPIO_InitStructure.GPIO_Speed = GPIO_Speed_50MHz; main.c(172): warning: #223-D: function "GPIO_Init" declared implicitly GPIO_Init(GPIOC, &GPIO_InitStructure); main.c(174): warning: #223-D: function "GPIO_PinRemapConfig" declared implicitly GPIO_PinRemapConfig(GPIO_FullRemap_TIM3, ENABLE); main.c(174): error: #20: identifier "GPIO_FullRemap_TIM3" is undefined GPIO_PinRemapConfig(GPIO_FullRemap_TIM3, ENABLE); main.c: 15 warnings, 20 errors assembling startup_stm32f10x_cl.s... compiling system_stm32f10x.c... compiling misc.c... C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\misc.c(99): warning: #223-D: function "assert_param" declared implicitly assert_param(IS_NVIC_PRIORITY_GROUP(NVIC_PriorityGroup)); C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\misc.c(117): warning: #223-D: function "assert_param" declared implicitly assert_param(IS_FUNCTIONAL_STATE(NVIC_InitStruct->NVIC_IRQChannelCmd)); C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\misc.c(159): warning: #223-D: function "assert_param" declared implicitly assert_param(IS_NVIC_VECTTAB(NVIC_VectTab)); C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\misc.c(178): warning: #223-D: function "assert_param" declared implicitly assert_param(IS_NVIC_LP(LowPowerMode)); C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\misc.c(202):
".\PWM_Output.axf" - 20 Error(s), 72 Warning(s). Target not created
The file "stm32f10x.h" contains the special function registers and some other information for the processor.
This is enough if you are going to work directly with the processor registers.
But why do you think you don't need "stm32f10x_tim.h" etc, when you plan to use the standard peripherial driver code?
in my project, only GPIO is used, why should I include stm32f10x_tim.h which is only useful for timers?
Because the error messages you posted says so.
But then the error messages you posted doesn't seem to belong to the source code you posted...
Professional findings. And I am sorry I post a mismatched error messages! Now the proper error messages(majority because of the characters number limitation of the post) are post below, please kindly take a look where the problem comes from. By the way, is it possible to have your email address so that I can send to the whole project and you could catch all the details?
Rebuild target 'Target 1' compiling main.c... main.c(38): error: #20: identifier "GPIO_InitTypeDef" is undefined GPIO_InitTypeDef GPIO_InitStructure; main.c(58): warning: #223-D: function "RCC_APB2PeriphClockCmd" declared implicitly RCC_APB2PeriphClockCmd(RCC_APB2Periph_GPIOD, ENABLE); main.c(58): error: #20: identifier "RCC_APB2Periph_GPIOD" is undefined RCC_APB2PeriphClockCmd(RCC_APB2Periph_GPIOD, ENABLE); main.c(61): error: #20: identifier "GPIO_Pin_0" is undefined GPIO_InitStructure.GPIO_Pin = GPIO_Pin_0 | GPIO_Pin_2; main.c(61): error: #20: identifier "GPIO_Pin_2" is undefined GPIO_InitStructure.GPIO_Pin = GPIO_Pin_0 | GPIO_Pin_2; main.c(62): error: #20: identifier "GPIO_Speed_50MHz" is undefined GPIO_InitStructure.GPIO_Speed = GPIO_Speed_50MHz; main.c(63): error: #20: identifier "GPIO_Mode_Out_PP" is undefined GPIO_InitStructure.GPIO_Mode = GPIO_Mode_Out_PP; main.c(64): warning: #223-D: function "GPIO_Init" declared implicitly GPIO_Init(GPIOD, &GPIO_InitStructure); main.c: 2 warnings, 6 errors compiling misc.c... C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\misc.c(99): warning: #223-D: function "assert_param" declared implicitly assert_param(IS_NVIC_PRIORITY_GROUP(NVIC_PriorityGroup)); C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\misc.c(117): warning: #223-D: function "assert_param" declared implicitly assert_param(IS_FUNCTIONAL_STATE(NVIC_InitStruct->NVIC_IRQChannelCmd)); C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\misc.c(159): warning: #223-D: function "assert_param" declared implicitly assert_param(IS_NVIC_VECTTAB(NVIC_VectTab)); C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\misc.c(178): warning: #223-D: function "assert_param" declared implicitly assert_param(IS_NVIC_LP(LowPowerMode)); C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\misc.c(202): warning: #223-D: function "assert_param" declared implicitly assert_param(IS_SYSTICK_CLK_SOURCE(SysTick_CLKSource)); C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\misc.c: 5 warnings, 0 errors compiling stm32f10x_gpio.c... C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\stm32f10x_gpio.c(111): warning: #223-D: function "assert_param" declared implicitly assert_param(IS_GPIO_ALL_PERIPH(GPIOx)); C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\stm32f10x_gpio.c(178): warning: #223-D: function "assert_param" declared implicitly assert_param(IS_GPIO_ALL_PERIPH(GPIOx)); C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\stm32f10x_gpio.c(286): warning: #223-D: function "assert_param" declared implicitly ...... assert_param(IS_FUNCTIONAL_STATE(NewState)); C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\stm32f10x_rcc.c(1285): warning: #223-D: function "assert_param" declared implicitly assert_param(IS_RCC_MCO(RCC_MCO)); C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\stm32f10x_rcc.c(1332): warning: #223-D: function "assert_param" declared implicitly assert_param(IS_RCC_FLAG(RCC_FLAG)); C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\stm32f10x_rcc.c(1406): warning: #223-D: function "assert_param" declared implicitly assert_param(IS_RCC_GET_IT(RCC_IT)); C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\stm32f10x_rcc.c(1451): warning: #223-D: function "assert_param" declared implicitly assert_param(IS_RCC_CLEAR_IT(RCC_IT)); C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\stm32f10x_rcc.c: 36 warnings, 0 errors assembling startup_stm32f10x_cl.s... compiling system_stm32f10x.c... ".\IO_Toggle.axf" - 6 Error(s), 59 Warning(s). Target not created
But you have already received the answer - if you want to use the standard peripherial driver layer then you do need more header files. It's only if you are going to interact directly with the SFR that you can get away with using only the include file you are currently using.
GPIO_Init() is not a SFR. So you need to add extra header files.
All the documents I read from Keil say the "stm32f10x.h" is the unique header file to be included in user application code, why should I include more header file than "stm32f10x.h"? Furthermore, in this particular case, what more header files that I need to include in my main.c source?
So - have you been a developer yet and spent some time looking at the used include file?
State of USE_STDPERIPH_DRIVER?
And existence of stm32f10x_conf.h with suitable content?
You have two options - let everything be black magic, or take a closer look at how the example programs manages to do what they do.
No, I am a starter/learner for embeeded sofware and also the uvision5 toolset. Normaly I work as a hardware developer. But I am very interested in software and eager to learn it quickly.
To use the USE_STDPERIPH_DRIVER, in my perception the only thing I need to do is to enable the relevant items under the "Manage Run-Time Environment --> Device -->stdPeriph Drivers", and to include the "stm32f10x.h" in my source code. But appraently you have different ideas.
I am glad to take a closer look at the example programs, the example programs you mentioned here are the ones of pack examples in uvision5?
And in this particular case, you also suggest me to take a look at the content of stm32f10x_conf.h?
With your reminding and after reading the stm32f10x.h file, I tried to add "#define USE_STDPERIPH_DRIVER" in my main.c file, now it solves the include problem, but the last errors are about the "assert_param", the detailed error messages are listed below, still keeping looking into this, but it will be better if you could inspire me a little.
Rebuild target 'Target 1' compiling main.c... compiling misc.c... C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\misc.c(99): warning: #223-D: function "assert_param" declared implicitly assert_param(IS_NVIC_PRIORITY_GROUP(NVIC_PriorityGroup)); C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\misc.c(117): warning: #223-D: function "assert_param" declared implicitly assert_param(IS_FUNCTIONAL_STATE(NVIC_InitStruct->NVIC_IRQChannelCmd)); C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\misc.c(159): warning: #223-D: function "assert_param" declared implicitly assert_param(IS_NVIC_VECTTAB(NVIC_VectTab)); C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\misc.c(178): warning: #223-D: function "assert_param" declared implicitly assert_param(IS_NVIC_LP(LowPowerMode)); C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\misc.c(202): warning: #223-D: function "assert_param" declared implicitly assert_param(IS_SYSTICK_CLK_SOURCE(SysTick_CLKSource)); C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\misc.c: 5 warnings, 0 errors compiling stm32f10x_gpio.c... C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\stm32f10x_gpio.c(111): warning: #223-D: function "assert_param" declared implicitly assert_param(IS_GPIO_ALL_PERIPH(GPIOx)); C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\stm32f10x_gpio.c(178): warning: #223-D: function "assert_param" declared implicitly assert_param(IS_GPIO_ALL_PERIPH(GPIOx)); C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\stm32f10x_gpio.c(286): warning: #223-D: function "assert_param" declared implicitly assert_param(IS_GPIO_ALL_PERIPH(GPIOx)); C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\stm32f10x_gpio.c(308): warning: #223-D: function "assert_param" declared implicitly assert_param(IS_GPIO_ALL_PERIPH(GPIOx)); C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\stm32f10x_gpio.c(324): warning: #223-D: function "assert_param" declared implicitly assert_param(IS_GPIO_ALL_PERIPH(GPIOx)); C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\stm32f10x_gpio.c(346): warning: #223-D: function "assert_param" declared implicitly assert_param(IS_GPIO_ALL_PERIPH(GPIOx)); C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\stm32f10x_gpio.c(361): warning: #223-D: function "assert_param" declared implicitly assert_param(IS_GPIO_ALL_PERIPH(GPIOx)); C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\stm32f10x_gpio.c
....
assert_param(IS_FUNCTIONAL_STATE(NewState)); C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\stm32f10x_rcc.c(882): warning: #223-D: function "assert_param" declared implicitly assert_param(IS_RCC_RTCCLK_SOURCE(RCC_RTCCLKSource)); C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\stm32f10x_rcc.c(896): warning: #223-D: function "assert_param" declared implicitly assert_param(IS_FUNCTIONAL_STATE(NewState)); C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\stm32f10x_rcc.c(1067): warning: #223-D: function "assert_param" declared implicitly assert_param(IS_RCC_AHB_PERIPH(RCC_AHBPeriph)); C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\stm32f10x_rcc.c(1098): warning: #223-D: function "assert_param" declared implicitly assert_param(IS_RCC_APB2_PERIPH(RCC_APB2Periph)); C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\stm32f10x_rcc.c(1129): warning: #223-D: function "assert_param" declared implicitly assert_param(IS_RCC_APB1_PERIPH(RCC_APB1Periph)); C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\stm32f10x_rcc.c(1156): warning: #223-D: function "assert_param" declared implicitly assert_param(IS_RCC_AHB_PERIPH_RESET(RCC_AHBPeriph)); C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\stm32f10x_rcc.c(1188): warning: #223-D: function "assert_param" declared implicitly assert_param(IS_RCC_APB2_PERIPH(RCC_APB2Periph)); C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\stm32f10x_rcc.c(1219): warning: #223-D: function "assert_param" declared implicitly assert_param(IS_RCC_APB1_PERIPH(RCC_APB1Periph)); C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\stm32f10x_rcc.c(1240): warning: #223-D: function "assert_param" declared implicitly assert_param(IS_FUNCTIONAL_STATE(NewState)); C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\stm32f10x_rcc.c(1253): warning: #223-D: function "assert_param" declared implicitly assert_param(IS_FUNCTIONAL_STATE(NewState)); C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\stm32f10x_rcc.c(1285): warning: #223-D: function "assert_param" declared implicitly assert_param(IS_RCC_MCO(RCC_MCO)); C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\stm32f10x_rcc.c(1332): warning: #223-D: function "assert_param" declared implicitly assert_param(IS_RCC_FLAG(RCC_FLAG)); C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\stm32f10x_rcc.c(1406): warning: #223-D: function "assert_param" declared implicitly assert_param(IS_RCC_GET_IT(RCC_IT)); C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\stm32f10x_rcc.c(1451): warning: #223-D: function "assert_param" declared implicitly assert_param(IS_RCC_CLEAR_IT(RCC_IT)); C:\Keil_v5\ARM\PACK\Keil\STM32F1xx_DFP\1.0.5\Device\StdPeriph_Driver\src\stm32f10x_rcc.c: 36 warnings, 0 errors assembling startup_stm32f10x_cl.s... compiling system_stm32f10x.c... linking... .\IO_Toggle.axf: Error: L6218E: Undefined symbol assert_param (referred from misc.o). Not enough information to list image symbols. Finished: 1 information, 0 warning and 1 error messages. ".\IO_Toggle.axf" - 1 Error(s), 57 Warning(s). Target not created
I think I find a mehtod to fix this problem,
to define USE_STDPERIPH_DRIVER in Options->C/C++->preprocessor Symboles
Thank you anyway for the time.