Pew Pew In The Palm Of Your Hand

It’s often said that “getting there is half the fun”, and we think that can be just as true when building hardware as it is during the roadtrip to your favorite hacker con. Many of us enjoy the process of planning, designing, and building a new gadget as much as playing with it when it’s done. We get the impression [Radomir Dopieralski] feels the same way, as he’s currently working on yet another iteration of his PewPew project.

For the uninitiated, [Radomir] has already created a number of devices in the PewPew line, which are designed to make programming games on “bare metal” easier and more approachable for newcomers by using CircuitPython.

The original version was a shield for the Adafruit Feather, which eventually evolved into a standalone device. The latest version, called the M4, includes many niceties such as a large TFT screen and an acrylic enclosure. It’s also switched over to the iconic Game Boy layout, to really drive home that classic gaming feel.

As [Radomir] explains, previous versions of the PewPew were designed to be as cheap and easy to manufacture as possible, since they were to be used in game programming workshops. But outside of that environment, they left a little something to be desired. With the M4, he’s created something that’s much closer to a traditional game system. In that respect it’s a bit like the Arduboy: you can still use it to learn game development, but it’s also appealing enough that you might just play other people’s games on it instead.

That Game Cartridge Isn’t As Straightforward As You’d Think

Classic games consoles played their games from cartridges, plastic bricks that held a PCB with the game code on it ready to be run by the console hardware. You might therefore expect them to be an easy prospect for emulation, given that the code can be extracted from whatever ROM they contain. But as anyone with an interest in the subject will tell you, some cartridges included extra hardware to boost the capabilities of their games, and this makes the job of an emulator significantly more complex.

[Byuu] has penned an article exploring this topic across a variety of consoles, with in-depth analyses of special-case cartridges. We see the obvious examples such as the DSP coprocessors famously used on some SNES games, as well as Nintendo’s Super Game Boy that contained an entire Game Boy on a chip.

But perhaps more interesting are the edge-case cartridges which didn’t contain special hardware. Capcom’s Rockman X had a copy protection feature that sabotaged the game if it detected RAM at a frequently used save game address emulated by copiers. Unfortunately this could also be triggered accidentally, so every one of the first generation Rockman X cartridges had a manually attached bodge wire that a faithful emulator must replicate. There is also the case of the Sega Genesis F22 Interceptor, which contained an 8-bit ROM where most cartridges for this 68000-powered platform had a 16-bit part. Simple attempts to copy this cartridge result in the upper 8 bits having random values due to the floating data lines, which yet again an emulator must handle correctly.

It’s a subject with a variety as huge as the number of console developers and their games, and a field in which new quirks are constantly being unearthed. While most of us don’t spend our time peering into dusty cartridges, we’re grateful for this insight into that world.

We’ve visited the world of emulators a few times before, such as when we looked at combatting in-game lag.

Upping The Story-Telling Game With Dialog And The Å-Machine

During the decades since Infocom released their interactive story game Zork to world-wide acclaim for microcomputers, the genre of interactive fiction (IF) is still immensely popular, with a surprising number of modern IF works targeting Infocom’s original Z-Machine runtime for 8-bit micocomputers. We’ve seen a number of improved runtimes and languages for the platform over the years, with [Linus Åkesson]’s Dialog language a newcomer.

Covering the technical details about the language in this thread at IntFiction, the interesting aspect about this language is that while it has a compiler that compiles it to Z-code for the Z-Machine, [Linus] has also implemented a new runtime, called the ‘Å-Machine‘, since ‘Å’ follows ‘Z’ in the alphabet (if you’re Swedish, that is). This runtime should allow for larger stories and other features that make better use of more resources, while still allowing smaller stories to work on old hardware. Unfortunately the only Å-Machine implementation at this point is written in JavaScript, which is not known to work particularly well on Commodore 64 or even Amiga 500 systems.

As for Dialog itself, its documentation provides a detailed overview of the language’s capabilities, which claims to be inspired by both Inform 7 and Prolog. Its goals are to be easy to follow, with a minimal number of language concepts, and high performance. As the documentation notes, many Z-Machine based stories exist today that are unplayable on vintage hardware due to lack of optimization.

We covered Zork and the Z-Machine a while ago in some detail. We think it’s great to see that there’s still so much interest in the platform. Maybe someone will write an Å-Machine implementation for a Commodore or MSX system one of these days to see how it compares to Infocom’s Z-Machine. Here’s to another few decades of the Zork-legacy.

Steel Battalion Controller Grows Up And Gets A Job

We’re going to go out on a limb here and say that the controller for Steel Battalion on the original Xbox is the most impressive video game peripheral ever made. Designed to make players feel like they were really in the cockpit of a “Vertical Tank”, the controller features dual control sticks, three pedals, a gear selector, and dozens of buttons, switches, and knobs. Unfortunately, outside of playing Steel Battalion and its sequel, there’s not a whole lot you can do with the monstrous control deck.

HID Report Descriptor

But now, nearly 20 years after the game released, [Oscar Sebio Cajaraville] has not only developed an open source driver that will allow you to use the infamous mech controller on a modern Windows machine, but he’s part of the team developing a new game that can actually be played with it. Though gamers who are imagining piloting a futuristic combat robot in glorious 4K might be somewhat disappointed to find that this time around, the Steel Battalion controller is being used to operate a piece of construction equipment.

In his blog post, [Oscar] focuses on what it took to develop a modern Windows driver for a decades old controller. It helps that the original Xbox used what was essentially just a rewiring of USB 1.0 for its controllers, so connecting it up didn’t require any special hardware. Unfortunately, while the controller used USB to communicate with the console, it was not USB-HID compliant.

As it turns out, Microsoft actually provides an open source example driver that’s specifically designed to adapt non-HID USB devices into a proper game controller the system will recognize. This gave [Oscar] a perfect starting point, but he still needed to explore the controller’s endpoints and decode the data it was sending over the wire. This involved creating a HID Report Descriptor for the controller, a neat trick to file away mentally if you’ve ever got to talk to an oddball USB device.

In the end, [Oscar] created a driver that allows players to use the Steel Battalion controller in his game, BH Trials. Unfortunately there’s something of a catch, as drivers need to be signed by a trusted certification authority before Windows 10 will install them. As he can’t quite justify the expense of this step, he’s written a second post that details what’s required to turn driver signing off so you can get the device working.

Earlier this year we saw an incredible simulator built around the Steel Battalion controller, were an external “coach” could watch you play and give you tips on surviving the virtual battlefield. But even that project still used the original game; hopefully an open source driver that will get this peripheral working on Microsoft’s latest OS will help spur the development of even more impressive hacks.

Continue reading “Steel Battalion Controller Grows Up And Gets A Job”

Null Shard Build Blurs Line Between Game And Reality With Laser Cutting, Mold Making, 3D Printing

In The Room Three, players are tasked with collecting mysterious objects known as “Null Shards”. But it seems one player, who goes by the name [Juiceman], took this challenge a bit literally. Starting with promotional art released for the game, he embarked on an epic journey to create a replica “Null Shard” that ended up looking so good that one of them is currently residing in a place of honor at the headquarters of developer Fireproof Games.

The developers had previously released image files to create a papercraft version of the Null Shard on their website, so [Juiceman] based his initial CAD work on these designs. But it turned out the surface texture was a little too complex to laser etch into acrylic without making a soupy mess. He simplified it a bit, while trying to retain the overall effect. From the superb laser-etched acrylic master he made a silicone mold started casting the eight triangular panels needed for two copies of the Shard.

To hold it all together [Juiceman] create a “skeleton” pyramid by first experimenting with designs on a traditional plastic FDM printer. After a few tries he had a workable design and switched over to a laser sintering machine, giving the final frame a gorgeous texture. With the cast panels installed and a few coats of paint, he had his Null Shards.

The final step was to turn down a piece of ash to make a nice base, and 3D print the feet and “claw” mount for the Shard using the same laser sintering process. The finished product looks fantastic, and apparently lives on a shelf next to a similarly constructed replica of the “Lament Configuration” puzzle cube from the Hellraiser films. [Juiceman] says the two replicas are the first entries into his “Geometries of Hell” collection, which incidentally, we’ve decided will officially be the name of our first metal album. All we need to do now is learn how to play instruments.

We’ve previously looked at how 3D printing and a dash of dedication can create some incredible prop builds, and once upon a time, we even ran a Sci-Fi Contest that challenged our readers to bring their favorite movie and game objects into the real world. Builds like this are a perfect example of what happens when a dedicated hacker or maker gets inspired by a piece of entertainment that really resonates with them.

[Thanks to Lauren for the tip]

DIY 40FPS 16bpp Platformer On A Cortex M0+

Sure, you can play a bunch of retro games on a Raspberry Pi, but if you’re really hardcore, you build your own retro console and write your own games for it. [Nicola Wrachien]’s entry into this year’s Hackaday prize is his DIY Cortex M0+ game console and the platform game he wrote to test the hardware.

The board that [Nicola] is using is the uChip, a small DIP board based around a ATSAMD21 (the same chip that runs the Arduino Zero). That, along with a 160×128 TFT LCD screen, makes up the bulk of the hardware. A carrier board holds both of these as well as several buttons and an OpAmp.

The ATSAMD21 chip has decent hardware DMA that [Nicola] is using to get the frame rate needed. Since the DMA hardware and the CPU can work at the same time, while the DMA is handling one chunk of graphics, the CPU is working on the next chunk. Using this system, [Nicola] is able to get a better framerate than originally designed. Take a look at [Nicola]’s webpage for more details on the algorithm used.

In order to create a level in the platformer that [Nicola] made to show off the console, [Nicola] created a full blown level editor in Java. Using the editor, you can place the tiles and sprites and set their behaviours. The map can then be exported in an optimized format for loading on to the hardware and into the game.

A video showing off the game is after the break. There’s no shortage of great DIY consoles on the site — check out this impressive vector console, or if RetroPie is more your thing, take a look at this DIY Zelda-playing device.

Continue reading “DIY 40FPS 16bpp Platformer On A Cortex M0+”

Running Doom On A Doomed GPS

What’s the first thing you think of when you see an old GPS navigation system for sale cheap at a garage sale? Our research indicates that 100% of people would wonder if it could run Doom; at least that’s what we conclude from the single data point we have, anyway. [Jason Gin] asked and answered the question — with a resounding yes — about his recent acquisition.

The unit in question is a Magellan RoadMate 1412 running Windows CE. After some playing, [Jason] found that simply connecting the unit to a computer via USB caused all the application files to appear as a FAT-formatted volume. Replacing the obviously-named “MapNavigator.exe” with a copy of TotalCommander/CE allowed browsing around the filesystem.

This revealed that much was missing from the CE install, including the Explorer shell and command prompt. Either could be used to launch Doom with the required command-line arguments. Luckily, [Jason] had another trick ready, namely using MortScript (a scripting engine) to launch the Doom executable. This worked like a charm, and after a few tweaks, he now has a dedicated demo box.

We say “demo box” instead of “Doom machine” because without a keyboard, you can’t actually play the game — only view the demo. In a valiant attempt, he connected a USB OTG connector, but the GPS doesn’t seem to recognize input devices, only USB storage devices. Keep at it, [Jason], we’d love to see you crack this one!

[Jason] is no stranger to hacking Windows CE devices. Last time we checked in, the target was a KeySight DSO1102G oscilloscope.

Continue reading “Running Doom On A Doomed GPS”