Looking for a super geeky card to make for that special someone? You could always buy a Hallmark card but let’s be honest, that’s just being lazy. In this post I’ll show you how I made my own for my partner’s 24th birthday.
Hit past the break to for a video of the card.
Here’s a bill of materials:
- Acrylic – aka Plexiglass. I cut out two 5″x7″ pieces from a sheet ~$5
- Double sided copper clad board – You’ll only a credit card sized piece ~$3
- ATTINY85 – You can get the DIP or SMT ones. I used a DIP but later wish I hadn’t.~$2
- Arduino, or a ATTINY programmer
- Speaker – I scavanged mine from a broken cell
- LEDs – SMT looks best. Anything between 2 and 6 of them works well
- 3v Coin battery - I used a CR2032
- Other stuff: Laser printer, paper, exacto knife, Ferric Chloride, Nail polish remover/paint thinner, lots of patience and deep rooted issues with generic cards
I started off with programming the ATTINY plugged into my Arduino. There’s a great tutorial that you can find at the MIT’s Media lab here. Once you’ve got your Arduino and ATTINY85 talking, you can start making music with MuseScore and a pretty nifty python script from John at jarv.org. Tutorial, another tutorial and GitHub. John’s musical card is one of two beautiful builds that have made my card possible. The other is this LED based card build by Windell. You guys are amazing. Thank you. If you’re ever in Toronto, I’d love to buy you a beer.
Download: GreetingCard-Arduino-ATTINY85 (The Arduino/ATTINY85 code I used. Its a lot of altered, and a bit simplified code from jarv with the addition of blinking LEDs and 1 less speaker)
My girlfriend’s favourite cartoon happens to be The Little Mermaid so I used a Little Mermaid midi file that I found on the internet, put it through MuseScore after taking out most of the song (it was wayyyy too long). Plugged it into PlayTune and plugged that into John’s code along with a Happy Birthday tune, wired up the speaker and voila, I had the musical part all done.
Now to make the circuit in something more sophisticated than a paper napkin. I used Eagle. Its great because its simple to use, has lots of great Youtube tutorials and has very comprehensive libraries from Adafruit and Sparkfun. Once that was all done, I plotted out the circuit and transferred it over to Photoshop (save as pdf). Added some text, made battery contact pad bigger and added a picture of me and my partner on the back as nice touch. If you want to put in photos, follow this tutorial.
Up next was making the circuit board. I’ve never made a circuit board before so this was probably one of the more challenging aspects of the project for me and I made a ton of mistakes along the way. Hopefully the next time it’ll be a smoother ride…
First mistake: trusting a friend to bring over the laser printout of the PCB on the right paper. He printed it on regular paper that simply isn’t the best to work with but it was the night before and the only other option was breaking into the nearest Kinko’s. Lesson: use magazine, glossy, inkjet, or pretty much anything but regular paper. It’ll work but its a pain and it won’t be pretty.
I cut out the right sized piece of copper clad board with a Dremel. That was the next mistake. Dremels are not the easiest thing to cut with in straight lines. Lesson: Use a guillotine.
Used a laminator. Useless. Ironing time. Got distracted watching GoogleWacking, and almost burned the bathroom down. Lesson: If you possibly have ADD, don’t go near hot objects. Find a responsible adult.
Pop it into water and let it sit for half an hour. Put some soap in it, it seems to help. Then scrub off the paper first with your thumb then with toothbrush. Also, you’ll never be able to use the toothbrush again so don’t use one you’re attached to. Once I got the paper all out, I popped it into a batch of Ferric Chloride and put a hair dryer to it. Not fast enough. Microwave? It helped, but 30 seconds seemed to be a bit much. Use 15s next time.
The traces came out relatively intact, lost a bit of detail but overall looks passable. Pour some nail polish remover, scrub some more and you’re almost there.
Time to make some holes. Lesson: Make sure you have a small enough bit. I did not. This DIP was now going to have to be surface mounted. No way around it. Bend some pins, clip off the excess and voila, kinda works. Oh wait, I need the negative to go to the other side of the PCB. No worries, drill a hole and pass a wire through and solder on both sides. *sigh* It looks terrible and my OCD is screaming at me but its 5AM already.
LEDs came next. I had an ingenious plan for this. Mount them across edges of the board and this is one of the few ideas that worked without too many issues. SMT LEDs are very very tiny and I used 0603. That’s 1.6 mm × 0.8 mm. Also they were white and I was working on a white table so you can imagine my frustration every time I’d drop one. It was easier after the first one though. Use lots of flux and make sure you drop a bit of solder onto where the LED will sit. Place the LED with some non magnetic tweezers (I have slightly magnetic ones and they are bloody annoying) and simply move the solder up onto the LED pad. The other side is a piece of cake after.
Fixed up the board with a bit of copper tape where my etching messed up and the PCB was all done!
Now I had to cut a hole in it and for some reason (maybe the fact that it was now 7AM), I decided that it would be a good idea to use a soldering gun with a flat head. It wasn’t. Lesson: Do not ever attempt to cut acrylic with a soldering gun. If it seems like a good idea, stop. Go to bed, It isn’t. Use a dremel, fine toothed saw, jigsaw, anything but a stupid soldering gun. It’s like trying to kill Santa Claus by sitting on him. It’ll eventually work but its just the most idiotic way to do it.
Anyway, it did cut. But at this point I was much too tired to get a tab-thing working for the switch after half an hour of experimenting. So I ended up taping a piece of copper wire to a piece of paper attached to a piece of clear tape slightly curved outwards and stuck to the PCB. Also I drew a nice green ON sign on it. It looked hideous but its the thought that counts, plus the rest of the card looks fantastic. I think it adds character… That touch of hacked love.
The front of the card was another piece of acrylic featuring Hipster Ariel. Clear tape was my bff. And of course, here’s a video of it in action:
She loved the card and I like making mistakes, it helps me learn. But despite the endless blotched details, I’m quite proud of the card and I hope you build something. Anything. Even if you think you have 0 skill, dive right in, have fun and don’t stop till you’ve created something cool.