Retro games on the Raspberry Pi

Gamer’s Paradise

© Lead Image © Leo Lintang, 123RF.com

© Lead Image © Leo Lintang, 123RF.com

Author(s):

With the right software, you can turn the Raspberry Pi into a versatile console for retro games.

If you are a gaming console enthusiast, the Raspberry Pi is a powerful accessory for your hobby. In addition to recalboxOS and RetroPie, Lakka is now climbing into the ring on this small-board computer and bringing old console games to life.

If you are of a certain age, you might remember the entertaining games from the 80s with simple block graphics, an equally simple plot, and background noise that usually consisted of a few notes. These technically and visually simple games have recently become popular again, and you don't have to invest in consoles or online games: A cheaper and more flexible Raspberry Pi is more fun, and you can play on your TV set, just like the old days.

The retro gaming platform Lakka [1], a LibreELEC derivative with the RetroArch desktop, a Rasp Pi, and a TV or monitor can mutate into several gaming consoles thanks to a wide variety of emulation options.

You don't even have to own a Rasp Pi 3 (RPi3). An older model works, too, with restrictions. A hardware guide [2] shows which game emulators are compatible with which edition of the Rasp Pi. Lakka's programmers have done their homework: The LibreELEC derivative does not require any laborious manual configuration or connection to a modern TFT display: Even an old tube TV is enough.

Setting Up Lakka

After downloading the approximately 300MB Lakka image from the project page [3] and unpacking it, transfer the image file to the microSD card with the command:

$ dd if=Lakka-RPi2.arm-<Version>.img of=/dev/sd<X> bs=1M

Replace <Version> with the version number of your downloaded image and the <X> in the device name of the target with the correct device name. Some distributions also address the card as /dev/mmcblk0; if so, then specify this block device as the destination. Partition names like sdb1 do not work here.

After restarting the Rasp Pi, the dashboard appears with RetroArch's main menu; navigate through it with the arrow keys. Press Esc to return to the main menu from submenus. Early on, you should check Internet access. If you are using an older Rasp Pi model, you can connect via Ethernet. With the RPi3, Lakka detects the wireless module and offers the corresponding configuration in the Settings menu (Figure 1).

Figure 1: The wireless RPi3 module instantly recognizes Lakka and offers the corresponding options.

The Settings menu can be accessed by activating the gearwheel symbol in the dashboard and then selecting the WiFi option. In the Information | Network Information submenu, the current IP address appears next to the local host IP address if a network connection is available.

The developers are constantly improving Lakka, so the next step is to update the system by going to Online Updater | Update Lakka and following the onscreen instructions.

Customizing

The customization options for the system are in the Settings menu. To change the menu hierarchy to a different language, choose the User submenu. Use the arrow keys to change to the Language point and select the desired language. Clicking Esc takes you back to the Settings menu and saves your changes.

To enable the mouse, choose Settings | Menu. First slide the switch for the Show Advanced Settings option to On, and then move the slider beside the Mouse Support option to On.

The somewhat confusing menu structure in Lakka often requires a look at the documentation [4]. The software is still under development, so some settings seem to be provisional – in particular, settings for graphics options, such as shadow and transparency. In the test, for example, changing the menu design led to switches for individual menu groups, some of which were not operational – making the system virtually unusable.

Although you might need to adjust the video and audio settings in some games, the Driver submenu lets you modify the loaded kernel modules, which might be necessary if emulators do not emit sound, for example. Alternative Linux modules are available in the system. Use the arrow keys to adjust the settings; the system accepts the changes immediately (Figure 2).

Figure 2: The console emulator settings are made in a separate intuitive menu.

If you prefer to work on the command line, you can also customize Lakka by editing the /storage/.config/retroarch/retroarch.cfg file. When editing manually, note that you need to deactivate RetroArch with the

systemctl stop retroarch

command before starting to work. After completing the configuration, restart the service with the

systemctl start retroarch

command.

Control

In the 1980s, game consoles were primarily controlled by joysticks and, later, multifunctional controllers. To recreate this retro gaming experience, the software supports various controllers; according to the website [5], they can be partially addressed over Bluetooth.

In these tests, I used a Sony DualShock 4 controller that usually can be operated over Bluetooth or wired over the USB bus. However, it was not possible to connect the controller to the RPi3 via Bluetooth. Even a test with the model 2 and an external USB Bluetooth dongle by Asus, which is otherwise easily supported by Linux, failed to solve the problem. Therefore the controller could only be used over USB. Lakka automatically detected and initialized the device when connecting the cable.

Controllers have different control elements, so you should check which buttons trigger which functions. Also, some old DOS games developed for traditional PCs did not support joysticks or controllers and were controlled by the keyboard.

Play with Me!

After all the preparatory work has been completed, you can integrate the desired games, known as ROMs, into the system by transferring them to the roms/ directory of the SD card. (Please see the "Gray Area" box.) If you emulate several different gaming consoles, you should create a separate subdirectory for each console to store the ZIP archives or ISO images.

Gray Area

From a legal point of view, the use of emulators and ROMs on computer systems proves to be problematic. If the emulator contains code from the original console, it may violate copyright laws, so downloading and using it may be illegal. However, many manufacturers release their software for old consoles that are no longer manufactured. Therefore, it is recommended only to buy emulators from reputable websites.

Game ROMs are also subject to copyright. For example, some manufacturers, such as Nintendo, explicitly point out on their websites that free downloading of ROMs is prohibited [6]. However, many games have not been available on the normal gaming market for many years, and often the rights owners no longer exist or have been taken over by other companies.

To activate the desired console, select the Load Core option from the main menu. In addition to hardware emulators for pure consoles, you will find DOSBox for emulating a DOS system. Next, load the desired game by choosing Load Content | Start Directory | Load Archive.

The menu disappears and the game screen appears. Use the controller to navigate through the game. Lakka automatically saves scores and configurations, allowing you to resume interrupted games from the History menu at your old score (Figure 3).

Figure 3: The History menu allows you to reload scores after a break.

Lakka also makes it possible to retrieve ROMs from the network by clicking Netplay in the main menu. In a clear-cut dialog, you can define whether to use the Rasp Pi as a host or a client.

Conclusions

Lakka on the Raspberry Pi offers hours of gaming fun without tying the user to a specific console model. The game pace was positive in the test on the RPi3.

However, some DOS games ran so fast they could not be played in DOS emulation. In other games, the player immediately lost track of the game in quickly changing complex scenarios. You shouldn't use very old games on high-resolution monitors, because scaling the content creates ugly block effects.

Lakka offers many configuration options, decent hardware support, and easy-to-use menus. The few weaknesses still to be found under the hood are probably a result of the rapid on-going development of the software and are likely to disappear in future releases.