Mesen
Mesen emulates Nintendo NES and Nintendo Famicom Disk System. It reads 3 files, 1 of them required: without a required file it does not start games. A required file is needed only by the machines that use it. Each file below cites the line of source code that reads it.
About this profile
Install this emulator's files
The installer finds your setup and its BIOS folder, then downloads only the files this emulator reads there and checks each one.
Open the Start menu. Type PowerShell and open it. Paste the line. Press Enter.
&([scriptblock]::Create((irm https://abdess.github.io/retrobios/i.ps1))) --emulator mesenOpen Terminal, in Applications, then Utilities. Paste the line. Press Return.
curl -fsSL https://abdess.github.io/retrobios/i | sh -s -- --emulator mesenOpen a terminal. Paste the line. Press Enter.
curl -fsSL https://abdess.github.io/retrobios/i | sh -s -- --emulator mesenSwitch to Desktop Mode. Open Konsole. Paste with Ctrl+Shift+V. Press Enter.
curl -fsSL https://abdess.github.io/retrobios/i | sh -s -- --emulator mesenInstall Termux, a terminal app. Run pkg install python and termux-setup-storage once. Then paste the line. Press Enter.
curl -fsSL https://abdess.github.io/retrobios/i | sh -s -- --emulator mesenOpen a terminal on the device. Or connect from a computer with SSH, a terminal over the network. Paste the line. Press Enter.
curl -fsSL https://abdess.github.io/retrobios/i | sh -s -- --emulator mesenTechnical notes
Mesen is a cycle-accurate NES/Famicom emulator by Sour (the original NES-only version, archived in 2020 in favor of Mesen2). NES cartridge games need no BIOS. Famicom Disk System games require the FDS BIOS ROM.
The core tries FdsBios.bin first, then disksys.rom as fallback. Both are loaded from the system directory root. If neither is found or the file is not exactly 8192 bytes, FDS games fail to load (BiosMissing).
The Study Box is a Famicom tape-based learning peripheral (mapper 186). Its BIOS (StudyBox.bin, 256 KB) is loaded the same way. Only needed for Study Box tape dumps (.stbx format).
MesenDB.txt (game database) is baked into the libretro binary as MesenDB.inc and loaded in retro_init(). The external file path in InitDatabase() is never reached in the libretro context.
MesenPalette.pal is an optional custom palette file, loaded only when the mesen_palette core option is set to Custom. Accepts 192 bytes (64 colors) or 1536 bytes (512 colors with emphasis combos).
HdPacks go in system/HdPacks/<rom_name>/ -- per-game content, not system BIOS.
File path construction: retro_load_game() sets FolderUtilities::SetHomeFolder(systemFolder). All BIOS lookups use CombinePath(GetHomeFolder(), filename) -- flat, no subdirectories.
No functional divergence between upstream and libretro for BIOS loading.
3 files: 1 required, 2 optional.
In this collection: 3 in repo and 0 missing.
Required
Section titled “Required”disksys.rom required for Nintendo Famicom Disk System in repo
FDS BIOS ROM
- System: Nintendo Famicom Disk System
- Aliases:
FdsBios.bin - Mapped at 0xE000-0xFFFF as PRG ROM bank 0. Core checks FdsBios.bin first, falls back to disksys.rom. Size must be exactly 8192 bytes or BiosMissing is set.
- Size: 8.0 KB
- Collection copy:
bios/Arcade/FBNeo/fdsbios.nes - Platforms:
disksys.rom: Batocera, EmuDeck, KNULLI, Lakka, RetroArch, RetroBat, RetroPie.bios/disksys.rom: AmberELEC, EmuELEC, RetroDECK.fds/disksys.rom: Recalbox, RomM.FDS_disksys-nintendo.rom: BizHawk.NES/boot0.rom: MiSTer FPGA
Validation and source
- Validation: size
- Asked for by: emulator code, libretro port
- Source:
Core/FdsLoader.cpp:45-59(emulator code, libretro port),Core/FdsLoader.cpp:143-146(emulator code, libretro port)
Optional
Section titled “Optional”StudyBox.bin optional in repo
Famicom Study Box BIOS ROM
- System: Nintendo NES
- 256 KB BIOS for the Study Box tape peripheral (mapper 186). Only needed for .stbx tape dumps. Size must be exactly 262144 bytes.
- Size: 256.0 KB
- Collection copy:
bios/Nintendo/NES/StudyBox.bin
Validation and source
- Validation: size
- Asked for by: emulator code, libretro port
- Source:
Core/(emulator code, libretro port),StudyBoxLoader.cpp:125-133 Core/(emulator code, libretro port)StudyBoxLoader.cpp:149-152
MesenPalette.pal optional in repo
External NES color palette
- System: Nintendo NES
- Accepts 192 bytes (64 RGB triplets) or 1536 bytes (512 emphasis combos). Falls back to built-in default if size doesn't match.
- Size: min 192 B, max 1.5 KB
- Collection copy:
bios/Nintendo/ NES/ MesenPalette.pal
Validation and source
- Validation: size
- Asked for by: libretro glue
- Source:
Libretro/libretro.cpp:301-323(libretro glue),Libretro/libretro.cpp:405-406(libretro glue)
Next steps
Section titled “Next steps”- Get your files, for the setup you play on
- Every system, and the files each one needs
- When a game does not start