Minimus AVR USB

Thanks to this overly syndicated blog post (really – Planet Ubuntu I can understand given its content, but Planet Mozilla and Planet Inkscape, too!?) I discovered a wonderful little device called Minimus AVR USB. Basically it’s a USB-enabled (and USB-programmable) AVR microcontroller on a board with the I/O lines brought out to solder connections and just enough on-board peripherals (two buttons, three LEDs) to do some basic things without breaking out the soldering iron.

I’ve been meaning to get back into microcontrollers for a while and been tempted to go down the Arduino route, but too little spare time meant that I never got any further. Because of their slightly illicit origins as PS3 modding tools, Minimus boards are readily available at modding sites for just a few pounds (I bought mine for less than £5 from here).

I hope to post more about these in future, but I wanted to get an early post in to mention a little pitfall I fell into. I’m developing on a Ubuntu box and managed to get the AVR toolchain installed and working easily enough. I grabbed the demo code from the Minimus site and was able to push the hex file to the board in order to get the lights flashing and the buttons working. At least I knew the little board was operational.

Next I opened the source code, but as it’s been written to compile using AVR’s Windows toolchain I promptly ignored the build instructions and make file. “It’s just a few lines of code”, I thought to myself, “I can hand compile it easily enough.” So I did. And it compiled. And I converted the resultant file into a hex file for pushing to the Minimus. I pushed it with no errors, reset the device and… no flashing lights.

Many hours of tweaking that tiny source file proved that I could turn each of the lights on permanently, or off permanently. But I couldn’t persuade them to flash, and I couldn’t read the state of the hardware button. I threw in snippets of code I’d found to disable the watchdog timer, but still no joy. I tried setting the I/O lines using binary, hex, decimal, bit shifts and any other method I could think of. Nothing worked.

The solution finally came when I found some other code online and built using the make file. Suddenly the lights were flashing and the button was working! Something in the make file – one of the many switches to GCC probably – was sufficient to get things working. So if you find yourself here because you’ve bought a Minimus to play with and can’t seem to get it going, check that you’re building with a make file, not compiling by hand.

Comments (2)

  1. Hi Mark,

    I’ve just aquired a minimus avr usb board and am trying to get the tool chain installed under on of my OS’s.
    I tried to follow your link for the sample code but the info seems to have been taken down from the site.
    Do you know of any other links where I can get a copy?
    Do you have any suggestions as to the best tool chain for developing on this board.


  2. Hi Rick,

    To be honest I haven’t found the time to do anything much with my minimus since this blog post. I did write some code to make the hardware button trigger a fake Windows Key press but that’s about all (my 1984 vintage clacky keyboard lacks a Windows key, which is fine most of the time, but for those rare occasions when I actually need one I can just plug in the minimus and use the button on that). So I’m afraid that I couldn’t begin to tell you anything about the best tool chain.

    As for the sample code, it looks like the site is completely gone, but thankfully’s Wayback Machine captured at least some of it. This link should hopefully get you a copy of the file:

Comments are closed.