Hi everyone, I want to program nucleo F091RC using STM32f0xx standard peripheral libraries. I included all the .h and .c files in my project and when I try to build my project, the only one error i have is this one :
src\stm32f0xx_dac.c(165): error: #20: identifier "RCC_APB1Periph_DAC" is undefined
does anyone know how I have to define RCC_APB1Periph_DAC ? is it uint8/16/32_t ? or something else ? I have to declare it into the .h file ?
Thank you all.
I declared it as uint32_t, saved and rebuild the project. but now I have that problem : .\Objects\projet1.axf: Error: L6218E: Undefined symbol assert_param (referred from stm32f0xx_adc.o).
Which I have seen on another thread. But As I included to my project all the .c and .h, I don't understand where the problem is... ".o" are created when ".c" is compiled right ?
You should review the project templates provided, and look at the include paths, and defines handed to the compiler.
The assert code is usually situated in main.c
Defines like USE_STDPERIPH_DRIVER,STM32F051
The linker gives errors when *none* of the object files (.o) have the function body code that is being called.
Remember .H files don't typically provide code, they define the interface to code that's in some other .O or .LIB. The compiler performs a syntax check, but it's the linker's job to find all the pieces and bind them together. When the linker fails it's because some parts are missing.