New Tutorial: ARM Development with Eclipse

Readers contemplating buying the Olimex LPC2000 ARM boards from Spark Fun may enjoy the tutorial “ARM Development with Eclipse.”

I developed the tutorial for students and hobbyists and it describes how to create a low cost Eclipse/GNU ARM software development system using open-source compilers, debuggers, etc.

While the sample programs are specifically designed for the LPC-P2106 Olimex board, one reader has already used this information on a LPC-P2138 board.

It’s a 10 mbyte download, about 150 pages in length.

Hope you enjoy it, I’ll try to incorporate any corrections you find.

The tutorial is hosted by Olimex on their LPC-P2106 and ARM-JTAG pages.

http://www.olimex.com/dev/pdf/ARM%20Cro … clipse.pdf

Good luck and enjoy,

Jim Lynch :smiley: :smiley:

I have posted a major revision of the tutorial “ARM Cross Development with Eclipse Rev 2” on the Olimex web site:

http://www.olimex.com/dev/pdf/ARM%20Cro … on%202.pdf

This revision uses the latest releases for Eclipse and CDT (as modified by the Norwegian company Zylin) and uses the Eclipse debugger rather than the RedHat Insight debugger employed in the original tutorial.

The sample projects can be found here:

http://www.olimex.com/dev/soft/arm/LPC/source_code.zip

The Eclipse debugger is quite sophisticated so this tutorial revision is worth a look.

Cheers,

Jim Lynch

Hi Jim - can you go over how one would do things differently for an Atmel ARM chip? I’m working on a project with an Atmel AT91SAM7X256 and have been a bit confused in how to properly set up the compiler and everything else.

Hi Jim. Thanks for taking the time to write and share the excellent tutorial!

I just bought Olimex’s LPC2294 header board and I can’t wait to play around with it. I looked through your tutrial and it looks like it will definitely get me started. Hopefully I’ll also figure out how to develop for and burn to this thing in Linux as I don’t really use Windows much.

hello,

i cannot download the tutorial. when i do it just downloads a file which is less than a kb. i think there is something wrong with the olimex website.

Hi Anaoum>

I just checked the Olimex site and the link associated with the ARM-JTAG product downloaded OK for me.

The tutorial is here:

http://www.olimex.com/dev/pdf/ARM%20Cro … on%203.pdf

The source code is here:

http://www.olimex.com/dev/soft/arm/LPC/sourcecode.zip

Give these links a try and report back.

Cheers,

James P. Lynch

Thanks, the link worked and the tutorial is great.

Just one Question, will this setup allow me to program the ARM’s FLASH with The JTAG Wiggler from olimex, and if so how?

Thanks

With the hardware setup and software components described, you cannot program the flash via the JTAG. You still have to attach a COM1 serial cable and program the flash with the Philips IAP Flash Loader utility. Then you use the JTAG to debug the downloaded executable.

Dominic Rath is working on a replacement for the proprietary Macraigor OpenOCD utility, I think it will support JTAG programming of the flash. His utility is very close to being completed. You can check his progress at this web site: http://openocd.berlios.de/web/

Cheers,

Jim Lynch

can this same setup of software be used on linux?

The OpenOCD is being developed on Linux, so there shouldn’t be any problems. All parts of Jim Lynch’s tutorial are available on Linux, too.

Thank you for this tutorial and, mostly, for your sample code.

I installed gnuarm on Linux and compiled your code, and now I have working PLC code and an example to start with that has all of the memory mapping and PLL stuff working correctly. That’s incredibly helpful!

I like your tutorial.

I would like to take it to the next stage and start pulling all the required elements together into a single place.

I think pulling all the files you will need from the web onto a single CD would make it easier.

The next stage after that would be to make an installer to install everything in one go.

What do people think.

P.S. How are you getting on with the OpenOCD based version of thr tutorial ?

I completed the first draft of a revised tutorial (which includes Dominic Rath’s OpenOCD utility) and submitted it to the Eclipse Foundation as a Eclipse Corner article. So far, I haven’t received any feedback from them.

If you are interested in looking at this draft, the web page version can be downloaded from here: http://www.megaupload.com/?d=M5XSJSVV

The Microsoft WORD version may be downloaded from here:

http://www.megaupload.com/?d=6JSVK5SZ

I like your suggestion to develop a “hands off” installer. I have no experience with installers but the Cygwin operates with such an installer so it is certainly feasible for somebody to create.

Gathering all the downloads into a CDROM sounds good, but remember that this tutorial is currently running 2000 downloads a day. One could get overwhelmed for CDROM requests - you’d need a professional CDROM copy device to keep up. Probably makes more sense to keep it all electronic and on the web.

Cheers,

Jim Lynch

Just have to say what a great book it is. I’ve already recomended it to 2 friends.

Although I’ve used a different ide, I’ve read my way through other parts of your book and it was of great help to me. I particularly like how how you’ve described all the details right down to compiler flags in the makefile.

I was able to modify the sample code given and flash/ram config to suit the Olimex H2294 board and find a suitable header file on the net to get an led flashing :slight_smile:

Still plenty of nightime reading for me to do but just have to thank you for putting the time and effort into writing such a great book!

Cheers,

Mikael

I take you point about the bandwidth required. I was planning on putting it on sourceforge.net.

I have done a few windows installers so I can look into that.

I started looking at doing an Eclipse installer. There was some information but it looked very complex. I will do some more digging.

I get my inspiration for this from projects like this :-

http://sourceforge.net/projects/yawamp/

http://sourceforge.net/projects/phptriad

http://sourceforge.net/projects/xampp

If they can have three projects for web development then why not at least one for embedded !

As long as there are no objections to your tutorial being used as the basis for such a project I can proceed to “Make it so !”.

Now is an exiciting time with a complete easy to use Open Source dev tool only a few weeks away.

Well maybe months :wink:

I have downloaded the latest version. Looks good.

One comment :-

"This is an uncompressed Unix-style “Tape Archiveâ€

Hi jim I just thought I would pass on some feedback on you tutorial.

I downloaded the the web page version.

  1. There are a lot of duplicated files in the folders just look in the three folders.

  2. I opened the file in Firefox 1.5 on an old laptop with 192MB of RAM. It was very very slow, and almost impossible to scroll. I guess it was holding uncompressed versions of all the pictures in RAM. It was slow as it was swapping out to disk heavily.

  3. Some of the images were of very poor quality, however you converted them from screenshots needs to be changed. I find www.iranview.com and png files work well for screenshots.

  4. I have now read three diffrent versions, A) Eclipse/OCDemon/Insight B) Eclipse/OCDemon/CDT and the latest Eclipse/OpenOCD/CDT. They all have thier merits and I think it would be nice to pull out the two old debugger sections as seperate articles, with a refernce to them in the new article.

I have had no time to go back to getting my Olimex LPC2103 board with Olimex Wiggler working yet. I may try later today. No much time left in the day here in England :frowning:

All the best, and keep up the good work Jim!

I have been diligently trying to improve the tutorial “ARM Cross Development with Eclipse” for the last year, but there are times where it seems like I’m shooting at a moving target.

For example, Zylin does not archive old versions of their modified CDT plug-in and the downloads mentioned in the current Revision 3 tutorial no longer work. If you try to use the “latest and greatest” Zylin plug-ins, you’ll find that they have some problems that render the debugger useless. These will eventually be fixed, but what can be done right now?

I collected all the downloads (minus the cygwin stuff) into a single zip file and placed it on the http://www.megaupload.com web site. This collection represents versions of Eclipse, the Zylin plug-ins, JAVA, GNUARM, etc. that work together harmoniously. This is a 198 mb file and takes about a hour to download on a high-speed internet connection.

Included files:

ARM Cross Development with Eclipse Revision 4 Draft.doc (draft tutorial)

ARM Cross Development with Eclipse version 3.pdf (tutorial)

bu-2.16.1_gcc-4.0.2-c-c++_nl-1.14.0_gi-6.4.exe (GNUARM)

eclipse-SDK-3.1-win32.zip (Eclipse 3.1)

embeddedcdt-20050810.zip (Zylin CDT)

zylincdt-20050810/zip (Zylin CDT)

hwsupport-2.16.exe (OCDRemote)

jre-1_5_0_06-windows-i586-p.exe (JAVA)

openocd.zip (OpenOCD)

philips_flash_utility.zip (flash)

SourceCode.zip (sample code)

The link to this components download is:

http://www.megaupload.com/?d=CNY1Y6DX

If you want to try the OpenOCD JTAG debugger, there are instructions on its use in the draft tutorial above; just stick to this set of downloads and everything will work smoothly.

Hope this helps.

Jim Lynch

Thanks for this I am d/l it now.

I have most of the stuff already, but I want to see what versions you have exactly.

I still would like to start a project to make CD for ARM Devlopment.

I want to look into Jigdo, which is a way of stiching files together from the web to make a CD.

Have you contacted Zylin about them keeping older versions available ?

I guess it will be a problem until the Zylin CDT is merged into the base CDT.

I have some news. I have my own LPC2103 board flashing a LED now, I have your tutorial to thank for that.

If we had a project page on SourceForge or BerliOS then I could post up my linker script and code.

I will try and do some digging on Jigdo in the next week or so and see if it is in a usable state.

Al the best.

==============================

FordP, from the Garden of England

Time is an illusion lunch time doubly so!