The SMD Challenge

Stock photo of LED lamps, from https://unsplash.com/photos/qzT3HVp1Mis

I learned about the SMD Challenge from a post on Hackaday, adequately entitled ‘An Unfortunate SMD Project’. With a fair share of the required components already in my parts boxes, I decided to place orders for the remaining stuff (LEDs in 0402 and 0201 form factors as well as resistors in 0201), and get a set of PCBs manufactured to test my skills.

Parts list

The following picture shows (almost) all the parts needed to complete the project:

Self-compiled kit

Soldering

Soldering was unexpectedly easy. I started off with the 1206 resistor and LED, and used the test points to the left and the right to probe whether the LED would light up using a Brymen BM235 multimeter’s diode test function. As soon as reaching 0402, I soldered the resistor in first, and used the test point on the left and the LED’s cathode pad to verify it made good contact, before adding the LED. It turned out the most challenging part was to figure out the cathode pin of the 0201 LED. As there was neither a marking on the case nor on the pins, there was a 50/50 chance of getting it right in the first attempt. I eventually assumed the end of the LED that had a slightly darker shading was the cathode; a guess that turned out to be correct. Phew.

At last, I added the capacitor and the microcontroller, which posed no challenge given the huge pin spacing in comparison to the 0201 devices. It was equally simple to solder the battery clip to the back of the PCB. Now, how to get the LEDs flashing?

Assembled device

Uploading the firmware

I downloaded the firmware for the ATTINY85 from the Hackaday project page; the file I used is named SMD_challenge_Cylon.ino. Compilation is easiest through the Arduino IDE, as the code uses a number of macros (like pinMode()) that would pose issues when using avr-gcc directly. To compile for the ATTINY85, make sure to install support for the ‘attiny’ cores by means of the board manager. Once compiled, grab the .hex file output; the compilation log output tells you the temporary directory in which it’s located.

I used my Atmel ICE programmer with some header pins inserted, and manually pressed them onto the pads to flash the device (which only takes a few seconds). Note the orientation of the ISP header: The square pin (bottom right in above photo) is VCC (pin 2). The following avrdude command line finally uploads the hex file to the MCU.

avrdude -p attiny85 -c atmelice_isp -e -U lfuse:w:0xE2:m -U hfuse:w:0xD7:m -U efuse:w:0xFf:m -U flash:w:SMD_challenge_Cylon.ino.hex
Yesss, it's working

Bottomline

A very nice project that keeps you entertained for an hour or two. If you’re not too keen on sourcing the parts yourself, I’ve seen people sell readymade kits on Tindie as well. It’s a great opportunity to see how you’re handling those tiny parts (and with a little pride I can confirm that no part was lost in the process).