Skip to content

maxpoletaev/nupsx

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

88 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

nuPSX

nuPSX is an experimental PlayStation 1 emulator and debugger written in Zig, built as a learning exercise to explore Zig's capabilities and PSX hardware architecture. Still in early development with no intention of becoming usable by the general public. If you are looking for the emulator to play games, check out DuckStation.

State

Can boot and play a few commercial games (notably Crash Bandicoot and MGS) and homebrew demos. Lots of things are still missing or incomplete. Tested 2D games are mostly fine, 3D games have minor graphical glitches. Sound system is not complete but functional enough to play music and most of sound effects in tested games.

Game Status Note
Battle Arena Toshinden 🟢 Playable
Colin McRae Rally 2.0 🔴 Crashes
Crash Bandicoot 🟢 Playable
Crash Team Racing 🟢 Playable Sound issues (no voice)
Tekken 3 🟠 In game Wrong screen resolution
Earthworm Jim 2 🟢 Playable
Metal Gear Solid 🟢 Playable Cutscene glitches
Mortal Kombat 2 🟢 Playable
Ridge Racer 🟢 Playable
Spyro the Dragon 🟠 In game Sound issues
Tomb Raider 🔴 Crashes

Build & Run

git clone https://github.com/maxpoletaev/nupsx.git
cd nupsx
zig build --release=safe
./zig-out/bin/nupsx --bios SCPH1001.bin

Command Line Options

nuPSX - A PlayStation emulator

Usage: nupsx --bios <path> [options]

Options:
  --bios <path>        Path to BIOS file (required)
  --exe <path>         Path to executable file to run
  --cdrom <path>       Path to CD-ROM image file (.cue)
  --debug              Enable debug user interface
  --disasm             Enable disassembly output
  --breakpoint <addr>  Set a breakpoint at the specified address (hexadecimal)
  -h, --help           Show this help message

Controls

    [ Q ]                    [ O ]
  _/[ E ]\_       ┆┆       _/[ U ]\_
 /         \--------------/         \
|    [W]    |            |    [I]    |
| [A]   [D] |            | [J]   [L] |
|    [S]    | SHFT ENTR⟩ |    [K]    |
|\_________/--------------\_________/|
|       /                    \       |
|      /                      \      |
 \____/                        \____/

  ↑ = W     △ = I     [START]  = Enter
  ← = A     ◻ = J     [SELECT] = R-Shift
  ↓ = S     × = K     [L1] = E  [R1] = U
  → = D     ◯ = L     [L2] = Q  [R2] = O

Dependencies

nuPSX relies on zig-gamedev libraries for graphics, audio and ImGui bindings.

Credits

Special thanks to guys in EmuDev Discord for sharing tons of undocumented knowledge and getting me unstuck countless times.

Readings:

Tests and Demos:

Referenced Projects:

About

Experimental PlayStation 1 emulator

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published