"STM32 Discovery F407" Error compiling

Ron
Sun Nov 01, 2015 12:53 am
Hello,

I’m new to the forum, been using 8bit for several years.
Decided to look at the 32bit stuff, but have some errors.

1) Using arduino IDE 1.6.5
2) Went into the Tools/Board/Boards Manager and selected Arduino SAM Boards Arduino DUE Went Fine
3) Unzip Arduino_STM32-Master to Arduino/Hardware Directory
4) In the Hardware Directory renamed the Arduino_STM3-Master to Arduino_STM32, removed -Master

1) Ran Arduino 1.6.5 IDE, New 32bit boards are in the board section
2) Selected “STM32 Discovery F407”
3) Loaded Arduino 32bit example Blink
4) Verify blink gives these errors

Arduino: 1.6.5 (Windows 7), Board: “STM32 Discovery F407”

arm-none-eabi-g++: error: Files\Arduino\hardware\Arduno_STM32\STM32F4\cores\maple/libmaple/usbF4: No such file or directory
arm-none-eabi-g++: error: Files\Arduino\hardware\Arduno_STM32\STM32F4\cores\maple/libmaple/usbF4/STM32_USB_Device_Library/Core/inc: No such file or directory
arm-none-eabi-g++: error: Files\Arduino\hardware\Arduno_STM32\STM32F4\cores\maple/libmaple/usbF4/STM32_USB_Device_Library/Class/cdc/inc: No such file or directory
arm-none-eabi-g++: error: Files\Arduino\hardware\Arduno_STM32\STM32F4\cores\maple/libmaple/usbF4/STM32_USB_OTG_Driver/inc: No such file or directory
arm-none-eabi-g++: error: Files\Arduino\hardware\Arduno_STM32\STM32F4\cores\maple/libmaple/usbF4/VCP: No such file or directory
Error compiling.

Strange but those directories are there!

I selected a different board STM32F3Discovery, verify blink compiles Fine

Looking at the errors looks like the slash is going in the wrong direction after maple, maybe OK Looks strange
Tried on Windows XP and Windows 7 – same error

Ron


RogerClark
Sun Nov 01, 2015 2:56 am
Just tried compiling blink for the F407 on Arduino 1.6.5.r5 and it was OK for me

When did you install the IDE ? I doubt this is the problem but the IDE team did seem to release a lot of fixes for 1.6.5 hence the R5 version

In preferences turn on verbose for compile and look at the line that has errors

e.g.

C:\Users\rclark\AppData\Roaming\Arduino15\packages\arduino\tools\arm-none-eabi-gcc\4.8.3-2014q1/bin/arm-none-eabi-g++ -c -g -Os -w -MMD -ffunction-sections -fdata-sections -nostdlib --param max-inline-insns-single=500 -fno-rtti -fno-exceptions -DBOARD_discovery_f407 -DVECT_TAB_BASE -DERROR_LED_PORT=GPIOD -DERROR_LED_PIN=14 -mcpu=cortex-m4 -DF_CPU=168000000L -DARDUINO=10605 -DARDUINO_STM32DiscoveryF407 -DARDUINO_ARCH_STM32F4 -DMCU_STM32F406VG -mthumb -DSTM32_HIGH_DENSITY -DSTM32F2 -DSTM32F4 -DBOARD_discovery_f4 -IC:\Users\rclark\Documents\Arduino\hardware\Arduino_STM32\STM32F4\cores\maple/libmaple -IC:\Users\rclark\Documents\Arduino\hardware\Arduino_STM32\STM32F4\cores\maple/libmaple/usbF4 -IC:\Users\rclark\Documents\Arduino\hardware\Arduino_STM32\STM32F4\cores\maple/libmaple/usbF4/STM32_USB_Device_Library/Core/inc -IC:\Users\rclark\Documents\Arduino\hardware\Arduino_STM32\STM32F4\cores\maple/libmaple/usbF4/STM32_USB_Device_Library/Class/cdc/inc -IC:\Users\rclark\Documents\Arduino\hardware\Arduino_STM32\STM32F4\cores\maple/libmaple/usbF4/STM32_USB_OTG_Driver/inc -IC:\Users\rclark\Documents\Arduino\hardware\Arduino_STM32\STM32F4\cores\maple/libmaple/usbF4/VCP -IC:\Users\rclark\Documents\Arduino\hardware\Arduino_STM32\STM32F4\cores\maple -IC:\Users\rclark\Documents\Arduino\hardware\Arduino_STM32\STM32F4\variants\discovery_f407 C:\Users\rclark\AppData\Local\Temp\build2836591131281272557.tmp\Blink.cpp -o C:\Users\rclark\AppData\Local\Temp\build2836591131281272557.tmp\Blink.cpp.o


Ron
Sun Nov 01, 2015 2:05 pm
The arduino IDE version says 1.6.5 but the download file name I installed from says arduino-1.6.5-r5-windows
Ron
Verbose compilation
Arduino: 1.6.5 (Windows XP), Board: “STM32 Discovery F407”

C:\Documents and Settings\one\Application Data\Arduino15\packages\arduino\tools\arm-none-eabi-gcc\4.8.3-2014q1/bin/arm-none-eabi-g++ -c -g -Os -w -MMD -ffunction-sections -fdata-sections -nostdlib –param max-inline-insns-single=500 -fno-rtti -fno-exceptions -DBOARD_discovery_f407 -DVECT_TAB_BASE -DERROR_LED_PORT=GPIOD -DERROR_LED_PIN=14 -mcpu=cortex-m4 -DF_CPU=168000000L -DARDUINO=10605 -DARDUINO_STM32DiscoveryF407 -DARDUINO_ARCH_STM32F4 -DMCU_STM32F406VG -mthumb -DSTM32_HIGH_DENSITY -DSTM32F2 -DSTM32F4 -DBOARD_discovery_f4 -IC:\Program Files\Arduino\hardware\Arduino_STM32\STM32F4\cores\maple/libmaple -IC:\Program Files\Arduino\hardware\Arduino_STM32\STM32F4\cores\maple/libmaple/usbF4 -IC:\Program Files\Arduino\hardware\Arduino_STM32\STM32F4\cores\maple/libmaple/usbF4/STM32_USB_Device_Library/Core/inc -IC:\Program Files\Arduino\hardware\Arduino_STM32\STM32F4\cores\maple/libmaple/usbF4/STM32_USB_Device_Library/Class/cdc/inc -IC:\Program Files\Arduino\hardware\Arduino_STM32\STM32F4\cores\maple/libmaple/usbF4/STM32_USB_OTG_Driver/inc -IC:\Program Files\Arduino\hardware\Arduino_STM32\STM32F4\cores\maple/libmaple/usbF4/VCP -IC:\Program Files\Arduino\hardware\Arduino_STM32\STM32F4\cores\maple -IC:\Program Files\Arduino\hardware\Arduino_STM32\STM32F4\variants\discovery_f407 C:\DOCUME~1\one\LOCALS~1\Temp\build4795590044229318396.tmp\Blink.cpp -o C:\DOCUME~1\one\LOCALS~1\Temp\build4795590044229318396.tmp\Blink.cpp.o

arm-none-eabi-g++: error: Files\Arduino\hardware\Arduino_STM32\STM32F4\cores\maple/libmaple/usbF4: No such file or directory
arm-none-eabi-g++: error: Files\Arduino\hardware\Arduino_STM32\STM32F4\cores\maple/libmaple/usbF4/STM32_USB_Device_Library/Core/inc: No such file or directory
arm-none-eabi-g++: error: Files\Arduino\hardware\Arduino_STM32\STM32F4\cores\maple/libmaple/usbF4/STM32_USB_Device_Library/Class/cdc/inc: No such file or directory
arm-none-eabi-g++: error: Files\Arduino\hardware\Arduino_STM32\STM32F4\cores\maple/libmaple/usbF4/STM32_USB_OTG_Driver/inc: No such file or directory
arm-none-eabi-g++: error: Files\Arduino\hardware\Arduino_STM32\STM32F4\cores\maple/libmaple/usbF4/VCP: No such file or directory
Error compiling.


martinayotte
Sun Nov 01, 2015 2:56 pm
From what we can see above, the errors comes from the fact that your tree is located in “C:\Program Files\” and that all paths are not treated correctly as they been interpreted as “C:\Program” and “Files\” separately because of the space.
Simply move or re-install it in a simple folder such “C:\MyArduino\”.

Ron
Sun Nov 01, 2015 5:55 pm
Thanks, moving to C:\ did it!
Ron

RogerClark
Sun Nov 01, 2015 8:29 pm
On windows the normal installation location is in

MyDocuments/Arduino/hardware/arduino_stm32

not in with the IDE.

Adding cores with the IDE was only for 1.0 of the IDE and the hardware folder in the sketches folder was introduced in 1.5.x


cimd
Fri Jul 01, 2016 9:54 pm
I tried installing the Arduino_STM32 folder in the C:\Users\Ingo\Documents\Arduino\hardware folder as per installation instruction, but the Arduino IDE (1.6.7) does not recognizes the folder/boards. If I install it to the C:\Program Files (x86)\Arduino\hardware folder, the IDE recognizes it, but then I get all the “No such file or directory” on the includes.

In file included from C:\Program Files (x86)\Arduino\hardware\Arduino_STM32\STM32F4\cores\maple/WProgram.h:27:0,

from C:\Program Files (x86)\Arduino\hardware\Arduino_STM32\STM32F4\cores\maple/Arduino.h:3,

from sketch\sketch_jul01a.ino.cpp:1:

C:\Program Files (x86)\Arduino\hardware\Arduino_STM32\STM32F4\cores\maple/wirish.h:37:22: fatal error: libmaple.h: No such file or directory

#include "libmaple.h"

^

compilation terminated.

exit status 1
Error compiling for "STM32 Discovery F407"


RogerClark
Fri Jul 01, 2016 10:13 pm
Yes.

1.6.7 has never been supported

Upgrade to 1.6.9 as the Arduino team have now fixed the problems which broke things in 1.6.6,1.6.7 and 1.6.8


zmemw16
Fri Jul 01, 2016 11:16 pm
RogerClark wrote:Yes.

1.6.7 has never been supported

Upgrade to 1.6.9 as the Arduino team have now fixed the problems which broke things in 1.6.6,1.6.7 and 1.6.8


cimd
Sat Jul 02, 2016 12:24 am
Roger,

Thanks for the response. I’ve uninstalled IDE 1.6.7 and installed IDE 1.6.9, and yet I get the exact same results: IDE does not recognize the boards if the folder is in the mydocuments link; it does get recognized if it is in the arduino folder, but it doesn’t compile. Is the IDE 1.6.5 the only version that’s supported?


RogerClark
Sat Jul 02, 2016 1:13 am
1.6.5 was previously the last version that was supported, but when 1.6.9 came out, we found that they’d fixed the problems that they (the IDE dev team) had introduced in 1.6.6

I just tested that the F407 compiles OK under 1.6.9

Did you read the FAQ ?

viewtopic.php?f=2&t=873

DId you install the Due first so that the IDE has the ARM compiler


cimd
Sat Jul 02, 2016 12:41 pm
Yes, I already had the Due installed as I also own one. I even tried downgrading it to the same version you showed in the video you mentioned. Yet the STM32-Arduino is not recognized by the IDE.

I don’t think the issue is about compiling though. When I moved the STM32-Arduino folder into the program files folder, it was compiling. I was just getting include errors due to the change on the installation folder. I tried changing the link reference on the core files, and the compiler was recognizing the files once updated. But there are so many files… :oops: too much of a work.

I also find it very strange you are using this C:\Users\Ingo\Documents\Arduino\hardware folder. I’d never used it before. None of the boards I install on the IDE are installed in this folder. They all go into here: C:\Users\Ingo\AppData\Local\Arduino15\packages.

Anyway, I’m using windows 10. I currently have the IDE 1.6.9. And due 1.6.8 installed. I’ll keep trying …


cimd
Sat Jul 02, 2016 1:07 pm
Update: I was watching this video: https://www.youtube.com/watch?v=Ze6q6NidS5w and on minute 2:35 of the video I understood what I was doing wrong. :D He installed the STM32-Arduino folder in the ~/Arduino/hardware folder, and not on the C:\Users\Ingo\Documents\Arduino\hardware.

And the thing is that I have changed the standard sketch folder of the IDE to my google drive folder, hence the IDE not recognizing the C:\Users\Ingo\Documents\Arduino. Roger, maybe it is worth mentioning on the installation instructions that it should be installed on the sketches/hardware folder, and not on the C:\Users\Ingo\Documents\Arduino folder, as some dumb people like myself might change that. :)

Now I’m getting this error:

AVISO: A categoria '' na biblioteca RTClock é invalida. Definindo para 'Uncategorized'
AVISO: A categoria '' na biblioteca SPI é invalida. Definindo para 'Uncategorized'
AVISO: A categoria '' na biblioteca UIPEthernet é invalida. Definindo para 'Uncategorized'
Aviso: platform.txt do núcleo '[0}' contém algo depreciado (recipe.ar.pattern="{compiler.path}{compiler.ar.cmd}" {compiler.ar.flags} {compiler.ar.extra_flags} "{build.path}/{archive_file}" "{object_file}"), automaticamente convertido para recipe.ar.pattern="{compiler.path}{compiler.ar.cmd}" {compiler.ar.flags} {compiler.ar.extra_flags} "{archive_file_path}" "{object_file}". Considere atualizar este núcleo.
arm-none-eabi-g++: error: Drive\1: No such file or directory

arm-none-eabi-g++: error: Projetos\0: No such file or directory

arm-none-eabi-g++: error: Arduino\Sketches\hardware\Arduino_STM32\STM32F4\cores\maple/libmaple/usbF4: No such file or directory

arm-none-eabi-g++: error: Drive\1: No such file or directory

arm-none-eabi-g++: error: Projetos\0: No such file or directory

arm-none-eabi-g++: error: Arduino\Sketches\hardware\Arduino_STM32\STM32F4\cores\maple/libmaple/usbF4/STM32_USB_Device_Library/Core/inc: No such file or directory

arm-none-eabi-g++: error: Drive\1: No such file or directory

arm-none-eabi-g++: error: Projetos\0: No such file or directory

arm-none-eabi-g++: error: Arduino\Sketches\hardware\Arduino_STM32\STM32F4\cores\maple/libmaple/usbF4/STM32_USB_Device_Library/Class/cdc/inc: No such file or directory

arm-none-eabi-g++: error: Drive\1: No such file or directory

arm-none-eabi-g++: error: Projetos\0: No such file or directory

arm-none-eabi-g++: error: Arduino\Sketches\hardware\Arduino_STM32\STM32F4\cores\maple/libmaple/usbF4/STM32_USB_OTG_Driver/inc: No such file or directory

arm-none-eabi-g++: error: Drive\1: No such file or directory

arm-none-eabi-g++: error: Projetos\0: No such file or directory

arm-none-eabi-g++: error: Arduino\Sketches\hardware\Arduino_STM32\STM32F4\cores\maple/libmaple/usbF4/VCP: No such file or directory

exit status 1
Erro compilando para a placa STM32 Discovery F407


martinayotte
Sat Jul 02, 2016 1:11 pm
C:\Program Files (x86)\Arduino\hardware\Arduino_STM32\STM32F4\cores\maple/wirish.h:37:22: fatal error: libmaple.h: No such file or directory

martinayotte
Sat Jul 02, 2016 1:15 pm
But it seems to be an issue with the spaces on the folder names. I’ll see what I can do about that.
That is another IDE bug mentioned in the beginning of the current thread by someone last year.

cimd
Sat Jul 02, 2016 6:21 pm
HOORAY! We never forget a first blink led. :-)

Ok, guys. I made it to work, thanks to you.

Do you guys need any support / volunteering work to be done on the F4 development? Let me know if I can help, and if its in my knowledge level. :D

PS: I can even use Visual Micro on MS Visual Studio.


RogerClark
Sat Jul 02, 2016 9:49 pm
@cimd

Thanks for the feedback.

I agree I should say to install in the Arduino sketches folder, but there are many people using linux and osx, which is why I just say the “Arduino” folder, as its location changes depending on which OS you used.

Re:Visual Micro

Yes. Visual Micro have registered with this forum, and they provide good support for Stm32


martinayotte
Sun Jul 03, 2016 1:08 am
@cimd, Glad to you got up and running with F4 !

For the community, I would ask you to provide details of experience, because I can’t figure out what was the steps that bring you for failures to success.
(was it to simply change Install path ? moving folders around ?)
This will greatly help any newcomers on the forum …


cimd
Sun Jul 03, 2016 2:52 am
@martinayotte

Glad to help. Here is an installation instruction: https://github.com/cimd/STM32F4-DISCO

I’ll see how I can improve it tomorrow (feedbacks are always welcome). It’s kinda late here.


Leave a Reply

Your email address will not be published. Required fields are marked *