I have a university project going on at the moment, where the main goal is to learn something new, that hasn’t been, and won’t be, covered by our course material. Not too hard, given that my university is still pitching assembler for PIC’s as new and interesting. The module asks that we undertake a project, whereby we learn some new skills, and deliver an output that demonstrates them.

I’ve set out to get my head around the vUSB stack, and design a USB interfaced, 1-wire temperature sensor stick. Now so far I’ve only been used to serial communications, either over a RS232-TTL <-> USB interface, or using the on-board USB controller on the Arudino Leonardo. Reading and writing bytes directly to serial ports is a pretty easy system. USB adds a lot of overhead to that, but it’s too useful of a tool to pass up learning.

I’ve been following the well-doccumented vUSB tutorials from CodeAndLife, and I’ve managed to get a command-line controlled LED working (though you do have to read everything. Keep an eye out for the makefile for the command line exe!). Next up will be getting the DS1820 working, and modifying the LED switch code to handle data transfer. Watch this spot! Below is the hardware I’ve been using, it’s pretty damn simple! A few things to note are the 3V3 TO-92 regulator (USB speaks 3V3!), and the series + pull-up resistors on the USB connections, though they are barely visible in this photo!

ATTINY 2313 vUSB Stick