One can imagine a political or business conference without an interactive badge — but not a hacker conference. Does this make the case for hackers being a special breed of people, always having something creative to show for their work? Yes, I think it does.
Following the Hackaday Belgrade conference in April of this year, we met at the Supplyframe offices to discuss the badge for the Hackaday SuperConference that will happen in Pasadena on 5+6th of November. The Belgrade conference badge (which was fully documented if you’re curious) was surprisingly popular, and I was asked to design the new one as well.
I was prepared to come up with something completely new, but [Mike Szczys] suggested keeping with the same basic concept for the project: “No reason to change anything, we have a badge that works”. To which I responded: “Well, the next one will also work”. But then I realized that “works” does not stand for “being functional”. The key is that it was embraced by visitors who played with it, coded on it, and solved a crypto challenge with it.
The World Doesn’t Have Enough LEDs
Fast forward six months — here are the modifications made to the basic concept. First, the existing LED matrix, which was composed of two compact 8×8 blocks, was replaced by 128 discrete SMD LEDs. It was a much needed change to help scale down the dimensions and clunkiness, but also to avoid another painful experience of trying to purchase and have the matrix displays shipped, which seriously threatened the production of the previous badge.
It’s a long story which I discussed in my Belgrade talk — it turned out we did not manage to get enough common anode (CA) displays from all distributors in the whole world. We had a plan B, which also fizzled, leaving us with the plan C which actually included two “C”s: Common Cathode. We cleaned up all the supplies at five distributors, and managed to get 122 CA red, 340 CC red and 78 CA green displays (enough for only 270 badges) — the entire world supply. After that, you couldn’t get any 38 mm Kingbright’s display for months! The only problem was that there were two different versions of PCBs, one for CA and the other for CC displays, but luckily only one version of software, as it could autodetect the display type.
Motion and Expansion
So, what else was new in the concept? In the Belgrade version, the badge supported an accelerometer module and included an unpopulated footprint in case you decided to install it, but now the badge has the MEMS chip LIS3 as an integral part. There are nine pads (with five I/O ports, driven directly from the MCU) to which you can add a 9-pin expansion connector. There will be a number of these connectors at the Design Lab, so that anyone can expand their badge for their convenience, on the spot.
The Visual Design
The biggest change was in the visual design. What we came up with ended up being a fair bit smaller, lighter, with a more convenient shape, and less than half the thickness of the previous one. After we had scrapped quite a few ideas during the development process (including stylized skull, frog, etc), we were left with a couple of options which you can see on the image below. The wireframe drawing on the left hand side is the Belgrade badge, shown here for a size comparison. At this point the locale and date of the conference weren’t yet definitive, which is why you see San Francisco written on the images.
Design number 4 prevailed, so the PCB layout could begin. I don’t like autorouted PCBs, so I was in for quite a rough time trying to solve the routing manually having only 2 layers on the board at my disposal.
Routing a Compact LED Matrix
The LED matrix is so dense that there was virtually no room on the LED layer, so most of the tracks on the component layer had to be routed as if it was a single layer PCB. To make matters worse, the LED layer is routed as a matrix, with a bunch of horizontal and vertical tracks, otherwise a good reason to use a 4-layer PCB. To stay inside the budget, everything had to be placed on 2 layers, and that’s why the final result seems so confusing at the populated area between batteries:
That pretty much covers the changes — the badge is virtually the same as the previous one in all other aspects. It includes an infrared optical port, which uses the existing UART on the MCU, so it is easy to implement in user programs. Communication range is several meters, and as long as you are in a room with white walls and ceiling, you don’t have to worry about the direction of the transmitter and receiver. Every badge has its unique serial number, and the default infrared UART routine will receive only messages which contain the matching number in the address field of the header.
Hacking the Badge
The badge was presented in a video we published last month. We plan to have a lot of fun with this hardware throughout the weekend. SuperConference visitors will be challenged to use their badges to solve the special puzzle task, which will be composed of several layers. And we want everyone to give badge hacking a try, with firmware, hardware, or both.
Here is the schematic diagram for the new badge:
The badge is hacking friendly, as there is a USB port and bootloader, so the programming is fast and easy, even without a separate hardware programmer. All you need is your computer and one Micro-B USB cable, and you’re all set for hacking at the SuperConference.
The firmware is more or less the same as the Belgrade badge but the bootloader has been updated. Our friends at Microchip adapted their Xpress board bootloader for us so that the Hackaday SuperConference badge acts as a USB mass storage device. Simply plug in the USB cable, hold power while pressing reset, and drag your HEX file to the drive that appears on your computer.
There is a kernel in protected bootloader space which covers all BIOS functions. LED matrix scan is fully supported, so all you have to do in your software is write 0’s and 1’s to the 16-byte frame buffer in the Data RAM. All other services (keyboard scan, low power sleep ON-OFF, brightness adjust, infrared serial reception and pause screen) are also located inside the Timer Interrupt routine, so the user does not have to deal with low-level hardware if they don’t want to. Some more routines (32-bit pseudorandom number generator and Accelerometer support) are also available in kernel.
Choose Your Hacking Difficulty:
I Can Blink
Even those who have never touched a bare PCB can still easily get this badge to do their bidding. Start with the example in the C framework. Play around with which LED turns on and how to change the timing, then build your skills from there.
Bring It On
You fancy yourself a programmer? Show us what you can accomplish in one weekend. The low-level hardware servicing is completely handled for you, which means the rest is up to your creativity. Program a clever and creative user experience to claim your moment of glory.
Hurt Me Plenty
You are a wizard of embedded development. Read the schematic, grab a few datasheets, and take this to bare metal. Completely bypass the kernel in one of two ways. Start with the C framework but remove the “goto” assembly commands that send interrupts back to the kernel, giving you full hardware control. Or bring your own PIC programmer and completely blow out the bootloader and kernel. We only saw one person do this in Belgrade, but it was epic!
We have just published a C framework for badge hacking. You have your choice of installing MPLAB X and using the GitHub repo, or using the cloud IDE version called MPLAB Xpress.
Full documentation of the badge has begun. Follow along on the Hackaday.io page.
Will this be enough for a good time at Pasadena in November? That depends on you. If you plan on coming charged with some positive and creative energy, and even bringing some ideas with you — then there should be no room left for doubt in the answer!
Filed under: cons