Jarosław Wieczorek Jarosław Wieczorek - 3 years ago 322
C Question

How to link arm_cortexM4l_math.lib in Openstm32

I've included CMSIS_5 library, but I don't know how to link arm_cortexM4l_math.lib to my stm32 project for FFT.

My board is stm32f407-DISCOVERY and I'm using Openstm32.

Answer Source

Problem was resolved in a few simple steps.

I noticed that when I create a project, I can choose to export options for separated directory of standard stm32 peripherals.

  1. Select export to a separate directory of standard stm32 libraries. (When I chose this solution, showed two folders next to my project: stm32f407_stdperiph_lib and STM32F4xx_DSP_StdPeriph_Lib_V1.8.0)

  2. stm32f407_stdperiph_lib was linked immediately after the project was created.

  3. STM32F4xx_DSP_StdPeriph_Lib_V1.8.0 - This library is only added next to my project directory, but wasn't linked

  4. Link to STM32F4xx_DSP_StdPeriph_Lib_V1.8.0:

  5. In PropertiesSettingsMCCC GCC CompilerIncludes

  6. I added:

    "$ {Workspace_loc: /STM32F4xx_DSP_StdPeriph_Lib_V1.8.0/Libraries/CMSIS  /Device/ST/STM32F4xx/}
    "$ {Workspace_loc: /STM32F4xx_DSP_StdPeriph_Lib_V1.8.0/}"
    "$ {Workspace_loc: /STM32F4xx_DSP_StdPeriph_Lib_V1.8.0/Libraries/CMSIS/DSP_Lib/Source/}"
  7. Add preprocessor in MCCC GCC Compiler:

    • In PropertiesSettingsMCCC GCC CompilerPreprocessor


  1. Copy the whole Source directory from DSP_Lib to the src directory of the project

  2. Build

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download