Hey Everyone, I am struggling to resolve my issue once I add FreeRTOS to my KEIL project. Before adding it, everything builds ok and runs. I then simply add FreeRTOS (using STM32CubeMX), don't change anything in the Cube and when I try to build, I get about 100 errors. They all seem to be somewhat related to portmacro.h and port.c
The first few errors are:
../Middlewares/Third_Party/FreeRTOS/Source/portable/RVDS/ARM_CM4F\portmacro.h(167): error: unknown type name '__forceinline'
../Middlewares/Third_Party/FreeRTOS/Source/portable/RVDS/ARM_CM4F\portmacro.h(170): error: expected 'volatile', 'inline', 'goto', or '('
Any thoughts would be helpful.....
I am using ARM Compiler 6.19
Language C = c99
MDK uVision = 5.38.0
Thanks!
You are building, and including the header file, from this directory - which is only correct for ARM compiler 5. https://github.com/FreeRTOS/FreeRTOS-Kernel/tree/main/portable/RVDS/ARM_CM4F
If you want to use ARM compiler 6 then you need to instead build, and include the header file, from this directory github.com/.../ARM_CM4F (i.e. change the include path, remove the C file you are currently building, and instead build the files in the GCC directory)