Tech

A Fresh Game Breathes Life Into Nintendo’s Tiniest Handheld, the Pokemon Mini

Published

on


Nintendo took a chance in 2001 with the Pokemon Mini, the world’s smallest cartridge-based platform to date. This teeny-tiny device was smaller than a matchbox and only held ten official games before fading into obscurity. Game makers had to get creative with the tiny 160×100 monochrome LCD screen driven by an Epson S1C88 CPU running at 4.194304 MHz, resulting in charming, simplified Pokémon adventures. Four AAA batteries kept the fun going for about 20 hours before needing a recharge, with cartridges containing a maximum of 2 MB of ROM, but the hardware was so constrained that game programmers had to get somewhat creative with the design.



Homebrew enthusiasts recognized the potential for restoring this historical relic. They began developing emulators, assemblers, and even flash carts after gathering a plethora of information through reverse engineering and community tools. Websites like pokemon-mini.net have become troves of downloads, ranging from full games and demonstrations to development kits. Programmers working on the Mini often utilize C or assembly language using the open-source c88-pokemini toolchain on GitHub, or they can obtain a genuine Epson SDK from the past, which includes a minimal simulator for testing code.

Inkbox entered the fray with Pokémon Ambulation, their version on Frogger’s iconic ‘river-crossing hurdle. The game allows you to choose from eight different Pokémon; whether you want to speed across as lightning-quick Pikachu or plod along as lumbering Snorlax, you must guide them through a succession of scrolling lanes laden with hazards. There are automobiles zipping along horizontally, logs sliding across the water, and gators snapping shut in irritation. Collision means you have to start over, but reaching the far bank earns you points and advances you to the next level.


Assembly code is crucial to the S1C88 core’s operation. Inkbox began as a fairly simple application to get the system up and running and manage interrupts. When it came to visuals, they used 4-bit grayscale tiles, which means they had 256 possible shades to work with to cover the 20×16 screen grid. Backgrounds scroll quite smoothly thanks to some smart fiddling with hardware registers, and sprites, such as the Pokémon itself, can be superimposed on top of backdrops to make them appear more believable. A basic tone generator generates sound effects, such as beeps to indicate that you’ve leaped and a crash to indicate that you’ve failed, all of which are synced to the frame rate.


Getting down to the nitty-gritty of constructing the tiles for their game required precision. Inkbox developed an online editor, which is still hosted at notin.tokyo/pminiTiles, that allows you to draw and then export your creations directly into the game. The LCD panel doesn’t have many shades to play with, so it takes some smart pixel-dithering to make it appear that there are more than just the 16 or so shades available. Every frame is scanned for collision detection, which occurs at a staggering 60 frames per second. Input comes from the usual suspects, four buttons and a D-pad, but to avoid jitters, the code debounces the buttons.


Instead of running large amounts of code on an emulator, testing was done directly on hardware. Emulators such as PokeMini can help ensure that the code works, but timing and LCD refresh issues imply that the thing must still be run on actual hardware. Inkbox effectively inserted an RP2040 microcontroller into a bespoke cartridge shell, which was configured to simulate ROM via SPI flash and was connected to the Mini’s bus like an actual game cartridge. When you turn it on, the Nintendo logo appears on the screen, Ambulation loaded, and the game begins; the buttons click with a pleasing ‘click’, and the screen glows low-key in the dark.
[Source]

Source link

Advertisement

Leave a Reply

Your email address will not be published. Required fields are marked *

Trending

Exit mobile version