08/08/06 - AVR Dragon

JTAG, DebugWire, ISP, PP, HVSP. USB. 53x105mm. Space for a ZIF socket. Groovy box. And all for well under $100?

My flaky jtag clone has been acting up for ages, so I was pretty stoked to hear about the AVR Dragon, Atmel's new low-costgeneric programmer + debugger. I finally laid my hands on one today and all I can say is: Wow, I'm impressed. Without putting too fine a point on it, it's everything I want in a programmer! We need good tools to do good work, and the Dragon fits the bill perfectly. If you haven't followed the recent forum discussions you could be forgiven for thinking: Doesn't the jtag mkii have a similar feature set? Yeah, sure, but it costs several times as much (and perhaps equally important, doesn't have space for a zif socket nor come in such a nice box). Anyway, without further ado, The AVR Dragon:

Orient vs. The Vikings:

 

Box top:

 

Underside:

 

Lid:

 

Inside:

 

First upgrade:

 

Hooray! I can flash a mega128:

 

I don't think anyone will disagree when I say I think this is going to have a profound impact on the AVR commmunity. I've used several DIY and clone debuggers and programmers, and they were pretty much all broken in some way or another. My JTAG has frequent disagreements with AVRStudio, my bit-banged serial port ISP programmer is slow as buggery, and they both eat up my laptop's only serial port. I've never even considered buying a mark ii jtag, I only do this stuff as a hobby and for uni so $500 or however much they are is prohibitively expensive. The Dragon appears to have solved all of these nasties in one foul sweep.

 

15/06/06 - Driving an 8x8 LED matrix

Now that I have a decent mega128 breakout board to plug stuff into I can finally do something with these matrix displays I've got lying around.

I wired up a single 8x8 display to my mega128 board and hooked them together with a hard drive cable:

The display is pretty easy to drive but the 16 inputs eat up two ports. Here's the diplay pinout:

Each row scans from top to bottom at a couple of kHz. The video shows how this works in slow-mo.

Here are some pics:

13/06/06 - ATMega128 breakout / simple development board

I've been needing a breakout boar
d for a mega128 for aaaaaaaaaaaaaaaaaaaaaages. I also wanted an excuse to try out a PCB manufacturer I found in China. Yes, I know, there are plenty of breakout boards available already but sometimes I just prefer to do it myself. I'm a total satisfaction junkie.

I built up the first one this afternoon. I pasted it and sat it on a clothes-iron set to full for a couple of minutes, using a heat gun to reflow it.

I was stoked to find everything worked first time. No tracks to cut this time! Not everything went to plan though - I forgot how large IDC sockets are compared to plain headers and the regulator got in the way of the jtag socket :-( Rather than risk plugging the jtag in around the wrong way (bound to happen) I just trimmed the corner of the plastic. Oh well, things to watch out for next time, when it might actually matter.

Features:

  • Convenient ATMega128 breakout board. Put the pins underneath and socket it to a motherboard, or put them on top for easy access to port pins.
  • Careful board design. None of this funny angle/.000000001 mil track/no ground plane/caps-and-xtal-miles -away-from-pins cowboy nonsense!
  • Onboard 3.3/5V reg (LT1117)
  • JTAG programming and debug connector
  • Power led
  • All pins brought out to headers and labeled (v. useful)
  • Reset switch
  • 5x3mm SMD strip xtal
  • Only 55x45mm

If you want one, send me an email. I've got a few boards and all the parts you'll need (less programmer).

13/04/06 - ISD1420 speech recorder

When I was working on BBot I played around with the WTS701 speech synth chip from Winbond, and wasn't at all impressed with how heinously complicated it was to get working. Talk about a convoluted interface! All that's really needed is to give the robot a small vocabulary of humorous and useful phrases ("Outa my way, punk!","Take us to your leader")

I came across the ISD1420 "ChipCorder" speech recorder IC (also from Winbond) recently and thought it looked promising. The chip holds up to 20 seconds of audio in up to 160 separate messages in a non-volatile analog storage array, each individually addressable. Several operating modes are available; message queuing, message looping etc and couldn't be easier to use. The chip has also input / output amps, automatic mic gain etc, so doesn't really need any extra hardware. Perfect.

Here's the block-diagram:

To test it out I used this circuit, straight from the datasheet:

And here's the end result (click for a short video):

The voice belongs to Crystal, who lives here. Thanks Crystal!

28/4/06 - DIY bikelights

I didn't have a decent flashing light for my bike, so decided to make one. I used a PIC 16F684 running off the internal RC oscillator set to 31khz (low power consumption). It works great, but resets itself to the default mode sometimes. I'm not sure if my dodgy 'midnight-engineered' code is to blame, or something to do with the PIC running straight off a 9V battery...

Here's the source, a video and some pics.

4 LEDs on each fork

Protoboard, PIC micro, mode button, current-limiting resistors. Pretty simple.

Battery+power switch

The battery and PIC live in the toolkit

If you look at the sourcecode you'll notice a couple of macros - slow() and fast(). One of the cool things about PICs (well some of them anyway) is that you can change the internal RC oscillator on the fly. I had a mode that bumped up the oscillator to 4Mhz (using fast() )just to perform the rand() function, then dropped it back to 31k when done (with slow() ). The mode didn't look that great so I removed it, but it's still handy to have software control of the system clock.

25/4/06 - Press n' Peel board for MMA7260 3-axis accelerometer

I just bought a laser printer so thought I'd whip up a board for my three-axis accelerometer (MMA7260Q from freescale, in a 16-QFN).

Here's the board.



The great thing about using really thin PCB material? You can actually see through it, which is a big help when you can't easily test the pins for bridges. Soldering these chips isn't really that hard (I used a clothes iron for a hotplate and paint stripper to reflow the solder paste), but its a bit more tricky than doing the same on a professional board with silkscreen as guide...

Here are the DXP files (including schematic and PCB libarary parts) if you want to make one yourself...

1/5/06 - Mikael tells me the mma6260 dual-axis accelerometer fits the same pinout (less one axis of course). If you don't have DXP I could probably make a pdf you can print onto pres 'n peel with, anyone interested? Nah, didn't think so...

Some notes on using press 'n peel

Something not everyone realises is that you don't need to put a whole sheet of PnP through at once. Just print the outline of your PCB, then cut out a piece of PnP slightly larger than your board and sellotape the leading edge down. Don't tape the trailing edge because PnP and paper expand at different rates.

Before applying PnP to the PCB you first need to polish the copper (well duh). The best way I've found is by using a PCB cleaning block, which leaves surface really shiny. Then you need to get rid of any grease with something that won't leave a residue. I have some foaming cleaner that does the job ok, but I hear MEK works well.