The V-USB library is a pretty handy piece of code that lets you add USB connectivity to ATtiny microcontrollers (it was previously named tinyUSB). But if you’ve ever looked into adding the library to your own projects you may have been stymied by the complexity of the code. There are many examples, but there’s a lack of a concise quick-start for the uninitiated. [Joonas Pihlajamaa] has been working to correct that shortfall with his four-part V-USB tutorial series. It’s not for the absolute newbie; you should already be comfortable working with AVR chips but that’s the only real prerequisite we can see.
He starts the series with a look into the hardware considerations. USB provides a 5V power rail but the data lines expect 3.3V logic so this must be accounted for. With the test rig built on a breadboard he moves on to pick apart the code, covering various user-defined variables that you’ll need to set based on your project’s needs. We’re going to keep this on the back burner and hopefully the Troll Sniffing Rat will get a makeover (although we must say comments have been a lot nicer as of late… keep it up!).
We’ve embedded links to all four tutorial parts after the break.
- http://codeandlife.com/2012/01/22/avr-attiny-usb-tutorial-part-1/ (primer)
- http://codeandlife.com/2012/01/25/avr-attiny-usb-tutorial-part-2/ (hardware)
- http://codeandlife.com/2012/01/29/avr-attiny-usb-tutorial-part-3/ (software)
- http://codeandlife.com/2012/02/04/avr-attiny-usb-tutorial-part-4/ (wrapping up)