I've created a quick little screencast explaining how to upload the
LittleWire firmware to a digispark, turning it in to an AVR/PIC programmer, as well as allowing access to all of LittleWire's other features. It's a handy tool for experimenting as it lets you talk to SPI, i2c, and 1wire devices from languages including c, c++, c#, python, ruby, and processing. Ihsan - the creator of LittleWire also helped create some of the software used by the DigiSpark - the micronucleus program we'll be using to upload our program.
An AVR programmer is particularly handy because you can buy the same ATtiny85 chips used by the Digispark in their raw form for about $3 each, and by hooking them up with a programmer you can upload Digispark programs directly on to them. They're a little bit smaller, but they don't have the USB port or power regulator, so they need to be powered by a five 4.0-5.5 volt power supply - a USB phone charger works great! A couple of dollars cheaper might not seem like much, but it's been very important for me when doing art installations which used ten or more chips to drive large
collections of lights.
Using the LittleWire libraries (including the
ruby version I made) you can quickly experiment with talking to accelerometers, temperature sensors, iButtons, RFID readers, analog sensors, servos, and all sorts of other gadgets in a more concise language than the C-based code used in the Arduino software. I especially like using Ruby because the Interactive Ruby program lets you type in and run code line by line, seeing the return values of functions immediately. It really is a much nicer way to experiment than trying to print out debugging stuff through DigiUSB or serial ports or whatever else. If you're going to leave your device plugged in to a computer anyway it often makes more sense to write all the code on the computer and just puppet it with a firmware like
LittleWire too.
Digispark LittleWire tutorial from Jenna Fox on Vimeo.
LittleWire homepage:
http://littlewire.ccLittleWire Github Download:
https://github.com/kehribar/Little-WireThe process should be very similar on other operating systems - you'll just need to find the micronucleus binary in the digispark arduino installation in another way, and I'm not sure if the dragging files on to a terminal will work on every operating system.