Skip to content
PORTSNATIVE.
HomeCatalog
Web GamesEmulatorsToolsNews
PORTSNATIVE.

A catalog for discovering ports and related projects. We link to official sources and do not host original game files.

ExploreCatalogMy list
InformationAbout usSuggest a portSupportDonationsLegal notice
© 2026 PortsNative
Back to catalog
Super Mario Bros.
PORTSNATIVE

Super Mario Bros.

NATIVE PORTPLATFORMERWINDOWSALPHA

Super Mario Bros.

TechnologyNative C/C++ port (engine reimplementation)

Available forWindows

View official project

About the project

Super Mario Bros. es un videojuego de plataformas desarrollado y publicado por Nintendo para la Nintendo Entertainment System (NES). Dirigido y producido por Shigeru Miyamoto, es la secuela del arcade Mario Bros. de 1983 y el primero de la serie Super Mario. Los jugadores controlan a Mario, o a su hermano Luigi en el modo multijugador, para atravesar el Reino Champiñón y rescatar a la princesa Toadstool del rey Koopa —más tarde llamado Bowser—.

11 versions of Super Mario Bros.

You're viewing: Super Mario Bros.

Super Mario Bros.github.com/pwsqrd/lynx_smb
Windows
Current
SMB Vanillagithub.com/nukep/SMB-Vanilla
Windows
Linux
macOS
›
Super Mario Bros. (nathsou)github.com/nathsou/smb
Windows
›
Super Mario Bros. (oliveryasuna)github.com/oliveryasuna/smb-recomp
Windows
›
Super Mario Bros. (Switch)github.com/sverigeunit/Mario-Bros-Switch-Port
To be confirmed
›
Super Mario Bros. (UEFI_SuperMario)github.com/MikeWuPing/UEFI_SuperMario
Windows
›
Super Mario Bros. Remasteredgithub.com/JHDev2006/Super-Mario-Bros.-Remastered-Public
Windows
Linux
macOS
›
Super Mario Bros. Remastered (Android, mircey)github.com/mircey/super-mario-bros.-remastered-android
Android
›
Super Mario Bros. Remastered (Android)github.com/mircowuffwuff/super-mario-bros.-remastered-android
Android
›
Super Mario Bros. Remastered (Switch)github.com/delsonazevedo/Super-Mario-Bros.-Remastered-Switch
To be confirmed
›
SuperMarioBrosRecompgithub.com/mstan/SuperMarioBrosNESRecomp
Windows
Linux
macOS
›

Official project information

Author's original READMEOpen on GitHub ↗

Super Mario Bros. — Atari Lynx Port

A port of the NES Super Mario Bros. to the Atari Lynx handheld.

Rather than rewriting the game, this project runs the original 6502 game logic (from a complete NES disassembly) on the Lynx's 65C02 and wraps every NES hardware access — graphics, audio, input — in a thin Lynx adapter layer. The NES's tile-based PPU is translated to the Lynx's sprite-based Suzy engine, the NES APU to the Lynx Mikey audio channels, and the NES controller to the Lynx joypad.

All artwork and level data is extracted directly from the original NES ROM during the build. No copyrighted assets are stored in this repository.

Super Mario Bros. running on the Atari Lynx


Windows quickstart

  1. Install Docker Desktop and restart your PC. (Skip this if you already have it.)
  2. Download this repo: click the green Code button at the top of this page → Download ZIP, then extract it (e.g. to C:\temp).
  3. Put your Super Mario Bros. .nes ROM in the rom folder.
  4. Double-click build-windows.bat.
  5. When it says Done!, smb.lnx is next to build-windows.bat. Open it in a Lynx emulator.

The first build takes about 5 minutes; after that it's much quicker.

If Windows shows "Windows protected your PC", click More info → Run anyway. If it says the ROM wasn't found, your ROM is the wrong version — see the ROM table under Build.


How it works

NESLynxTranslation
Tile-based PPU, 256×240Sprite-based Suzy engine, 160×102 @ 4bppTiles → pre-composited metatile sprites, NES→Lynx palette dedup into ≤16 slots
APU, 5 channelsMikey, 4 channelsPer-frame register translation, software envelope emulation
ControllerJoypad + buttonsInput shim
2 KB RAM + separate VRAM64 KB unified RAMNES I/O register equates redirected into RAM
  • lynx_port/smb_lynx.s — the NES disassembly converted to ca65 syntax (~16K lines).
  • lynx_port/lynx_startup.s — Lynx hardware init and the IRQ→NMI bridge that drives the original game loop.
  • lynx_port/lynx_sprites.s — Suzy sprite rendering and NES→Lynx palette translation.
  • lynx_port/lynx_audio.s — NES APU → Mikey audio translation.

The graphics scale factor is NES 8×8 → Lynx 5×5 (160×102 fits a 32-column field exactly).


Prerequisites

  • cc65 — provides ca65, ld65, and sp65, plus the Lynx target library (lynx.lib). Don't use you package manager, compile from source:
    git clone https://github.com/cc65/cc65.git
    # The exact commit this port is tested against (see Dockerfile CC65_COMMIT):
    cd cc65 && git checkout c720c3c4854cf36befbb7d1b19fdb207f7549882
    make -j"$(nproc)" && sudo make install PREFIX=/usr/local
    
  • Python 3 with Pillow — the only third-party Python dependency, used by the asset-extraction scripts. Install it with pip install -r requirements.txt.
  • make and bash.
  • An Atari Lynx emulator to run the result (e.g. GearLynx, Felix, or Handy).

Make sure ca65, ld65, and sp65 are on your PATH. If cc65 is installed somewhere non-standard, override the tool paths:

make CA65=/opt/cc65/bin/ca65 LD65=/opt/cc65/bin/ld65 SP65=/opt/cc65/bin/sp65

Docker Building (easy)

git clone https://github.com/pwsqrd/lynx_smb
cd lynx_smb

# Drop your ROM in rom/ (any filename, matched by checksum)
cp /path/to/your/smb.nes rom/

# Build the image (one-time, ~5 min — compiles cc65 from source)
docker build -t lynx_smb_builder .

# Run the build, get the .lnx out
docker run --rm \
  -v "$PWD/rom:/build/rom" \
  -v "$PWD/out:/build/out" \
  lynx_smb_builder

Build (if you dont like docker)

  1. Supply the NES ROM. This port does not include any game assets — drop your own legally-obtained Super Mario Bros. ROM into the rom/ directory. Any filename works; it is matched by checksum. The required dump is:

    FieldValue
    NameSuper Mario Bros (JU) (PRG 0).nes
    Size40976 bytes
    MD5811b027eaf99c2def7b933c5208636de
    SHA-1ea343f4e445a9050d4b4fbac2c77d0693b1d0922

    (If the ROM is missing or wrong, the build stops and prints exactly what it expects.)

  2. Build:

    make
    

    This verifies the ROM, extracts and converts all assets, assembles the four modules, and links the final ROM to out/smb.lnx (plus .lab/.sym debugger symbol files).

    The default tile size is 5×5 (NES 8×8 tiles downscaled to fit the Lynx's 160×102 screen). This is the standard build and produces out/smb.lnx. The alternate TILE_MODE=5x4 build (see below) is written to out/smb_5x4.lnx instead. 5x4 mode allows for more vertical space and matches the NES version more closely.

  3. Run it in an emulator:

    make run FELIX=/path/to/your/emulator
    # or just point your emulator at out/smb.lnx
    

Useful make targets / options

CommandDescription
makeVerify ROM, build assets + ROM image
make assetsBuild only the extracted assets
make runBuild then launch the emulator (FELIX= to set it)
make cleanRemove object files and the linked ROM
make distcleanAlso remove all extracted/generated assets
make TILE_MODE=5x4Alternate tile scaling (more vertical content, smaller tiles, more draw calls) → out/smb_5x4.lnx
make VSCROLL_MODE=THREE_POSChoose a vertical-scroll behaviour, 5×5 only (see below)

Vertical scroll modes (5×5 only)

The Lynx screen (102 px tall) is far shorter than the NES's (240 px), so the 5×5 build scrolls the camera vertically to keep Mario in frame. How it scrolls is chosen at build time with VSCROLL_MODE=. Three behaviours are available:

VSCROLL_MODEBehaviour
(unset) or PLATFORM_LOCKDefault. Platform-lock: the camera follows Mario down immediately, but only pans up after he has stood still briefly (~0.13 s). Keeps the framing steady and stops the view lurching upward on every jump. Snaps between ground / mid / top positions.
TWO_POSTwo-position snap between a ground camera and a raised camera, with a dead zone and velocity gating to prevent oscillation. Snappier and simpler.
THREE_POSThree-position snap (ground / mid / top) with dead zones — finer vertical framing than TWO_POS.

In every mode the camera eases toward its target (±2 px/frame) and holds still during pipe transitions, level entry, and death; water levels never scroll vertically. The alternate 5×4 build fits more rows on screen and does not scroll vertically, so VSCROLL_MODE has no effect there.

make VSCROLL_MODE=THREE_POS

Repository layout

lynx_port/        Port source (ca65 assembly) + linker config + hardware include
tools/            ROM verification + asset-extraction pipeline (Python / sp65)
rom/              Place your NES ROM here (gitignored)
docs/             Screenshot and other docs
Makefile          Build orchestration

The build/ and out/ directories are created during the build and are gitignored.


Credits & provenance

  • Game: Super Mario Bros. © Nintendo. This project ships no Nintendo assets or code; everything is generated from a ROM you provide.
  • NES disassembly: the game logic is derived from the comprehensive Super Mario Bros. disassembly SMBDIS.ASM by doppelganger (doppelheathen@gmail.com), converted from x816 to ca65 syntax. That original disassembly is not included in this repository; it is widely mirrored online (search for "SMBDIS.ASM doppelganger" / the smbdisassembly project).
  • Toolchain: cc65 (ca65/ld65/sp65 and the Lynx target library).

This is a hobby/educational port. You must own an original copy of the game to build and play it.

View official project
CALIFICACIÓN
—
Loading votes…
Advertisement

PROJECT FILE

Project type
NATIVE PORT
Genre
Platformer
Status
alpha
Original platform
—
Technology
Native C/C++ port (engine reimplementation)
Version
—
Updated
—

Target platforms 1

Windows
View on GitHub
Advertisement