2020-07-23 10:39 AM
Added folder Drivers/BSP. Added file stm32f4xx_nucleo.h to the new directory. Added it to the include path. I even copied the file to Core/Inc. Still "no such file". Why is it missing?
Solved! Go to Solution.
2020-07-24 09:34 AM
Right click on your project within Project Explorer then "Properties"
As addon here is my setup adding BSP without any issue
2020-07-23 10:44 AM
Quality software...
Perhaps look at what exactly is being feed on the compiler/linker command lines, and if that is wrong or malformed.
2020-07-23 11:29 AM
> Why is it missing?
The compiler can't find it.
Hard to know why without any details. Make sure the path to the include file is added.
2020-07-24 04:19 AM
every line contains "-I../Drivers/BSP" as seen in the line with the error:
arm-none-eabi-gcc "../Core/Src/DiagnosticStack/DiagnosticSlaveReceiveHandler.c" -mcpu=cortex-m4 -std=gnu11 -g3 -DUSE_HAL_DRIVER -DSTM32F401xE -DDEBUG -c -I../Core/Src/DiagnosticStack -I../Drivers/STM32F4xx_HAL_Driver/Inc -I../Drivers/CMSIS/Device/ST/STM32F4xx/Include -I../Core/Src/bootSupport -I../Core/Src/halLayer -I../Drivers/CMSIS/Include -I../Drivers/STM32F4xx_HAL_Driver/Inc/Legacy -I../Drivers/BSP -I../Core/Src/DiagnosticClasses -I../Core/Inc -O0 -ffunction-sections -fdata-sections -Wall -fstack-usage -MMD -MP -MF"Core/Src/DiagnosticStack/DiagnosticSlaveReceiveHandler.d" -MT"Core/Src/DiagnosticStack/DiagnosticSlaveReceiveHandler.o" --specs=nano.specs -mfpu=fpv4-sp-d16 -mfloat-abi=hard -mthumb -o "Core/Src/DiagnosticStack/DiagnosticSlaveReceiveHandler.o"
In file included from ../Core/Src/halLayer/halTimer.h:30:0,
from ../Core/Src/DiagnosticStack/Diagnostic.c:30:
../Core/Inc/main.h:39:10: fatal error: stm32f4xx_nucleo.h: No such file or directory
#include "stm32f4xx_nucleo.h"
Hints? Comments? Suggestions?
2020-07-24 04:23 AM
Project->Properties->Tool Settings -> MCU GCC Compiler -> Include paths Add "Drivers/BSP". It is visible as "../Drivers/BSP" Any suggestions as to how to make that line effective?
2020-07-24 07:55 AM
Is such line effective from Eclipse point of view already ? Please could you check if such line is leading to plain or grayed include like following sanpshot ... if grayed means Eclipse not able to reach
2020-07-24 09:11 AM
Thanks. Good find. I did find one bad directory which starts with a "/". How do I get rid of the bad one? How do I replace it with a good one with no '/"?
Unfortunately, stm32f4xx_nucleo.h isn't in that one directory and cannot be found.
2020-07-24 09:34 AM
Right click on your project within Project Explorer then "Properties"
As addon here is my setup adding BSP without any issue
2020-07-24 10:36 AM
Thanks again. I'm back in business.
2020-07-28 11:46 AM
Please tag as "Answered" will help Community.