SamPlay
Author
Description
http://www.keprt.cz/sam/saa/index.php
This is a standalone player for SAA1099 music, released initially in 1998. It consists of a Z80 emulator and SAA1099 soundchip emulator (SAAEmu) , itself powered by SAASound. SamPlay is capable of running on Windows or DOS systems.
Last updated 29/8/2026.
Trivia
0.90 - 29.8.2026
====
Versions 0.72 to 0.89 were never released, so everything listed here happened since 0.71.
Sound
* CMS driver: the Game Blaster clocks its SAA1099 at 7.16 MHz, while the Sam Coupe runs
the chip at 8 MHz. SAAemu now recalculates every frequency it sends to the card, so
tunes finally play in the right pitch. The noise generators use dividers which are
fixed in the hardware and cannot be corrected this way, so the noise still comes out
about two semitones too low.
* CMS driver: the default port is now 220h. The old default of 380h was of no use to anybody.
* Upgraded Dave Hooper's SAASound library from version 3.01 (2001) to 3.4 (2020). It brings
years of accuracy work on the envelope generators, on the amplitude levels and on the
sync behaviour of the frequency and noise generators.
* Sound card selection rewritten. What you write in SAAemu.ini now always wins; the BLASTER
and ULTRASND environment variables are used only to fill in what you left out.
* The SoundBlaster mixer is detected properly at last, both the SB16 one and the older
SB Pro one. The OPL2 driver no longer pretends to have a mixer - the cards which had
nothing but an OPL2 chip had no mixer either.
* Selecting the OPL2 driver no longer reports OPL3 on the screen.
Playback
* Fixed the emulation of memory paging through the LMPR port, which used to be a rough
approximation. ProTracker tunes, which page themselves, depend on it.
* Fixed long standing bugs in channel muting.
* Fixed benign bugs in the ETracker and Craft players.
* Fuxoft tunes are now checked against the size of the data they carry, not against the
size of the file, so they are recognized correctly inside AST files.
* Loading another tune into a running program resets everything properly.
* Protection against runaway tunes: the number of Z80 instructions executed per tick is
limited, so a broken player can no longer hang the whole program.
User interface
* Started without a parameter, SamPlay opens a file dialog instead of just printing the
usage. You can also open another file at any time with the O key.
* Channel volumes are drawn as bars, and the left and right channel are shown separately.
* The keyboard is read directly from console events. The arrow keys used to freeze the
program on Windows 98; they don't anymore.
* Number keys are read by their position on the keyboard, so selecting a track works on
national keyboard layouts as well.
* The console window is no longer shrunk to a stamp when the program starts.
* Warnings about memory access, runaway CPU and invalid files are printed on the last
screen line and no longer overwrite anything else.
* Console output is buffered, which makes the screen refresh a great deal faster.
Robustness and diagnostics
* The program keeps running when a tune fails to load or when no sound card is found.
It stays silent and waits for you to open another file.
* New -trace switch. It simulates the tune without playing anything and lists every
invalid memory access it finds. It replaces the old MEMWATCH build.
* A log file is written into the AppData directory. It cannot live next to the program,
because a program installed in Program Files is not allowed to write there.
Internals
* Ported to current Visual Studio while keeping the Visual C++ 2005 build working, because
that is the last compiler which can still target Windows 98.
* Tested on real hardware under Windows 98, which uncovered a number of bugs.
* Screen handling moved into a separate View class, source files renamed, and the safe
CRT functions used throughout.
0.71
====
* I started to write this change log.
* A message box is displayed upon error. Formerly it was only displayed in console window.
* A message box describing command line parameters is displayed if SamPlay is started without parameters.
* Directory "audio" removed. Configuration file SAAemu.ini is now in base direcotry.
File "etracker.bin" is not needed anymore, its contents are compiled directly into SamPlay.
* Rewritten SoundBlaster mixer code. Please test it!
* Minor enhancements to SamPlay console UI.
---
* AST (Aley's Sam Tune) file format introduced. A warning message is displayed whenever loading a plain file.
* If there are more tunes in a file (i.e.more than one), you can switch between them by pressing number keys.
* Channel mute is now controlled by QWERTYUI keys.
0.70 - 7.12.2002
====
* Rewritten HQ Digital Driver. The sound is now clickless and the driver works perfectly in Windows 2000/XP.
This also brings a slight change to SAAemu.dll interface and its usage.
* Some minor changes inside SAAemu.
* Changes in SamPlay to reflect new SAAemu interface.
