Friday, December 30, 2011

ARM for Hobbyists

M0 mbed from mbed.org
ARM chips have gained a foothold in hobby electronics that I suspect will become fairly significant by 2015 or so.

Certainly some projects (several of mine included) will benefit from more RAM, larger program space, faster clock speeds, and 32-bit processors.

What's required for widespread uptake of ARM are a combination of free tools with libraries that simplify programming and low cost development boards that make prototyping easier.

  • Leaf Labs began providing an Arduino-derived IDE for their Arduino-compatible STM32 ARM-based boards some time ago. The Maple Native has been promised for quite awhile but nothing yet.
  • The mbed M3 and M0 dev boards with online compiler have been around for a few years now and are growing in popularity. The DIP package makes for easy breadboarding. The library is truly stellar and there's a big community and many user-written objects. An RTOS is available. Web-based compilation is quite fine if you're not in the field.
  • The LPCXpresso is a bit faster than the mbed at 120MHz and comes with a free IDE and features a DIP form factor, too.
  • To get down to the bare metal, CMSIS is a cross-platform library from ARM that abstracts the ARM core capabilities. As far as I know, vendors supply peripheral libraries. STM has a standard peripheral library, for example. DSP libraries are typically available, too.
  • Arduino and Atmel have teamed and announced the Due featuring a SAM3U, a 96MHz ARM Cortex M3. Still waiting on this (7/2012) and actually we've been waiting for quite some time. The big issue I see is that Arduino libraries don't even come close to taking advantage of all a typical ARM MCU's capabilities so presumably enhanced capabilities are in the works, but that is just my assumption.
  • The Wiring project (from which Arduino descended) plans to introduce STM32 ARM compatibility at some point. I've been waiting to see the home page announcement change for quite some time, now. Leaf Labs is working with Wiring now.
  • CooCox is an IDE, peripheral library, and set of tools intended for programming across multiple ARM families, with a few supported so far (7/2012). As ARM peripherals differ across families, this project is quite promising but like others, is dragging on.
  • Among a slew of hobbyist-unfriendly QFP packages, one ARM vendor, NXP, is supposedly going to release a 28-DIP form factor Cortex M0, the USB-capable LPC1114FN28 but I've been waiting for this to show up for almost a year now (7/2012). NXP offers M0s in SOIC and TSSOP form factors as well.
  • There are more than a few low cost dev boards out there. Too many to list, in fact.
Not that ARM is the only 32-bit, high performance game in town but I've become very interested in the platform in the last few months. I know this isn't a comprehensive list. If you know of other ARM-based development hardware/IDE platforms I'd love to hear about it.

Bottom line: your best bet is the mbed platform, I think. The library capabilities are awesome and you get a lot of community support. It's a huge step up from the Arduino paradigm many of us are used to. While we wait and wait for the Arduino Due, Wiring, CooCox, Leaf Labs solutions seem viable.

Otherwise you're left to coding your own stuff using CMSIS and vendor libraries. It's more painful and you're basically stuck with a particular vendor, maybe even a particular family.

Coding an ARM is quite a bit more complex than coding an 8-bit AVR and that may be why we haven't seen a clear open source winner emerge yet.

Friday, December 23, 2011

Pololu Goodies

Happy Holidays to those who celebrate!  Despite my fear of sounding like an advertisement, I love Pololu. Great people; they have always been friendly to me, and they come up with some really cool robots and components.

A few weeks ago I received a package with my Black Friday spoils and it was just like Christmas had come early.

Can't wait to try some high speed line following...

Mmmmm... tank treads.
Besides the above, I also ordered a 9DOF IMU and have implemented an AHRS using Pololu's sample code running on an ATmega328P.

Thursday, December 22, 2011

Jingle Bells


Ok, it's been done before, but why let that stop me?

Through the holidays, when you visit my blog, here, you'll add to the household festivities because a little bell in my office will jingle. And also, an angel will get its wings.

This version is a PC and Propeller-based holiday kludge-o-rama. Here's how...

Friday, December 16, 2011

Magnetometers and Motors

Test rig for current measurement
Now that I've got a mechanism for measuring motor current, it's time to try and quantify the effects of motor magnetic field on magnetometers.

Data Bus was cursed by Compass heading deflection earlier this year and I never discovered its cause. The error observed was on the order of 20 degrees or more.

As part of my ongoing work to get ready for the just-announced Sparkfun AVC 2012, I want to see if I can correlate motor current and magnetometer readings using a Honeywell HMC5843 3-axis magnetometer.

Friday, December 9, 2011

RadioShack? Yes.

I've been visiting Radio Shack stores since I started dinking around with electronics in high school in the 80's. I'm not affiliated with them, but I've always been a loyal customer. Though I've heard many hobbyists dis them over the years, at least they've always had components on the shelves.

But nothing like this!

Arduino and Parallax gear including a Propeller board!

The venerable Forest Mims III books are back and better than
ever along with other promising titles

I almost missed this entire endcap of Arduino,
Make and Parallax goodies
Propeller boards, Arduino boards, Make kits, gyros, GPS, and on and on. Radio Shack is carrying a lot of really great hobbyist/roboticist/maker/electronics nerd gear. Go check it out.

Never have I been so excited to visit a Radio Shack since the days of blue Archer packages and speech chips hanging by the dozens.

Radio Shack has been saying recently that they're committed to DIYers. If this doesn't convince you, nothing will.

Friday, December 2, 2011

Constructing RoboTurkey


Here are some construction details for RoboTurkey. Warning: lots of pictures and a video, to follow...