Skip to main content

pyfuturecomposer

A standalone, pure-Python reader and player for Future Composer (MoN / Deenen) C64 SID songs. It parses a Future Composer tune into a typed song model and runs the playroutine to produce byte-exact per-frame SID register output, with an optional WAV render through an emulated SID.

The player is a faithful integer transcription of Future Composer's entry_1806 6502 play routine (the tempo divider, the per-voice DEC-duration row advance, the opcode-stream SEQUENCE + PATTERN walks, and the dense per-frame modulation engine: slide-target vibrato / portamento, the $E0 glide, a 16-bit pulse-width sweep, the filter-cutoff program and the wave / arp tables). It reproduces the preframr-sidtrace register oracle of the reverse-engineering reference tune We R Da Best (tune 2) (Warren Pilbrough / Jade Tiger) byte-exact.

Read/play/register-log is pure stdlib; only WAV rendering needs the optional audio extra (pyresidfp).

pip install pyfuturecomposer          # reader/player/reglog
pip install pyfuturecomposer[audio]   # + WAV rendering via pyresidfp

Quick start

import pyfuturecomposer as fc

song = fc.read("tune.sid")            # PSID/.sid or bare .prg

# Per-frame SID register writes (the writes the playroutine emits each frame).
for writes in fc.iter_frames(song, max_frames=50 * 60):
    ...                               # writes: list[(register, value)]

# Forward-filled 25-register-per-frame snapshot grid (the oracle form).
grid = fc.render_grid(song, nframes=400)

# Register log (clock reg val triples), and WAV via an emulated SID.
fc.write_reglog(fc.iter_register_writes(song, max_frames=2500), "tune.reglog")
fc.render_wav(song, "tune.wav", seconds=30)   # needs the audio extra

Command line

pyfuturecomposer info   tune.sid
pyfuturecomposer reglog tune.sid tune.reglog --seconds 30
pyfuturecomposer wav    tune.sid tune.wav --seconds 30 --model 8580

Register-surface convention

iter_register_writes(song, max_frames=..) -> (clock, reg, val) is the shared py* register-log surface (matching pymusicassembler / pygoattracker), so the output cross-validates byte-exact against the deplayroutine generic interpreter and the preframr-sidtrace oracle.

Tests

Test tunes are HVSC copyright works and are never committed; they are fetched on demand into a gitignored cache (scripts/fetch_tunes.py), and the byte-exact player test validates against a committed frozen oracle grid when the preframr-sidtrace binary ($SIDTRACE_BIN) is unavailable.

./run_tests.sh          # black + pylint + pytest with coverage

License

Apache-2.0. See LICENSE.

Metadata

Release files for pyfuturecomposer 0.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for pyfuturecomposer 0.1.0
File Size Uploaded
pyfuturecomposer-0.1.0.tar.gz 30.9 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for pyfuturecomposer 0.1.0
File Interpreter ABI Platform
pyfuturecomposer-0.1.0-py3-none-any.whl Python 3 none any Details

Total release size: 57.4 kB

Release files / pyfuturecomposer-0.1.0.tar.gz

Download URL pyfuturecomposer-0.1.0.tar.gz
Size 30.9 kB
Tags Source
SHA-256 checksum
How to use checksums
b3f4c085d07536bacc5ca32b3e6ffac763cb52248f3b7169230966f93964d323
BLAKE2b-256 checksum
How to use checksums
3a2921b1b90ecd5d83f0ff3e9abcbce78da579cedabf072e70bee522c8890163
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.12

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Jun 26, 2026.

Transparency log

Release files / pyfuturecomposer-0.1.0-py3-none-any.whl

Download URL pyfuturecomposer-0.1.0-py3-none-any.whl
Size 26.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
3ac24fb91d9c2a72d8b4b77801a7566749dc70d8522808bfa159e624ef0ab10f
BLAKE2b-256 checksum
How to use checksums
e779fe0aae2203ddd18af5149dcf3d6f29f26baa864add047fa987080ac4227f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.12

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Jun 26, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page