User forums > Embedded development
Starting with STM32F401 Codeblocks
BlueHazzard:
Only to make clear why we make you go this way:
Codeblocks is not a compiler, but a IDE. So that codeblocks can work you need a working compiler environment. The link i posted tests this environment. As far as i can see there is all compact and neat described, because if you develop for embedded systems you have to check a lot other things too, like the linker script. If you test your compiler environment with the above link, we can be sure that the compiler is working as expected and so all problems we will encounter are codeblocks related and not compiler related...
--- Quote ---If I try to build the c code you gave me nothing happens. No error but also nothing else.
--- End quote ---
please post allways the exact steps you do. Only this description won't help anyone.
yvesuhc:
So everything i did till now:
I downloaded the GNU Tools ARM Embedded and placed it inside my programmx86 ordner.
After that i changed the settings of the GNU GCC Compiler for ARM in Global compiler settings.
I changed the files:
C compiler ->arm-none-eabi-gcc.exe
C++ compiler -> arm-none-eabi-g++.exe
linker for dynamic libs -> arm-none-eabi-g++.exe
linker for static libs -> arm-none-eabi-ar.exe
resource compiler -> nothing
make programm -> make.exe
So i realy DONT KNOW if these are the right files. these are the files in the toolchain but i dont know if they are the right ones becuase there was no readme.txt file or anything like that
So now my question did i MISS somehting here ? did I install the toolchain on the wrong place ? do i have to put it inside the codeblocks ordner ?
Thx for answers
:)
stahta01:
Did you install the Compiler?
I ask this because you said you placed it inside a folder; but, you never said you ran the installer.
Edit: If you installed the Compiler, did you set the path to the Compiler in the Code::Blocks settings?
--- Quote ---NOTE: The compiler's installation directory is exactly this: the installation directory. Not the "bin" subdirectory nor any other.
--- End quote ---
Tim S.
BlueHazzard:
1) Try not to use paths with spaces, or non ascii symbols, this makes things more complicated
2) You probably need to run the installer for the compiler, not only copy things. It does not have to be (my personal opinion: IT SHOULD NOT) be in a sub folder of codeblocks
3) The names look ok
4) You can create a empty project, or you use a ARM project
5) If you have a problem always post a full rebuild log in code tags: http://wiki.codeblocks.org/index.php?title=FAQ-Compiling_(general)#Q:_How_do_I_report_a_compilation_problem_on_the_forums.3F
6) Have you tried the example from the link? (This link does not use codeblocks, so you should also not use codeblocks) For this you should check that your compiler installation is in the PATH environment variable of your console
i hope you don't loose the motivation, because as soon as it works it will be awesome ;)
yvesuhc:
Ok so far so good but i dont know how to compile a programm wiht the console. The Link you send me also doesnt explain this.
Also there is no file to download so i guess i have to put the code inside a text file and change the .txt ???.
other than that the toolchain is in the PATH variable so i should be able to use it.
Thx for the help
Edit: btw if i simply copy past the text this happens:
C:\Users\Lord>arm-none-eabi-gcc -c -fno-common -O0 -g -mcpu=cortex-m3 -mthumb -o main.o main.c
arm-none-eabi-gcc: error: main.c: No such file or directory
arm-none-eabi-gcc: fatal error: no input files
compilation terminated.
I think that means that at least the compiler works but now i have to edit the comand to my own folder.
Navigation
[0] Message Index
[#] Next page
[*] Previous page
Go to full version