ZXtranSAM

This is a ZX Spectrum to SAM Coupé BASIC translator and variable importer.

šŸ’¾ tranSAM.mgt (bootable, includes SAMDOS2)

Use it to convert ZX BASIC (MGT type 01) files—i.e. those saved to disk using PlusD or DiSCIPLE—to SAM BASIC, *including* any variables saved along with the program.

The translation is based on BTRANS from the MGT Utility Tape (also included on the SAMDOS system disk).

ZX Spectrum BASIC variable parsing is based on Variables List by Neil R. Canham.

šŸ“ Source code on GitHub.


1.1 Added simple PLAY/SPECTRUM token support.

1.2 Fix SAM memory paging (allow larger programs with more variables).

1.3 Reclaim memory used by Spectrum variables once they've been imported.

1.4 Restored tape loading routines from BTRANS.


SAM screenshot: robot illustration
…Trans Am, geddit?
SAM screenshot: text describing the import process
BASIC variables importing
SAM screenshot: some more text describing the results
SAM BASIC memory pointers and numeric variables
SAM screenshot: a BASIC code listing
Speccy BASIC translated to SAM and LISTed out (also using the Spectrum font).