Making 1,750 programmable PCB badges for Canada's biggest hackathon
Pangram verdict · v3.3
We believe this text is mainly human-written, with some AI content.
AI likelihood · overall
HumanArticle text · 1,187 words · 6 segments analyzed
At most hackathons, your badge is a piece of cardstock on a lanyard. This year at Hack the North, Canada’s biggest hackathon, it was a circuit board with a screen, buttons, and a radio, and you could program it to do whatever you wanted. On the Saturday, a team walked up to me holding four of them. They’d turned them into a working game of Among Us. Eight months earlier, our badges were going to be made of cardstock too. If you want to play with the badge before reading, go ahead! I made an emulator: The badge's real firmware, compiled to WebAssembly. Everything is open source: the hardware (KiCad), the firmware, and the emulator. Why not cardstock In mid January, my friend Alex (a PM at Hack the North) asked if I wanted to join Hack the North. The moment I got that message, a vision popped into my head. What if we brought the badge culture of cybersecurity events into the world of hackathons. What if we made a wave so big other hackathon organizers couldn’t ignore it. What if we brought hardware badges into the mainstream of hackathons. This was our goal. I quickly put together a deck and pitched the idea to the organizing team. Here’s the executive summary: LEDs (as many as we can fit) Screen Battery Buttons Audio Wireless features Cool shape Silkscreen art Lanyards Oh, and all for $5 / head (boy was I naive). I made it super clear that we’d need multiple hardware iterations to de-risk and guarantee the success of this project. We initially scoped for an EVT (Engineering Validation Test), DVT (Design Validation Test), and 2-3 PVTs (Production Validation Test). We wound up shipping in four iterations, with the fourth being our production run. Built into the original pitch was an escape hatch to rapidly de-scope to blank badges, meaning ordering the badges without the components assembled which would drastically reduce cost. Without this safety net, I don’t think this project would have taken off. The directors, very understandably, did not want this project to (perhaps literally) blow up in our faces. (This was indeed a real risk we considered. Battery safety must be taken seriously.) The initial kickoff meeting ran quite late. As you can see we had quite a few messages in the thread too ranging from reasonable concerns to brilliant ideas! Engineering Validation Test (EVT) I had so much energy going into the initial schematic. It’s like the initial development of a software side project: pure forward development with no scaling problems, bugs, or tech debt. It didn’t have to be pretty, the primary goal was to prove the parts work together. Here is our first schematic iteration! We’ll get into all the mistakes I made soon. As for layout, well, I kinda took charge on it and of course went for the timeless classic: the hexagon. Why? Because HEXAGONS are the BESTAGONS. The team were not hexagon ball knowers unfortunately. The hexagons stuck around as an engineering test, but the ill fated shape would be killed off in the next iteration. We placed the order on February 15th using JLCPCB, our manufacturing partner in China. A few issues ensued: Part selection error On USB, everything worked. On battery power, nothing. The culprit was in the part selector list: Can you spot it? C10, C14, and L1 are on the same line. 😱 I labelled capacitors C10 and C14 as “10u”, meaning 10 microfarads. Unfortunately, I also labelled L1 “10u”, which tricked the part finder into giving me a 10uF capacitor in the place of a 10uH inductor. The opposite of what I wanted! This was a quick fix. We took a note to not make this mistake again, and on the EVT we were able to just short the inductor and it worked. This probably introduced a lot of noise and efficiency losses into the system, but it was able to handle it somewhat gracefully. Fine for an EVT at least. Lesson Write unambiguous values (10uH instead of 10u). Don’t blindly trust the part finder. Check twice. Pins too dense to solder Most small screens come with a thin ribbon cable hanging off them, called an FPC (flexible printed circuit). The normal way to attach one is with a small connector on the board: slide the ribbon in, flip the latch closed. We decided to skimp out on the connector. The plan was to stick the screen down with adhesive and solder the ribbon’s contacts straight onto pads on the board, saving about five cents a badge. Any experienced hardware engineer reading this is wincing, I can practically see them.
A soldered ribbon is hard to assemble reliably, and once it’s on, replacing a cracked screen requires hot air and a very steady hand. With 1,750 badges at a hackathon, some screens were going to crack.
I knew this was the riskiest part of the assembly. I just wanted to see if we could get away with it. Turns out: nope! About ten days after we ordered, JLCPCB emailed to say the pins were too dense to solder. They offered me two options: leave the screens off entirely, or pick a different part. I cooked up a third idea.
The FPC connector I should have used from the start happened to fit the pads I’d already laid out for the ribbon. JLCPCB soldered the connector onto those pads, plugged the screen into it, and taped it down, all for an extra $4.25 total.
We got lucky, and that connector solution stayed with us until the very end. Lesson Don’t ship manufacturing problems off to the manufacturer. Own them, figure them out, and be clear with them. Then, a few days later… The badge is real! We hopped right onto a call to chat about it. We started testing right away with some basic bring-up firmware to make sure the peripherals worked. Keep in mind this was before the days of zero shotting this sort of thing with AI. But did it work? Mostly! Once we fixed the L1 inductor issue, all features on the badge worked except for NFC. And even NFC technically worked. It just did the wrong thing.
NFC chips come in two roles. A reader, like the one in your phone or a door’s card scanner, powers up a field and scans things. A tag, like the chip in a transit card or an NFC sticker, sits there passively and gets scanned. We wanted our badges to scan tags. The chip I’d picked was a tag. A phone could scan our badge, but the badge couldn’t scan anything itself. What we really wanted was for two badges to tap together and swap contact details. That needs a chip that can switch between both roles, known as peer-to-peer mode, and those chips cost more than our budget allowed. In hindsight, badge-to-badge NFC was a bad idea anyway. NFC is finicky even with a well-tuned antenna, and ours was barely tuned. The ESP32 already had Bluetooth, which can do the same job without two strangers lining up their badges just right.