Appnote of the Week: 2-axis compass

This week, from Honeywell, an application note on building a digital solid-state 2-axis compass:

Reference Design: Low Cost Compass

This design uses the HMC1052 sensor. You can get that sensor, the processing circuitry AND the microcontroller all rolled into one I2C-addressable package as the HMC6352 – a bit of a pain to solder but VERY easy to use. Currently about $40 from Digikey Canada.

The main disadvantage of this arrangement is that it requires the unit to be basically perfectly level for the reading to be good. If you want to accomodate some tilt, the Honeywell HMC1055 sensor kit is what you need: an HMC1052, an HMC1051 (for Z-axis) and a MEMSIC accelerometer for tilt. Available cheap from Digikey, just add microcontroller (and code, and opamps, etc.)

3-Axis Compass Sensor Set HMC1055

For all that compassy and tilty goodness in a single I2C-addressable package, you want the HMC6343, which at $166 from Digikey right now, is an obscenely expensive way to do it, but nice and self-contained.

Appnote of the Week: Logic Analyzer

Xilinx has an interesting article on embedding instrumentation in a design for field debugging. Within that appnote is an interesting section that gives you the building blocks you need to start designing your own logic analyzer:

Embedded Instrumentation Using XC9500 CPLDs

Naturally, there’s still some work to be done with it, but it’s a decent enough start.

The UNIX Way at its worst

So it seems the Pidgin IM project is run by a bunch of jerks. Read here:

http://developer.pidgin.im/ticket/4986

A summary:

  • Entry box in 2.4.0 is made to be auto-resizing
  • Users hate it, and file bugs saying they want manual resizing back
  • Developers indicate they have no intention of fixing it
  • Users get angry
  • Developers get pissy, and indicate that any changes submitted will be rejected
  • Project is forked

It’s obvious from some of the comments that the users are at times going a little overboard, but there’s no excuse for the developer response (which, to date, has been “It’s our project, nyah!”).

To all developers: these are your users. Without them you are nothing. If they say the “feature” is crap, it’s crap. People who make software for money, by and large, get this point, lest they finally learn their lesson when they’re out of a job. One can only hope that by removing this motivation for Open Source projects, they have not doomed themselves to a future of of irrelevancy.

Remember kids: ideological purity is for philosophy students. Everything in reality is a compromise between an ideal design and what actually works.

Appnote of the Week: Battery Charging

Charging batteries properly is more difficult than you might think, and definitely more difficult than cheap power tool companies engineer for. The simple lightweight charger that comes with a cheap cordless drill is almost assuredly a piece of crap that will kill the batteries in short order.

Smart chargers monitor the state of the battery to cut off charging at the proper time. For NiCd and NiMh cells, this reduces cell damage. For LiIon cells, it reduces explosions and generally highly-exothermic scenarios. Atmel’s got a decent appnote on some of these algorithms:

AVR450: Battery Charger for SLA, NiCd, NiMh and Li-ion Batteries

Now you can build your own, and keep from having to buy a new drill just to get a new battery (that the store you bought it at no longer has / wants 80% of the price of the drill for).

Appnote of the Week: DTMF Generation

I once had an idea for a portable speed-dial device that you held up to a payphone to dial any of, say, 100 stored numbers. Software with that capability on PDAs were the first nail in the coffin for me on that idea; that someone had done it before, along with the whole rise of cellphones thing, pretty much sealed the deal. This would still have been interesting to read back then, though:

AVR314: DTMF Generator

The appnote basically gives the derivation of a DDS system for DTMF signals, and the included flowcharts and descriptions would make this a snap to implement on any microcontroller, Atmel or otherwise.

Metaboard: Arduino in fewer parts

A very cool project: someone’s taken an ATMEGA168 and written a bootloader that emulates the USBasp. This allows it to download code directly over USB – with no on-chip USB peripheral or other USB chip – using a programmer protocol already supported by avrdude. The whole thing fits in 2KB of Flash space.

What this means, is you can make an Arduino-alike, with only one IC (save for the voltage regulator), which still works with the Arduino software for downloading (make a small configuration change). The only disadvantage is that you lose 3 I/O pins during bootloading, and you don’t get a USB-Serial channel back to the PC.

The Metaboard – check it out. Uses the USBaspLoader from Objective Development, who developed the AVR-USB software USB framework.

uWatch – A DIY Programmable Scientific Calculator Watch

Saw this linked from EMSL: The coolest watch ever.

I only hope the guy updates his site soon – I want to see what went into getting it done.

Neat Article: Illuminated Buttons

A really cool article: Making your own illuminated buttons. A pretty cool technique, and doesn’t use anything overly esoteric.

Stuff I’ve been up to lately: Iron Ring

It seems I’ve been neglecting this blog ever since, well, I started it. Which is itself a very blog thing to day. I kind of feel the need to post some updates that I should have been posting all along, but rather than sneakily backdate them to make it look like I had my act together and was just never publishing drafts, I’ll just add posts as they come to me to fill in the blanks.

I’ll start with getting my iron ring. Some friends have already written about this, so I’ll just briefly recap: around the beginning of the 20th Century, some important Canadian Engineers decided it would be A Good Idea to have some sort of ritual to impress upon new Engineers that they have huge responsibilities to society now. They enlisted the help of Rudyard Kipling to develop an appropriate ceremony, who came back with such a thing, and a symbol of that commitment: The Iron Ring.

Mark's Ring
Figure 1: Mark Jobes’ iron ring.

This is a big deal for Engineers, as it’s one of the last things to happen before you graduate (and arguably more important to us than Convocation). At most universities, the ceremony is accompanied by epic partying, but at McMaster, the whole shebang is referred to as Kipling, and starts the night before the ceremony with some epic pranking – which I will cover later. Suffice to say, I got no sleep the night before, which made things… interesting.

The day of the ceremony was a rather celebratory occasion. We started off with an Electrical and Computer Engineering breakfast – good food, and some inspiring speeches from various profs and other Faculty members. We then headed over to the David Braley Athletic Center for the ceremony itself, and proceeded to wait for (what seemed like) an hour in line. The ceremony consisted of <REDACTED />.

When we were done all that, we all stared at our hands in disbelief (except Kofta, who shouted a lot). Due to massive lack of sleep, I remember very little of the time between then and getting to the party at Liuna Station – I’m fairly sure that I wound up at West End with Mark and Kitt, and I know I made it to the bus from Mac to Liuna Station, where I’m told I fell asleep. After that, what I do remember, is probably best left unpublished :)

All in all, an excellent time despite the lack of sleep – and that’s (part of the) Stuff I’ve been up to lately.

Great Moments in WTFery: Scrabu…WTF?

I consider myself a reasonable kind of guy. Nonetheless, when I try to play a move in Scrabulous on Facebook, and I see this… well, I kind of lose it.


I mean, seriously? I don’t think randomness has failed me that much since I got a Super 7 ticket with 4 consecutive numbers.