
This 12 months’s Hackaday Supercon, the primary since 2019 because of the pandemic, was once an excessively identical affair to these of the previous. Virtually each and every hardware-orientated hacker tournament has its personal customized digital badge, and Supercon was once no other. This 12 months’s badge is a simulation platform for a hypothetical 4-bit CPU created by means of our personal [Voja Antonic], and offered an actual problem for probably the most attendees who had by no means touched gadget code throughout their adolescence. The problem set was once to get a hold of probably the most fascinating hack for the badge, so collaborators [Ben Hencke] and [Zach Fredin] set about nailing the ‘expandr’ class of the contest with their optical punched card reader bolt-on.
Peripheral connectivity is fairly restricted. The speculation was once to construct a bolt-on board with its personal native processing — the use of a PixelBlaze board [Ben] introduced alongside — to maintain all of the scanning main points. Then, as soon as this system at the card was once learn, sell off the entire thing over to the badge CPU by way of its serial interface. With out get right of entry to to their same old amenities again house, [Ben] and [Zach] clearly needed to improvise with no matter that they had with them, and no matter might be scrounged off different badges or different {hardware} mendacity round.
One large factor was once that the general public don’t generally lift photodiodes with them, however happily they remembered that an LED can be utilized as a photodiode when reverse-biased correctly. Feeding the sign evolved over a one Meg resistance, right into a transconductance amplifier courtesy of a donated LM358 there was once sufficient variation for the STM32 ADC to reliably hit upon the variation between unfilled and crammed check-boxes at the filled-in program playing cards.
The CPU required 12-bit opcodes, which clearly implies 12 photodiodes and 12 LEDs to learn every phrase. The PixelBlaze board does no longer have this many analog inputs. A easy trick was once as a substitute of getting discrete inputs, all 12 photodiodes have been stressed out in parallel and fed right into a unmarried enter amplifier. To distinguish the other bits, the illumination LEDs as a substitute have been charlieplexed, thus turning in the person bits as a series of values into the ADC, for next de-serialising. The demonstration video displays that it really works, with a program loaded from a card and kicked into operation manually. Such amusing!
Punch playing cards generally have a hollow via them and can also be learn robotically, and are an effective way to configure testers like this fascinating vacuum valve tester we lined a twinkling of an eye again.