7
votes

I will embark on the ARM Cortex M3 bandwagon soon with an official training (CPU side).

Now, I did a bit of Arduino and AVR before and have some basics in electronics but I am mostly a software developer. I've read most topics in here and quite a bit elsewhere regarding the tools available and they have been really helpful. What I need is something to connect all those answer elements together.

I would like to equip myself with a starter kit that is general enough to get me going and that at least allows me to experiment different hardware/software combinations (Steppers, CAN-Bus, SPI etc...). I am looking at the following list (please feel free to add more items!):

  • Cortex M3 Chip
  • Evaluation board
  • Tool Chain
  • JTAG tools

For the chip I would like one of the higher-end models to be able to try a bit of everything. The NXP LPC1768 seems like a good choice but there is also STM and Stellaris to consider.

Interesting candidates for the board right now are the Keil MCP1760, the STM3210E-EVAL but I am afraid of vendor lock-in as I would like to be able to try various toolchains on a single board. mBed is very attractive but out of the equation because of it's online compiler (unless a regular compiler can be used as well)

For the Toolchain, I have a "feeling" towards IAR, Rowley Associates. I would prefer ease of use/well-doneness vs open source and preferably tools that could be used on multiple targets.

Do I really need a JTAG unit? If it's a "standard industry tool" like it seems to be I would like to at least get some experience on it. It looks like another source of vendor lock-in tough. Would I be better of using an external one I can familiarize myself with or just using one included on the evaluation board?

Basically, I need help in choosing a winning combination for the aforementioned categories. Is it even possible or am I being naive and should look at saving costs because I will end up buying one of each in the end?

Thank you.

RESULTS: What I ordered:

I finally bought Joseph Yiu's "The Definitive Guide to the ARM Cortex-M3 (Embedded Technology)", found some training for the CortexM3 platform (coming soon) and bought an STMicro kit: STM3210C-Eval which has a bunch of sensors built-in and is not vendor locked to a specific software environment. I also picked-up a few STm32vl-Discovery boards (13$cdn from digikey!) with on-board JTAG. I am now playing with an evaluation version (32K) of Keil's uVision IDE and I can say that I am REALLY impressed! I was able to re-build the Discovery's firmware, load it back, and step through it with the debugger in a single day!

Thanks everyone!

4
You might want to ask this on electronics.stackexchange.comKevin Vermeer
Thanks, great site, Another bookmark!Zot Ditz Myo
I have the stm32vl discovery but just got the stm32f discovery. 168Mhz, i and d caches, floating point unit, crypto, hash, a fair amount of memory, lots of flash, etc, etc. for $20 or less. the mbeds are going into storage and these are staying on my desk. github.com/dwelch67/stm32vld/tree/master/stm32f4dold_timer

4 Answers

3
votes

both llvm and gcc are perfectly fine, no need to buy any software. Most folks out here providing free help are going to be gcc users. Codesourcery is the current place to get the newer/better gcc (for arm). The lite version is perfectly fine. Rolling your own gcc is a relatively easy thing, but maybe not something you are into. A nice thing about llvm is that it is always a cross compiler and pre-builts usually have several/all targets.

I also have stellaris and mbed and other cortex-m3 examples out there. I like stellaris, not a fan of lpc, avoid the expresso, the mbed is actually not bad. The crazy bright blue leds give me a migrane so I replaced them with green, otherwise it works just fine, easy to use. Igor is right you are not locked into their sandbox like you are with the expresso, I have an example blink the leds using gcc to compile out there somewhere. you simply copy the .bin file to the thing which looks like a flash thumb drive and press the reset button to load the new file.

sparkfun.com has the stm32 header board for under $50 plus the mbed and who knows what else. The stellaris boards are in the sub $100 range and are perfectly fine. I bricked my 811 almost immediately by accidentally doing exactly what the warning said not to do. Turned my jtag gpio pins the wrong way and...game over. The 1968 and other non-811 series are either non-brickable or not as easy to brick. The stellaris boards chew up all the io with onboard peripherals which is fun for a while, but not if you want to do something other than just how to use those peripherals. You will want a jtag wiggler if you are using the stm32 header (avoid the stm primers) amontek makes a good one, the jtag-tiny, and the olimex one should work fine, but I actually dont know that I ever got mine out of the box. In theory one stellaris board can be used as a jtag wiggler for another or for other cortex-m3s. if you have a stellaris board you wont need anything else, everything you need comes in the box for one price, well if you dont want to use that toolchain then you can download one listed above.

2
votes

You might want to look at the Atmel ATSAM3U-EK dev kit (approx. $200 from Digi-Key). It has an LCD touchscreen, accelerometer, temperature sensor, analog inputs, JTAG, two serial ports, and USB 2.0 (built into the SAM3U).

The thing I like about the SAM3 series is the easy bring-up. It has an on-board ROM as well as flash for program storage. From the factory, it boots the ROM (you later change it to boot from flash), which fires up the USB port, which declares itself to be a USB Communication Device Class (CDC), and runs the SAM-BA boot monitor. It also has an on-chip ERASE pin that resets the whole thing to factory settings.

So all you have to do, to reprogram from scratch, is:

  • Jumper ERASE for at least 200 ms with the power on
  • reset and plug the board into a USB port
  • run Atmel's SAM-BA program on either Windows or Linux
  • select the serial port
  • enable flash writing
  • select your binary file and send it
  • set it to boot from flash
  • unhook the USB and hit reset again.

No dongle or JTAG box needed. I know that reprogramming via JTAG through IAR is probably fewer steps, but I like knowing that there's a way to get to a known state if the other tools break.

The IAR toolchain supports the SAM3 series, and there is a port of FreeRTOS to SAM3U + IAR (which I'm now trying to port to SAM3U + GCC since IAR's $5K licenses are too rich for us).

Another neat thing about the SAM3U-EK: It has a NAND flash on board, and if you plug the board into a computer while it's running the demo, it will mount the flash on your computer as a "flash drive". On this flash you will find the documentation, schematics, demo programs and libraries for GCC, IAR, and Keil toolchains, and instructions and files for restoring the demo program to the board (useful in case you think you broke something).

2
votes

For my part, I like the LPCXpresso board for LPC1768. It has a built-in USB JTAG interface and it comes with a free version of the Code Red IDE (Eclipse-based). I found the JTAG interactive debugging very helpful when learning to use this chip. Normally I don't use interactive debugging when I program, but for embedded programming I find it more and more essential.

The whole thing only costs $33 on DigiKey.

1
votes

I'm also a software developer originally. I used a couple of different kits, but the one I found most easy to use and did most with is mbed. You can literally get it up and running in five minutes from opening the box. No need to install any IDEs from the CD, no need for the JTAG dongles, no need to pour over datasheets - just write the code, compile and run.
Yes, some complain that it's "tied" to the online compiler. But I only heard that from people who did not actually try it. And it's just not true - you can still use any other toolchain that can produce binaries for LPC1768: IAR, Keil, CodeSourcery, Yagarto, or your own toolchain. I did not myself yet find a case for that, but it's certainly possible.
Probably the biggest disadvantage of mbed is that it does not expose the JTAG interface and so you cannot debug interactively. So far I did not find this critical but it might be important if you do a lot of low-level work.