Snes9x for Unix

Introduction

What is Snes9x?

Snes9x is a portable, freeware Super Nintendo Entertainment System (SNES) emulator. It basically allows you to play most games designed for the SNES and Super Famicom Nintendo game systems on your Mac, Linux, Windows and so on. The games include some real gems that were only ever released in Japan.

The original Snes9x project was founded by Gary Henderson and Jerremy Koot as a collaboration of their earlier attempts at SNES emulation (Snes96 and Snes97.) Over the years the project has grown and has collected some of the greatest talent in the emulation community (at least of the SNES variety) some of which have been listed in the credits section, others have helped but have been loss in the course of time.

Why Emulate the SNES?

Well, there are many reasons for this. The main reason is for nostalgic purposes. In this day and age, it's hard to find an SNES and many good games. Plus, many of us over the course of time have lost our beloved consoles (may they R.I.P) but still have our original carts. With no other means to play them, we turn to emulators. Besides this there are many conveniences of doing this on the computer instead of dragging out your old system.

Advantages consist of :

As with all things there are disadvantages though :

Getting Started

Usage:

Use -help option to see available options.

SNES ROM images come in lots of different formats. Snes9x supports zipped ROMs as long as there is only 1 per zip file. Also Snes9x can open gzip and jma compressed files.

Game Color System

By default, Snes9x displays the ROM information when a ROM is first loaded. Depending on the colors used you can tell whether or not a ROM is a good working ROM, or if it's been altered or is corrupted.

When asking for help on the Snes9x forums, please list the color and CRC32 that is displayed. This will help to find out what the problem is.

These colors do NOT signify whether a game will work or not. It is just a means for reference so we can understand what may or may not be a problem. Most often the problem with games that don't work it's because they are corrupt or are a bad dump and should be redumped.

SNES Joypad Emulation

The default key mapping for joypad 1 is as follows:

And the default key mapping for joypad 2 is as follows:

Pausing and Quitting the Game

Don't forget how to pause the game and quit Snes9x.

Requirements

System Requirements

Relatively fast CPU like Pentium 2 or PowerPC G3 300MHz or higher, and 16MB memory or more.
Certain games use added hardware which will require a faster machine. The specs listed above is the minimum to use Snes9x in any playable form. It is recommended that you get a semi-modern machine with a 800MHz CPU if you want good results. A 1GHz CPU is recommended for those that want a near perfect experience.

X Window System with 15, 16, 24 or 32-bit color depth. For maximum emulation speed, have the X server switched to 15 or 16-bit.

Software

You will need access to SNES ROM images otherwise you will have nothing to run! Some home-brewed ROM images can be downloaded from http://www.zophar.com/.
Please note, it is illegal in most countries to have commercial ROM images without also owning the actual SNES ROM cartridges, and even then you may be liable under various EULAs.

Controllers Support

Input Devices

The real SNES has two ports to connect input devices. Usually 1P and 2P SNES joypads are connected but various devices and adopters can be plugged.

Use -port1 and/or -port2 options to specify which input device to be emulated in each port.

Snes9x can emulate those input devices with the keyboard and mouse. The default mapping is as follows:

Peripherals Support

Satellaview

Snes9x partially emulates Satellaview system, so-called BS-X. To play BS games or read BS magazines with the BS-X base cartridge, do the following.

If you launch a BS game for the first time without BS-X.srm, maybe the game doesn't work properly.
To boot up BS games from BS-X town, use -bsxbootup option.

Sufami Turbo

To play Sufami Turbo games, do the following.

Note that the base cartridge can initialize SRAM for only the game in slot A, so you have to set every game in slot A and launch at least once.
If no games are set in the slots, only the base cartridge runs.
If you have a combined ROM image, split it to each games and the base cartridge. NSRT will help you.

Other Multiple Cartridge Games

Use -multi option as follows:

Currently supported: Same Game

Game Saving

Many SNES games take a very long time to complete from start to finish, so they allowed your progress to be saved at the predefined places chosen by the game designers. The game cartridge contains a battery-backed RAM, known as SRAM, and your save data remain in this SRAM until the battery shutoff.

Snes9x has two methods for saving games. One is the same as of the real SNES shown above; emulating SRAM. The SRAM contents are saved into a file (.srm) so you don't need to be worried about the battery shutoff. The other is more convenient way than the real SNES; 'freezing' or 'snapshotting' the game. It means saving the whole game state anywhere you want, beyond the game designers' intent - ideal for saving your game just before a tricky bit!

Using the SRAM File

It's easy enough, just save the game as you do with the real SNES. Snes9x outputs the contents of the emulated SRAM into a file (.srm) when you load a new game or quit Snes9x. This file is automatically loaded the next time you play the game. Files are stored in ~/.snes9x/sram by default.

Freezing and Defrosting the Game State

Snes9x provides 9 slots for freezing the whole of your game state. During the game, press Shift + F1 to F9 to save the state, and just F1 to F9 to load it again later. Files are stored in ~/.snes9x/savestate by default.

Real-Time Clock Emulation

Some games have a battery-backed real-time clock (RTC) in their cartridge to bring a real-time event in the game. Snes9x saves the state of RTC into a file (.rtc), stored in ~/.snes9x/sram by default, and also into a freeze file.
Note that because it's a 'real-time' clock, when these files are loaded, the emulated clock is automatically advanced in reference to your system's time and date.

Fool-Proof System

If you quit the game by error without saving your long-time progress, try to press F10 key and find '.oops' file in the same directory as freeze files. It's a freeze file automatically generated if you don't save anything for a long time.

Cheat Support

Cheat codes allow you to cheat at games. They might give you more lives, infinite health, enable special powers normally only activated when a special item is found, and etc. Three major formats are well-known: Game Genie, Pro-Action Reply (PAR) and Gold Finger. Many existing codes can be found via Internet.

Snes9x supports all the three formats. Cheats are saved in .cht files and are automatically loaded the next time a game with the same filename is loaded.

Technically, a cheat code consists of two elements; an address in SNES memory map where you want to overwrite, and a value which is overwritten on the address.
Beware of cheat codes designed for a ROM from a different region compared to the one you are playing or for a different version of the ROM; the source of the cheats should tell you which region and for which version of the game they were designed for. If you use a code designed for a different region or version of your game, the game might crash or do other weird things because the cheat address might be different between regions and versions.

How to Enter Cheat Code

Use -gamegenie, -actionreplay and -goldfinger options to enter your cheat code. Files are stored in ~/.snes9x/cheat by default.

Movie Support

Movie support allows you to record your actions while playing a game. This can be used for your own personal playback or to show other people that you can do something without them having to be around when you did it.

Recording the Movie

Press Shift + 1 to begin recording and Shift + 2 to stop recording. Also you can use -recordmovie option to record from the start of the game.

Playing Back the Movie

Press Shift + 3 and enter the movie filename (.smv) to play the movie. Also you can use -playmovie option to play the movie recorded from the start of the game.

Miscellaneous

Where the Files are Stored

By default, ~/.snes9x is used to load/save files related to Snes9x. The subdirectories Snes9x refers to are as follows:

Using IPS or UPS Patch

Snes9x automatically patches without overwriting the ROM image.

SPC File Dumping

SPC file (.spc) is the freeze state of only sound part, so it is known as SNES music data file. Dump the SPC file by Snes9x and play the file by SPC players.

Press Alt/Control + F1 to dump a SPC file. It's stored in ~/.snes9x/spc by default.
Note that the actual dumping occurs at the next note-on event so that you can dump the BGM from just the beginning.

Additional Keyboard Controls

Snes9x has various functions to play games with fun. The default mapping is as follows:

Gamepad Support

The Linux port makes use of the v1.x joystick kernel drivers written by Vojtech Pavlik to allow the use of a wide variety of different gamepad types to control SNES games.
If you are still using the older versions of the drivers, you can download the latest driver version from http://atrey.karlin.mff.cuni.cz/~vojtech/joystick/.
Refer to the documentation that comes with the drivers to enable support for your type of gamepad in Snes9x.

Configuring Settings and Key Mapping

The Unix port of Snes9x reads the preferences file snes9x.conf when launching, if it exists.
To make your snes9x.conf, copy the template file snes9x.conf.default, rename it to 'snes9x.conf', put it in the proper directory (~/.snes9x by default), and edit it as you like. The document control-inputs.txt will help you to edit the keyboard/gamepad mapping.

Building Snes9x from Source

The source release of Snes9x comes with a configure file that will try to make a Makefile suitable for your system. To invoke it go into the snes9x/unix directory inside the distribution:

Then run configure and finish with running make if it went well.

configure takes several arguments. Further documentation about this is available by running ./configure --help.

Compatibility

Compatibility with Other Ports

All the files generated by Snes9x are compatible between platforms, except for the extension of the freeze files.

Compatibility with Other SNES Emulators

Cheat files (.cht) are common between Snes9x and ZSNES. RTC files (.rtc) are common between Snes9x and bsnes. SRAM files (.srm) should be common among all SNES emulators.

Problems

Problems with ROMs

If Snes9x just displays a black screen for over 10 seconds after you've loaded a ROM image, then one of the following could be true:

The following ROMs are known to currently not to work with any version of Snes9x:

Problems with Sounds

If you hear crackling noise during the game, try these options to eliminate the noise.

Technical Information

What's Emulated?

What's Not?

Custom Chips

Super FX

The Super FX is a 10.5/21MHz RISC CPU developed by Argonaut Software used as a game enhancer by several game titles. Released SNES Super FX games included Yoshi's Island, Doom, Winter Gold, Dirt Trax FX, StarFox, Stunt Race FX and Vortex.

SA-1

The SA-1 is a fast, custom 65c816 8/16-bit processor, the same as inside the SNES itself, but clocked at 10MHz compared to a maximum of 3.58MHz for the CPU inside the SNES. The SA-1 isn't just a CPU; it also contains some extra circuits developed by Nintendo which includes some very fast RAM, a memory mapper, DMA and, several real-time timers.

C4

The C4 is custom Capcom chip used only in the Megaman X2 and Megaman X3 games. It can scale and rotate images, draw line-vector objects and do some simple maths to rotate them.

S-DD1

The S-DD1 is a custom data decompression chip that can decompress data in real-time as the SNES DMA's data from the ROM to RAM. Only two games use the chip: Star Ocean and Street Fighter Alpha 2.

SPC7110

The SPC7110 is a compression and memory mapping chip. It provides a few extra features as well. It functions as an RTC interface, and has a multiply/divide unit that has more precision than the SNES. The SPC7110 is found only in 4 games: Super Power League 4, Far East of Eden Zero, Far East of Eden Zero - Shounen Jump no Shou and Momotaro Dentetsu Happy.

Others

Other known custom chips: DSP-1, DSP-2, DSP-3, DSP-4, Seta-10, Seta-11, Seta-18, OBC1 and S-RTC.

Credits

Nintendo is a trademark.
Super NES, Super Famicon, Super Scope and Super FX are trademarks of Nintendo.
Sufami Turbo is a trademark of Bandai Co., Ltd.
Game Genie is a trademark of Lewis Galoob Toys, Inc.
Pro Action Replay is a trademark of Datel Inc.
Macintosh, Mac and Mac OS X are trademarks of Apple Computer, Inc.
UNIX is a trademark of The Open Group.
Linux is a trademark of Linus Torvalds.
Windows is a trademark of Microsoft Corp.
Intel is a trademark of Intel Corp.
PowerPC is a trademark of International Business Machines Corp.
Sony is a trademark of Sony Corp.
Konami and Justifier are trademarks of Konami Corp.
Hudson is a trademark of Husdon Soft Co., Ltd.
Capcom is a trademark of Capcom Co., Ltd.

Gary Henderson

Edited for Unix port by: zones (kasumitokoduck@yahoo.com)
Updated most recently by: 2011/04/10 zones