Hackaday Podcast 065: Game Boy Hacks Galore, Cable Robo Elbow, Pi Cam Solargraphy, And The Deepest Sub Is Crushing It

Hackaday editors Mike Szczys and Elliot Williams cover the hacks that made us happy over the past week. There’s an incredible cable-driven robotic elbow hack whose quality is only eclipsed by the fantastic explanation of how it works (like a block and tackle). Getting data like WiFi credentials into your embedded project may be just a blinking Android app away. Try your hand at digital solargraphy with creative use of f-stop and post processing. And Mike ogles an RC F-35 project while Elliot goes gaga for the deepest of all submarine designs.

Take a look at the links below if you want to follow along, and as always tell us what you think about this episode in the comments!

Take a look at the links below if you want to follow along, and as always, tell us what you think about this episode in the comments!

Direct download (60 MB or so.)

Continue reading “Hackaday Podcast 065: Game Boy Hacks Galore, Cable Robo Elbow, Pi Cam Solargraphy, And The Deepest Sub Is Crushing It”

The Nintendo Game Boy Color Is An Aircon Remote

Those of you who are familiar with 1990s handheld consoles may recall that Nintendo’s Game Boy Color had an infra-red receiver and transmitter. The thought of a handheld computer with infra-red capabilities interested [jg], who immediately set about converting it into a remote control for an air conditioner.

The Game Boy doesn’t have dedicated infra-red remote control hardware, instead the IR diodes appear to be connected to I/O lines. Thus the bitstream bas to be bit-banged, and takes the processor’s entire attention when transmitting. The software is neatly placed on a reprogrammed bootleg cartridge.

It’s an interesting read in terms of the approach to reverse engineering, for example finding the parameters of 37 kHz infra-red remote control by trial and error rather than by a quick read up on the subject, or searching for information on National air conditioners and finding nothing, but not searching the National brand itself to find that a search on Panasonic air conditioners would likely give all the information needed. But the end result operates the appliance, so it’s good to record a success.

This isn’t the first time we’ve seen a Game Boy control something, though we can’t recall seeing another using the IR. Need a brilliant overview of the Game Boy?  We’ve got you covered.

Thanks [Roel] for the tip.

Header image: Evan-Amos / Public domain.

Snakes And Ladders: Game Boy Emulator In Python

If a Game Boy was a part of your childhood, you were probably more than once dreaming of spending your entire school day with it. Well, they had to wait a few more years for that, but eventually in 2015, [Asger], [baekalfen], and [troelsy] made that dream reality when they created a Game Boy emulator in Python for a university project. However, it didn’t stop there, and the emulator has since grown into a full-blown open source project, PyBoy, which just reached the version 1.0 release.

Since it started out as an academic project, the three of them had to do their research accordingly, so the background and theory about the Game Boy’s internal functionality and the emulator they wrote is summarized in a report published along with the source code. There is still some work to be done, and sadly there is no sound support implemented yet, but for the most part it’s fully functional and let’s you successfully play your own extracted cartridges, or any ROM file you happen to have in your possession.

Being an emulator, you can also inspect its inner life when run in debug mode, and watch the sprites, tiles, and data as you play, plus do cool things like play the emulation in reverse as shown in the clip below. Even more so, you can just load the instance in your own Python scripts, and start writing your own bots for your games — something’s we’ve seen in action for the NES before. And if you want to dive really deep into the world of the Game Boy, you should definitely watch the 33c3 talk about it.

Continue reading “Snakes And Ladders: Game Boy Emulator In Python”

ESP32 Refines Game Boy Bluetooth Adapter

Last year we brought word of a project from [Shyri Villar] that turned a stock Game Boy Advance into a Bluetooth controller by exploiting the system’s “multiboot” capability. The prototype hardware was a bit ungainly, but the concept was certainly promising. We’re now happy to report that the code has been ported over to the ESP32, making the project far more approachable.

To clarify, the ESP32 is now the only component required for those who want to play along at home. Just five wires connect the microcontroller to the GBA’s Link Cable connector, which is enough to transfer a small ROM over to the system and ferry user input to the Bluetooth hardware. Even if you aren’t interested in using it as a game controller, this project is an excellent example of how you can get your own code running on a completely stock GBA.

While the original version of the hardware was a scrap of perfboard dangling from the handheld’s expansion connector, reducing the part count to one meant [Shyri] was able to pack everything into a tidy enclosure. Specifically, a third party GBA to GameCube link cable. This not only provides a sleek case for the microcontroller that locks onto the handheld with spring loaded tabs, but also includes a male Link Cable connector you can salvage. It looks as though there’s a bit of plastic trimming involved to get the ESP32 to fit, but otherwise its a very clean installation.

The GBA will be 20 years old soon, but that doesn’t mean the hardware and software exploration is over. The original Game Boy is over 30, and people are still giving talks about it.

The Ultimate Game Boy Talk

It is absolutely no exaggeration to say that [Michael Steil] gave the Ultimate Game Boy talk at the 33rd Chaos Communication Congress back in 2016. Watch it, and if you think that there’s been a better talk since then, post up in the comments and we’ll give you the hour back. (As soon as we get this time machine working…)

We were looking into the audio subsystem of the Game Boy a while back, and scouring the Internet for resources, when we ran across this talk. Not only does [Michael] do a perfect job of demonstrating the entire audio system, allowing you to write custom chiptunes at the register level if that’s your thing, but he also gets deep into the graphics engine. You’ll never look at a low-bit Pole Position clone the same again. The talk even includes some new (in 2016, anyway) hacks on the pixel pipeline in the last 15 minutes, and a quick review of the hacking tools and even the Game Boy camera.

Why do you care about the Game Boy? It’s probably the last/best 8-bit game machine that was made in mass production. You can get your hands on one, or a clone, for dirt cheap. And if you build a microcontroller-based cartridge, you can hack the whole thing non-destructively live, and in Python! Or emulate either the whole shebang. Either way, when you’re done, you’ve got a portable demo of your hard work thanks to the Nintendo hardware. It makes the perfect retro project.

Continue reading “The Ultimate Game Boy Talk”

There Really Was A Sewing Machine Controlled By A Game Boy

These days, high-quality displays and powerful microcontrollers are cheap and plentiful. That wasn’t the case a couple of decades ago, and so engineers sometimes had to get creative. The result of this is products like the Jaguar nu.yell sewing machine, as covered by [Kelsey Lewin].

The later nuotto model was capable of more advanced embroidery patterns. A Mario character cartridge was sold, while a later Kirby edition was scrapped before release.

The Japanese market product eschewed the typical mechanical controls of the era, to instead interface with a Nintendo Game Boy. The sewing machine would hook up to the handheld console via the Link Port, while the user ran a special cartridge containing the control software. This would allow the user to select different stitch types, or embroider letters. Very much a product of its time, the nu yell mimics the then-cutting edge industrial design of the first-generation Apple iMac. The technology was later licensed to Singer, who brought it to the US under the name IZEK. Sales were poor, and the later Jaguar nuotto didn’t get a similar rebranding stateside.

Back in the late 90s, the Game Boy was likely an attractive package to engineers. Packing a Z80 processor, buttons, and a screen, it could act as a simple human interface in lieu of designing one from the ground up.  Aprilia even used them to diagnose motorbike ECUs, and we’ve seen Game Boy parts used in medical hardware from the era, too. Video after the break.

Continue reading “There Really Was A Sewing Machine Controlled By A Game Boy”

Scott Shawcroft Is Programming Game Boys With CircuitPython

Some people like to do things the hard way. Maybe they drive a manual transmission, or they bust out the wire wrap tool instead of a soldering iron, or they code in assembly to stay close to the machine. Doing things the hard way certainly has its merits, and we are not here to argue about that. Scott Shawcroft — project lead for CircuitPython — on the other hand, makes a great case for doing things the easy way in his talk at the 2019 Hackaday Superconference.

In fact, he proved how easy it is right off the bat. There he stood at the podium, presenting in front of a room full of people, poised at an unfamiliar laptop with only the stock text editor. Yet with a single keystroke and a file save operation, Scott was able make the LEDs on his Adafruit Edge Badge — one of the other pieces of hackable hardware in the Supercon swag bag — go from off to battery-draining bright.

Code + Community

As Scott explains, CircuitPython prides itself on being equal parts code and community. In other words, it’s friendly and inviting all the way around. Developing in CircuitPython is easy because the entire environment — the code, toolchain, and the devices — are all extremely portable. Interacting with sensors and other doodads is easy because of the import and library mechanics Python is known for, both of which are growing within the CircuitPython ecosystem all the time.

CircuitPython is so friendly that it can even talk to old hardware relatively easily without devolving into a generational battle. To demonstrate this point, Scott whipped out an original Nintendo Game Boy and a custom cartridge, which he can use to play fun sounds via the Game Boy’s CPU.

Now You’re Playing With Python

It’s interesting to see the platforms on which Scott has used the power of CircuitPython. The Game Boy brings the hardware for sound and pixel generation along with some logic, but he says it’s the code on the cartridge that does the interesting stuff.

The CPU communicates with carts at a rate of 1MHz. As long as you can keep this rate up and the CPU understands your instructions, you can get it to do anything you want.

Scott’s custom cart has a 120MHz SAMD51. He spends a second explaining how he gets from Python libraries down to the wire that goes to the Game Boy’s brain — basically, the C code underneath CircuitPython accesses direct structs defined within the SAMD to do Direct Memory Access (DMA), which allows for jitter-free communication at 1MHz.

He’s using the chip’s lookup tables to generate a 1MHz signal out of clock, read, and A15 in order to send music-playing instructions to the sound register of the Game Boy’s CPU. It sounds like a lot of work, but CircuitPython helps to smooth over the dirty details, leaving behind a simpler interface.

If you want easy access to hardware no matter how new or nostalgic, the message is clear: snake your way in there with CircuitPython.

Continue reading “Scott Shawcroft Is Programming Game Boys With CircuitPython”