Small as this is, I found myself wanting to shrink the electronics footprint of a wearable circuit even more. I didn't have a need for some of the Gemma extras such as USB connector or JST for LiPo battery. So, I decided to experiment a little to get a wearable circuit to the bare essentials.
I already had in my toolkit the Adafruit USBtinyISP programmer, and the Evil Mad Scientist '2313 Target Board with ZIF socket. This board has a simple jumper modification to allow it to be used with ATTINY45/85.
This tutorial is written using Ubuntu 12.04LTS as the OS. For Windows or Mac, you will have to make some changes.
- First, you must have an arduino environment modified for ATTINY. Here's a straightforward explanation, using an ISP (In-System Programmer).
- Choose ATTINY85 8Mhz internal as your board.
- "Burn Bootloader" using the USBtinyISP attached to the target board
- You may need to burn fuses as per Ray's forum post:
Now, you're ready to upload the strandtest sketch. In the Arduino IDE, go to File/Preferences and make sure that "Show Verbose Output during Compilation" is checked.
Load your sketch. In my case, it was from the Adafruit NeoPixel libary, strandtest. Compile/Verify the sketch. At the bottom of the Arduino IDE, you will see the verbose output. The target compilation directory for all the files, including the hex file, will be shown in this window. Mine went to /tmp/build786510750882563862.tmp.
Go to a command line and change to the compilation target directory. Do a search for your hex file. From the command line issue a command similar to this one, using your hex file:
avrdude -c usbtiny -p t85 -F -U flash:w:strandtest.cpp.hex
Now, transfer your ATTINY85 to your circuit. In my NeoPixel soft circuit, Adafruit recommends using a 470 Ohm resistor on the digital output connected to the first NeoPixel in a strand.
Here's the simple circuit detail: