'LinuxMD,' which runs Linux on an actual Sega Genesis (Mega Drive) console, has been released.



LinuxMD is an experimental project that aims to run Linux on

the Mega Drive , a home video game console released by Sega in 1988. Developer Daniel Palmer has made it publicly available on GitHub, allowing users to boot the kernel and a minimal Linux environment on the actual hardware.

GitHub - LinuxMD/linuxmd: Linux for the Sega MegaDrive · GitHub
https://github.com/LinuxMD/linuxmd

To run LinuxMD, you will need a Mega Drive console, a ' Mega EverDrive ' flash memory cartridge, and a USB cable to connect the EverDrive to your PC. When booting on the actual hardware, copy the U-Boot binary, compressed Linux kernel, and root file system image to the EverDrive's SD card. On the PC side, connect to the serial console via the USB-connected EverDrive to check the boot log and perform shell operations.



The Mega EverDrive is a cartridge that allows you to play game ROMs by inserting an SD card, and it is characterized by its various functions. In particular, the 'SSF2 mapper' is an important function for running LinuxMD.

A mapper is a mechanism that switches the ROM and RAM areas used by the CPU within a limited address space. Normally, the maximum memory capacity on a cartridge that the Mega Drive can recognize is 4MB, and only a portion of that can be recognized at a time. However, using a mapper, a technique called 'bank switching' makes it possible to use a larger capacity. Since the only Mega Drive software that featured this mapper was 'Super Street Fighter II (SSF2),' which used a large-capacity 40MBit cartridge, the Mega Drive mapper is sometimes called the 'SSF2 mapper.'

LinuxMD loads the kernel and root filesystem assuming 4MB of memory space at boot time, and the actual boot log also recognizes and operates with 4MB of RAM. A normal Mega Drive does not have enough memory to boot Linux, but using the Mega EverDrive's SSF2 mapper allows the Mega Drive to recognize the 4MB of RAM required by LinuxMD. Therefore, Palmer states that running LinuxMD on a regular emulator is difficult because it requires replicating not only the behavior of the Mega Drive but also the behavior of the EverDrive's SSF2 mapper.

According to Palmer, LinuxMD includes a fork of the open-source emulator ' QEMU .' It has been modified to replicate the functionality of the Mega Drive and EverDrive to a certain extent, so it is possible to try LinuxMD using the emulator. However, because the CPU operates much faster than the actual hardware, it doesn't provide the same feel as the real thing.

The boot log looks like this: the Linux kernel starts, mounts a read-only root filesystem, and executes a shell. It also has a console that uses the Sega Genesis' video output, allowing for on-screen scrolling.



Palmer also explained that, at the time of writing, there were still issues with the operating speed. He said that loading and unpacking the kernel takes time, and communication with EverDrive is also slow, making it slow enough to hinder normal use.

in Software,   Game, Posted by log1i_yk