User forums > Embedded development
Looking into CodeBlocks and CodeSourcery
jmhill:
Hello Folks;
I've been happily running CodeBlocks, writing non-embedded applications. CodeBlocks is convenient to use on both Linux as well as Windows.
I've long seen the ARM new project wizard icon and have been curious. Over a year ago I had a start with CodeSourcery lite which is command line only, without an IDE. I was distracted and was not able to follow through.
So, please, is developing embedded applications with CodeBlocks worth doing? What hurdles did you overcome or need to overcome? What tools do you use with CodeBlocks?
Best;
Jonathan
oBFusCATed:
Hm, I guess it depends on the board you have for programming. (I'm not embedded programmer myself)
What compiler it requires?
What is the method for sending the compiled code to the board?
Is there a simulator?
Does it support remote debugging with GDB or any other debugger.
jmhill:
Thank you for replying.
I'm using an Atmel AT91SAM7S256 chip, it's an ARM7 chip with 256K bytes of flash
and 64K bytes of RAM.
The CodeSourcery lite package contains gcc, binutils, gdb, a simulator among other things.
I've built a simple example that calculates factorials and I used the simulator and gdb
to run it.
The chip is on a board from Olimex, it's a SAM7-P256 board. I'm going to use a tool
with JTAG which supports the gdb remote protocol, so that I'll be able to use gdb.
I was struggling with the ARM-USB-OCD JTAG adapter which works with OpenOCD, so
I'll give the Segger J-Link JTAG adapter a try, when it arrives.
Given that I can now use gdb with the simulator to run code that I've built, the next
step is to build a simple example at the command line and run it on actual hardware.
I have example code to study from Atmel. If that goes well, then I hope to get things
working with CodeBlocks.
'Best;
Jonathan
scarphin:
I've been compiling, linking, programming and debugging (on the actual hardware) Atmel AVR MCUs with avr-gcc using CB for a long time now. There were a couple of problems at first but most of them are solved as of yet. Afaik CodeSourcery is the gcc clone for ARM so u can try messing with it by copying the arm-gcc in CB and adjusting the settings for correct executables. No one can guarantee u won't run into problems though. That's the cost of using open-source. ;) But in the end CB team offers good support imo.
jmhill:
Thank you for your reply. I'm glad to hear of your success.
I'm still getting the underlying tools to work. So far, here are the choices
o Which compiler - I tossed a coin and chose CodeSourcery over that built for YAGARTO
o Which linker scripts to use - there is some variation.
o Which set of start up files to use - each tutorial example has it's own make file and start-up files.
I was able to download and run an example binary using the SAM boot assistant, the program blinks the LEDs, so I know the board is working. I was able to build an example from Atmel and was also able to download the binary, but the example was written for a different board so nothing actually happens.
I'd like to do some remote debugging with gdb and will be digging into that literature.
Best;
Jonathan
Navigation
[0] Message Index
[#] Next page
Go to full version