Unicorn HAT diffuser

I own a lot of HATs for my Raspberry Pi. Between the Unicorn HAT, Scroll pHAT and Blinkt! you might say I’m addicted to LEDs but I’ve recently managed to find a new addiction in 3D printing.

Whilst the Unicorn HAT is a lovely, colourful, 8×8 matrix, the individual NeoPixels are naturally round and quite bright. Needing to get to grips with our Maker Space’s 3D printer I decided a good first project would be a diffuser that would turn those circular LEDs into square ‘pixels’.

unicornhat

Having seen a similar accessory designed for larger NeoPixel boards I set about designing a version for the smaller (and much more cramped) Unicorn HAT. Being my first foray into 3D printing, I not only had to get used to the intricacies of my CAD  program of choice, but the intricacies of the 3D printer as well! As such I went through multiple revisions and test prints before landing on the final design. Armed with Autodesk’s 123D and a ruler I set about throwing a grid together, but quickly determined that I needed to be somewhat more precise about my measurements. After I acquired a digital caliper I threw out my original design and started from scratch.

diffusergrid

The first version of this was printed using black PLA filament, but unfortunately didn’t fit on top of the Unicorn HAT nearly as nicely as expected. Whilst the walls of the print were designed with 1mm thickness, they came out nearer to 1.4mm. It did however prove that the concept worked, so it wasn’t a total failure. Knowing that the width of the extruded filament was 0.4mm I went back to the design and reduced the thickness of all the walls to 0.8mm. After some fiddling with the slicing software I managed to ensure that the next print would come out correctly. It did and the grid fit perfectly over the HAT. Here it is running a little Matrix-inspired example.

img_20160711_184158

Unfortunately that success was short-lived. Having run the LEDs for a while, the plastic began to heat up and warped, no longer properly fitting over the board. Fortunately we have some ABS in the space, so a quick re-print and I had something that would hopefully be a bit more heat tolerant. This time I covered it in some sticky-vinyl for a very pleasing effect.

img_20160715_153400img_20160715_1551162

This print showed no evidence of the warping that the PLA did, even after long periods of running all the LEDs and the white plastic allows a nice amount of bleed-through between pixels.

In hindsight, this probably wasn’t the best project for a beginner especially seeing as it needed to be very dimensionally accurate but I learnt a lot through the process. If you have a Unicorn HAT, the design is available on Thingiverse.