I have been playing around with the AVR VUSB library for the last little while. This library allows you to build USB devices with most AVR microcontrollers. The first small project I wanted to implement was an external USB volume controller that acts as a regular multimedia keyboard and therefore works with pretty much any device that supports USB keyboards.

As part of this project I also wanted to give PCB etching a go, which seems like a nice way to quickly manufacture high quality PCBs for one-off projects.

In the first step I designed the circuit and the PCB layout in KiCad. When etching PCBs, the main problem is that you have to work with a single layer PCB and therefore the layout process becomes a bit more complicated. You want to avoid having to add jumper wires. With this PCB, I ended up adding 4 jumper wires (green in the PCB layout).

Schema:



PCB Layout:



I went with 2mm traces because I wasn’t sure how good the quality of the etched PCB would be. This is also the reason why I went with the DIP package of the ATMega328. The etched PCB turned out very well though. In my next project I will try to go with a TQFP package and no through-the-hole components. That way I don’t have to drill and the PCB could be considerably smaller.

This is the process I followed pretty closely:



I ordered the required items off eBay for around $50. You can re-use the etchant and developer multiple times and this set should yield probably 20 smallish PCBs. I got the transparency with 6 printouts of the copper layer from my neighborhood copy store for $0.75. All in all cost per PCB is around $3 and turnaround time is around 1.5hrs including setup and cleanup. There are many different methods out there, i.e. toner transfer but the process with the pre-sensitized photo resist boards seems the easiest and least error prone in my opinion.

I exposed the PCB for 10 minutes in a dark room with 2 20W CFLs from 25cm (10 inch) and etched the board for 30 minutes in the ferric chloride solution (at room temperature 25C/77f). I stacked 2 transparency printouts on top of each other to work around inconsistencies in the printout. The biggest hurdle I encountered was that I had to mix the Ferric Chloride with water at a specific ratio (100g of Ferric Chloride to 250ml of water – 40% Ferric Chloride). I didn’t have a scale though. I ended up improvising a balance scale from a level, 2 Coke bottles and some coins. To avoid all this hassle I would recommend buying pre-mixed Ferric Chloride. My Amazon shopping cart has a cheap scale waiting to be purchased now 🙂

The improv scale worked surprisingly well:



The next image shows the evolution of the PCB, from transparency to fully assembled PCB. Another mistake I did was to drill the holes too big (1mm). It turned out fine at the end, but the next time I will definitely use a smaller drill.

The firmware and the KiCad files are available on GitHub. Another design mistake I did was not to include an ISP header for programming the board. This made the initial setup and fine tuning a bit tedious, because I had to remove the microcontroller each time I wanted to make some firmware change. From now on, no more boards without programming headers.

The final assembly mounted:



And the button next to my headphone stand:



This was a really interesting project, with lots of new challenges and I’m pretty happy about the final result.

For completeness, the BOM: