Skip to main content

ZX Spectrum emulation framework

Project description

zx

ZX Spectrum Emulator in Python and C++

Python package CI

Elven

More screenshots

Features

  • Designed to be suitable for research and development purposes such as unattended testing of Spectrum software, timing analysis, etc.
  • Meant to be easy to customize and re-use via Python interfaces.
  • Fast and accurate emulation.
  • Based on the fast and flexible Z80 emulator.

Development status

  • Platforms: Linux and Windows (via SDL2).
  • General status: working pre-alpha.
  • Supported machines: 48K only for now.
  • Display: multi-colour effects, accurate timings.
  • Sound: EAR beeper and tape output supported.
  • Tape: TAP and TZX formats supported as well as conversion to WAV.
  • Snapshots: Z80.
  • Playback recordings: RZX.
  • Joystick: Xbox controllers supported via evdev (Linux only), mapped to cursor keys.

Installation and running

For the latest release:

$ pip install --upgrade setuptools wheel
$ pip install zx

Or directly from the repository for current development version:

$ pip install --upgrade setuptools wheel
$ pip install git+https://github.com/kosarev/zx

Local development setups are also supported:

$ git clone --recursive https://github.com/kosarev/zx
$ cd zx
$ pip install --upgrade setuptools wheel
$ pip install --editable .

Running:

$ zx

Controls

F1 displays help.

F2 is to save snapshot.

F3 is to load snapshot or tape file.

F6 pauses/resumes tape.

F10 quits the emulator.

F11 and double click switch between fullscreen and windowed mode.

PAUSE and mouse click pause/resume emulation or RZX playback.

Any Spectrum key stroke resumes emulation and leaves the RZX playback mode back to the regular emulation mode.

Running snapshots, recordings and tapes

$ zx elven.z80
$ zx exolon.rzx
$ zx https://www.worldofspectrum.org/pub/sinclair/games/e/EricTheFloaters.tzx.zip

Supported formats

Snapshots: .z80.

Tapes: .tap, .tzx, .wav.

Playbacks: .rzx.

Screenshots: .scr.

ZX Basic compiler sources: .zxb.

Archives: .zip.

Converting files

$ zx jack.tzx jack.wav
$ zx eric.tap eric.z80

Dumping files

$ zx dump rick.z80
OrderedDict([('id', 'z80_snapshot'), ('a', 213), ('f', 66), ...

On the dump command, zx parses the specified file (that can be of any supported format) in the form of raw Python data.

Reference papers

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

zx-0.12.0.tar.gz (91.9 kB view details)

Uploaded Source

File details

Details for the file zx-0.12.0.tar.gz.

File metadata

  • Download URL: zx-0.12.0.tar.gz
  • Upload date:
  • Size: 91.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.3

File hashes

Hashes for zx-0.12.0.tar.gz
Algorithm Hash digest
SHA256 ddeb717281b2b70533890cc45e6651bfb76014da33cb756309f8a9355cf10257
MD5 aa4fbd267310b96f8a4fffd31ef6e3d1
BLAKE2b-256 c16e14b70b711e1acf28e60d01078165995a46b2ab7c434fe39d2fd30389cedc

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page