Close

Design Choices

A project log for Pokey Watch

A chromatic tuner for musical instruments in a pocket-watch form factor. Perfect for the classy musician.

dbtayldbtayl 08/17/2014 at 20:200 Comments

This is just a brief discussion of some of the choices that were made in the design of this project.

First and foremost, everything was designed to be fabricated and assembled by me, "in house" so to speak. That meant that any chips had to be hand-solderable, any boards had to be CNC-millable, and the enclosure hand to be machinable either by hand, CNC, or both.

The IC selection was easy- I knew I wanted an ARM Cortex part, mostly because I've recently started playing around with them, and also because a 32-bit platform seemed more useful for some of the larger data values I was going to work with. I chose the NXP Cortex-M3 because I had a dev board already that had a similar chip, and because it came in an easily[-ish]-solderable package. The voltage regulator and battery charger are ones I'd worked with in the past and had lying around, in addition to being easy to solder. The other parts (op-amp, LEDs, etc.) were chosen based on whatever fit.

For the board itself, the fact that I was milling it meant that keeping vias to a minimum was ideal. I have to hand-solder vias, and that's no fun. I managed to get just about everything on one side, with the exception of one trace for the lithium ion battery. As it turns out, this is good, since the battery would be under the board anyway, so having its connection point there is no problem.

The enclosure design was a little trickier. I started out by trying to find out how big a pocket watch was (not having one, I really didn't know). Through sampling eBay auctions, looking at pictures online, and some guesswork, I decided 50mm across by 10mm tall was reasonable. That eventually grew to 54x11mm, based on wanting some more space for the PCB and battery.

With the size determined, I had to actually machine the part. Using my lathe was my first thought, since it's a round part, but that was quickly found to be a dubious option, as cutting off an incredibly thin (3mm for the lid) section after machining was... difficult. At least for me. So I turned to a CNC-milled design. The whole thing is roughly 2.5D, except for the USB connector cutout. I'm still working on how to mill that out... I made one prototype (lid and base), but my hinge design was awful. I had left ~3mm square of metal for the hinge, which didn't play well with a 1/16" hole (sorry for mixing units- my tooling is Imperial, but some of my design is metric). Hence the new design that can be seen in the images at top.

Finally, the software. I decided on an FFT because that's pretty much the limit of my DSP knowledge, and when you only have a hammer, everything seems to look like a nail. That said, I haven't found a better approach, and this one seems to be working pretty well. There weren't really any other significant software design decisions; it's pretty simple stuff.

If I had to do the whole thing again, I think the only thing I would really change is the microcontroller. Since starting out with NXP parts (because they were easy to program over a simple serial connection), I've found that the STM32 parts are also easy to work with, and seem to play a little nicer with a GCC toolchain, mostly with regard to linkers. I could be less of a sissy and just write my own linker scripts, but that's not my idea of a good time (I want to build stuff, not fight with my tools). It seems especially nice since evidently the Bus Pirate can be used as a programmer, eliminating the need for me to buy one specifically.

That's all, folks! (at least all I can think of at the moment)

Discussions