ASAP is a player of 8-bit Atari music for modern computers and mobile devices. It emulates the POKEY sound chip and the 6502 processor. The project was initially based on the routines from the Atari800 emulator, but the current version has a completely new original emulation core.

Input formats

ASAP supports the following file formats:

SAP (Slight Atari Player)

Designed for playing 8-bit Atari music on PCs. All other formats can be converted to SAP. Atari SAP Music Archive (ASMA) is a single big collection of SAP files.

CMC (Chaos Music Composer)

Atari music editor from early 1990s.

CM3 (CMC "3/4")

CMC with modified pattern length.

CMR (CMC "Rzog")

CMC with modified bass sounds.

CMS (Stereo Double CMC)

Stereo CMC.

DMC (DoublePlay CMC)

CMC with 6502 routine executed at double rate of the original CMC.

DLT (Delta Music Composer)

Atari music editor from 1990s.

FC (Future Composer)

Atari music editor from 1990s.

MPT (Music ProTracker)

Atari music editor from 1990s.

MPD (MPT DoublePlay)

MPT with 6502 routine executed at double rate of the original MPT.

RMT (Raster Music Tracker)

Modern Atari music editor running on Windows.

TMC, TM8 (Theta Music Composer 1.x)

Atari music editor from late 1990s. The two file extensions are treated identically and played in stereo. TM8 means it’s stereo (8-channel) music while TMC can be either mono or stereo.

TM2 (Theta Music Composer 2.x)

Modern Atari music editor.

STIL (SAP Tune Information List)

This isn’t a music format. It’s a text file that contains cover information and comments for many music files. This format is identical to C64 STIL. STIL.txt is distributed with ASMA (see above).

You can find some example files in examples.zip.

For viewing Atari pictures check out our sister project FAIL.

Ports

ASAP runs on Windows, Linux, in web browsers and mobile devices. This remarkable portability is possible thanks to the Ć programming language.

ASAP includes the following programs:

This table summarizes differences between the above versions.

To play the music on an 8-bit Atari, convert the music to an Atari program (XEX) using asapconv, WASAP, Winamp, Apollo or XMPlay.

There are other projects which use ASAP:

Using asapconv

Run the program from the command line to see the syntax. The -o/--output option selects the output format and is mandatory.

Using libasap

The library is documented in the asap.h header file. Be warned there might be breaking changes in the future versions of the library.

Compilation instructions

Required tools

For all builds you will need:

GNU Make

On Linux this program is called make. On other systems it may be called gmake (if this is the case, type gmake instead of make in the following instructions). On Windows you may install GNU Make from Cygwin or MinGW.

Standard Unix tools

I mean sh, cat, cp, rm, mkdir. On Windows you can find them in Cygwin.

xasm and MADS

If you are compiling latest source code from Git, install xasm and MADS.

Ć Translator

The core of ASAP is written in the Ć programming language. You’ll need cito. For your convenience, this is not needed for most of the C and C++ ports.

Make sure these tools are on your PATH.

Getting officially released source code

If you want to compile an official release of ASAP, download a source distribution (asap-*.tar.gz) and uncompress it to a directory of your choice.

On Unix-like systems:

tar zxf asap-*.tar.gz

On Windows you may use 7-Zip.

Getting latest source code

Alternatively you may get the latest version from the Git repository. To do this using a command-line Git client:

git clone git://asap.git.sourceforge.net/gitroot/asap/asap

This will fetch the latest code into a new directory called asap.

Building asapconv and libasap on Unix-like systems

From your shell prompt navigate to the directory which contains asap.c.

To compile and install, run the following commands:

make
sudo make install

The latter command installs the command-line converter and the C library in /usr/local.

Building the Audacious plugin on Unix-like systems

Install audacious-devel. To compile, run the following command:

make asap-audacious

To install in /usr/lib/audacious/Input:

sudo make install-audacious

Building the GStreamer plugin on Unix-like systems

To compile, run the following command:

make asap-gstreamer

To install in /usr/lib/gstreamer-0.10:

sudo make install-gstreamer

Building the MOC plugin on Unix-like systems

You need source code of MOC. The plugin is compatible with MOC 2.4.x and MOC 2.5.0 alpha.

Check MOC_INCLUDE and MOC_PLUGIN_DIR in the moc/moc.mk file. These should be the directory with MOC sources and the directory with the installed MOC plugins, respectively.

If the defaults are correct, use the following commands:

make asap-moc
sudo make install-moc

If you need to specify different directories, use:

make asap-moc MOC_INCLUDE=path/to/moc/sources
sudo make install-moc MOC_PLUGIN_DIR=/path/to/moc/plugins

Building the VLC plugin on Unix-like systems

Install vlc-devel. Verify paths at the top of vlc/vlc.mk. To compile, run the following command:

make asap-vlc

To install:

sudo make install-vlc

Building the XBMC plugin on Linux

You need source code of the Linux port of XBMC.

Run:

make asap-xbmc XBMC_DLL_LOADER_EXPORTS=path/to/dir/in/xbmc/sources

XBMC_DLL_LOADER_EXPORTS must point to the directory in XBMC sources which contains wrapper.def and wrapper.o. You should get xbmc_asap-i486-linux.so.

Recently I wasn’t able to enable the ASAP plugin in XBMC. This seems to be an XBMC issue.

Building the XMMS plugin on Unix-like systems

You need xmms and xmms-devel packages.

To compile, run the following command:

make asap-xmms

If the compilation finished successfully, you can install the plugin in your home directory:

make install-xmms-user

or for all users:

sudo make install-xmms

If you have another XMMS plugin that supports 8-bit Atari music, remove it in order to avoid conflicts.

Building asapconv, WASAP, Winamp/GSPlayer/Apollo/XMPlay/BASS plugins, RMT DLL, asapscan, shell extension and libasap on Windows

Install the C and C++ compilers from MinGW.

Open the command prompt in the root directory of ASAP sources and run:

make mingw

You should get asapconv.exe, wasap.exe, in_asap.dll, gspasap.dll, ASAP_Apollo.dll, xmp-asap.dll, bass_asap.dll, apokeysnd.dll, asapscan.exe, ASAPShellEx.dll and libasap.a.

Building Windows Media Player plugin and asap.lib on Windows

You additionally need Windows SDK (install native C++ compiler, headers, libraries and samples). Set Path, INCLUDE and LIB environment variables to point to the right locations in the Windows SDK. Make sure DSHOW_BASECLASSES_DIR is set correctly in win32\win32.mk.

Open the command prompt in the root directory of ASAP sources and run:

make win32/asap_dsf.dll win32/asap.lib

You will get asap_dsf.dll and asap.lib.

Building the Audacious plugin on Windows

Unpack Audacious source code and make sure AUDACIOUS_DIR in win32/win32.mk points to this directory.

Unpack GTK+ bundle (link in audacious/contrib/win32/notes.rtf) and make sure PKG_CONFIG points to the tool in GTK+.

Install gettext and libgnurx in MinGW (that’s probably not an exhaustive list, configure will complain about missing things).

From the Audacious source directory run:

bash configure PKG_CONFIG=../gtk/bin/pkg-config

After it finishes with no errors (warnings are fine), go to ASAP and run:

make win32/asapplug.dll

Put the DLL in lib/audacious/Input of the Windows binary distribution of Audacious.

Building the foobar2000 plugin on Windows

In addition to the common prerequisites and Windows SDK you need foobar2000 SDK - extract it to a new directory called foobar2000_SDK next to (not inside!) the ASAP directory.

Open the command prompt in the root directory of ASAP sources and run:

make win32/foo_asap.dll

This should produce foo_asap.dll.

Building the VLC plugin on Windows

Install VLC as usual, it includes the SDK. VLC_SDK_DIR in win32/win32.mk is fine for the default installation directory on 64-bit Windows - edit it if necessary.

Open the command prompt in the root directory of ASAP sources and run:

make win32/libasap_plugin.dll

You will get libasap_plugin.dll.

Building the XBMC plugin on Windows

You need Visual C++ Toolkit (it used to be a free download from Microsoft, now search the internet for VCToolkitSetup.exe) and .NET Framework SDK Version 1.1. Microsoft Visual C++ 2003 might work, but wasn’t tested.

Open the command prompt in the root directory of ASAP sources and run:

make win32/xbmc_asap.dll

This should produce xbmc_asap.dll, which you can use with XBox or Windows version of XBMC. The XBMC must include support for ASAP.

Alternatively, you may use the build_vctk.bat script in the xbmc directory.

Building WASAP, GSPlayer and Windows Media Player plugins for Windows CE

For WASAP and GSPlayer plugins you need CeGCC. For the Windows Media Player plugin you need Visual Studio 2008 (2005 might work, but wasn’t checked, 2010 won’t work).

Edit the WINCE_... paths at the top of win32/win32.mk so that they point to your installed tools. Open the command prompt in the root directory of ASAP sources and run:

make wince

This should produce wasap.exe, gspasap.dll and asap_dsf.dll in the win32/wince directory.

Building Java ASAP2WAV and Java applet

You need Java Development Kit (JDK).

If necessary, edit the paths at the top of java/java.mk so that they point to your installed tools. Open the command prompt in the root directory of ASAP sources and run:

make java/asap2wav.jar java/asap_applet.jar

This should produce asap2wav.jar and asap_applet.jar.

Building Java midlet

You need a Java ME SDK - I use Sun Java ME platform SDK.

Edit the WTK path at the top of java/j2me/j2me.mk so that they point to your installed Java ME SDK. Open the command prompt in the root directory of ASAP sources and run:

make java/j2me/asap_midlet.jad

This should produce asap_midlet.jar and asap_midlet.jad.

Building AndroidASAP

Install Android SDK with an Android platform(s) (I compile with 2.2 and test with 1.6).

Edit the paths at the top of java/android/android.mk so that they point to your installed SDK. Open the command prompt in the root directory of ASAP sources and run:

make android-debug

This should produce AndroidASAP-debug.apk. AndroidASAP integrates with file managers and the web browser. It uses the internet connection only for files clicked in the web browser.

Building C# ASAP2WAV, asapplay and SilverASAP on Windows

You need the .NET Framework, of course. For SilverASAP you need Silverlight and 7-Zip.

Open the command prompt in the root directory of ASAP sources and run:

make csharp

This should produce asap2wav.exe, asapplay.exe and SilverASAP.xap.

Building JavaScript command-line ASAP2WAV and the web browser player

Open the command prompt in the root directory of ASAP sources and run:

make javascript

asap2wav.js is the command-line script. asapweb.js plus asap.js are the browser player (you’ll probably need binaryHttpRequest.js as well).

Building Flash player version of ASAP

You need Flex SDK. Add its bin directory to your PATH.

Open the command prompt in the root directory of ASAP sources and run:

make flash/asap.swf

You should get asap.swf.

Building D ASAP2WAV and asapplay on Windows and Linux

You need DMD 2.054 or compatible D compiler. To build asapplay on Windows, you need D Windows API bindings. On Linux, you need ALSA development libraries (e.g. libasound2-dev package in Ubuntu). D bindings for ALSA are currently included in ASAP sources.

Open the command prompt in the root directory of ASAP sources and run:

make d

This should produce asap2wav.exe and asapplay.exe.

History

ASAP 3.1.2 (2012-06-25)
  • Created VLC plugin (SAP format only).

  • The JavaScript player now works in Chrome, Firefox, Internet Explorer 9 and 6, using XAudioJS.

  • Flash Player, Java applet, Silverlight and JavaScript players were put in a single "web" package.

  • UTF-8 encoding is supported for STIL.

  • Author is no longer hidden in the converted XEX files.

  • Winamp plugin opens ATR disk images and plays files inside them.

  • Audacious plugin updated to Audacious 3.2 and compiled for Windows.

  • BASS add-on updated to be compatible with AIMP 3 (SAP format only).

  • Enabled title/author/year in the BASS add-on (only selected BASS-based players use it, for example EncoreBassing).

  • Windows Media Player codec supports subsongs, AUTHOR and NAME (this works at least with Media Player Classic Home Cinema).

  • JavaScript interface of the web players has been extended and now has same functionality.

  • New TortoiseSVN and TortoiseGit plugins show changes in SAP tags.

ASAP 3.1.1 (2011-10-26)
  • Converted XEX files may optionally display information.

  • Fixed conversion of some TYPE D SAP files (e.g. Saturday_Demo.sap) to XEX.

  • Fixed time detection for some FC files.

ASAP 3.1.0 (2011-09-24)
  • WASAP/Winamp/Apollo/XMPlay file information window now includes STIL (SAP Tune Information List) and technical data.

  • Added Future Composer (*.fc) format (contributed by Jerzy Kut).

  • Written specification of the SAP format.

  • XMPlay displays STIL, tracker name and RMT instrument names.

  • The 64-bit setup package now includes the Windows Media Player plugin (useful for the Vista/7 sidebar WMP gadget).

  • Java release now includes asap.jar for WUDSN IDE.

  • asapplay in the D programming language has been ported to Linux and 64-bit compilers (by Adrian Matoga).

ASAP 3.0.1 (2011-07-15)
  • Uses linear interpolation for resampling (try Toxic_Cream.sap).

  • Displays titles of RMT, TMC and TM2 files.

  • The GSPlayer plugin now works on new Windows Mobile versions.

  • The Android player can play files directly from ZIP archives.

  • asapconv can auto-detect the native format (asapconv -o .%e *.sap).

  • asapconv can relocate modules (asapconv --address=a000 -o relocated.tmc original.tmc).

  • asapconv can write metadata to WAV files.

  • Created an experimental plugin for GStreamer (requires GStreamer with this bug fixed).

  • Converted XEX files disable the built-in BASIC.

  • Converted XEX files clear the I flag for the TYPE D PLAYER routine.

  • Doublequotes and pipes are now allowed characters in the AUTHOR and NAME tags.

ASAP 3.0.0 (2011-05-24)
New ports
  • Created a desktop player for the Adobe AIR platform.

  • Ported the Windows Media Player plugin to Windows CE.

  • Created a setup package with the Windows Explorer plugin for 64-bit Windows.

  • The Audacious plugin supports Audacious 2.5.

  • Created RPM packages with asapconv, ASAP C library and the XMMS plugin.

  • Created ASAP2WAV and a simple player in the D programming language.

  • JavaScript ASAP2WAV now runs in DMDScript and JScript.NET.

Emulation accuracy
  • Corrected ANTIC and POKEY timings.

  • Implemented STIMER, NMIST and NMIRES hardware registers.

  • Made the CONSOL register readable.

  • Fixed and optimized undocumented 6502 instructions.

Usability improvements
  • Conversion to Atari executables (XEX format, also known as COM).

  • RMT files can be extracted from SAP files created in Raster Music Tracker.

  • Implemented subsongs, seek bar and pause in the Android port.

  • Added a date picker in the WASAP/Winamp/Apollo/XMPlay file information window.

  • The FASTPLAY tag can be up to 32767 (previously 312).

  • Browser JavaScript player works on file:/// URLs.

  • asapscan uses a much faster length detection algorithm.

Bug fixes
  • Many important fixes in the Audacious plugin.

  • Many fixes in the Android port.

Cleanup
  • Rewritten ASAP core to the Ć programming language.

  • Removed defaultPlaybackTime and loopPlaybackTime parameters from applet, Flash Player and Silverlight interfaces.

ASAP 2.1.2 (2010-11-03)

There are new ports: Android, Audacious plugin, Silverlight and a simple command-line player using SDL. WASAP has been ported to Windows CE. There’s a new CAB package for Windows CE. Re-running WASAP opens the file selector. JavaScript ASAP2WAV now works in Rhino Shell, Google V8 shell, JScript.NET and JaegerMonkey. A slight fix and an optimization have been applied to 6502 emulation. "Show information about the currently playing file" is now available in XMPlay and has been fixed in Winamp.

ASAP 2.1.1 (2010-05-05)

The SAP file format has been extended with the "NTSC" tag. A BASS add-on (works in AIMP) has been created. A crash in XMPlay has been fixed. The XMMS plugin now works correctly on big endian machines. There’s a new Windows Explorer extension which displays metadata (title, author, year, duration, mono/stereo, number of subsongs, PAL/NTSC) and on Windows Vista/7 can edit them. A simple player in C# has been created.

ASAP 2.1.0 (2010-02-02)

ASAP2WAV has been replaced with asapconv which can additionally convert native modules to and from the SAP format, edit SAP tags and write MP3 files using LAME. A plugin for XMPlay has been created. The foobar2000 plugin has been updated to foobar2000 1.0. Time detection of RMT files has been fixed. PLAYER tag is now optional for TYPE D SAP files. "File Information" window now includes a better validation. Windows Media Player’s "Open" now includes ASAP file types. WASAP has a progress bar for writing WAV files. Flash player uses DEFSONG. Source code has been improved and moved from CVS to Git repository.

ASAP 2.0.0 (2009-12-10)

Windows setup has been created. ASAP has been ported to Flash Player and experimentally to JavaScript. New input formats: DLT, CMS and CM3 are supported. GTIA sound and COVOX are emulated. WASAP now includes "Save as WAV". JavaScript interface of the Java applet has been changed. There were huge changes in the build process: on Unix/Linux it no longer uses the "configure" script and on Windows it uses MinGW for almost all binaries (they are smaller than Visual C++ 2008’s, compatible with Windows 9x, wildcards work in ASAP2WAV).

ASAP 1.2.1 (2009-05-08)

XBMC plugin and POKEY emulation DLL for RMT have been created. The midlet has a progress bar, tags display, subsong selection and better performance. SKCTL emulation has been slightly improved. Documentation has been converted from plain text to HTML.

ASAP 1.2.0 (2008-03-29)

Plugins for Windows Media Player and Apollo have been created. RMT duration detection has been improved. A bug in TMC to SAP conversion has been fixed. ASAP can be compiled as C#.

ASAP 1.1.0 (2008-02-17)

All formats supported by ASAP can be converted to and from the SAP format, using the file information window of WASAP or the Winamp plugin. Unlike SAP Maker, ASAP supports subsongs and TIME tags. POKEY emulation has improved a little. Bugs in the XMMS plugin, the foobar2000 plugin and the applet have been fixed.

ASAP 1.0.2 (2007-11-02)

TIME tags can be edited in the file information window of WASAP and the Winamp plugin. A few emulation bugs have been fixed. Some user interface issues in WASAP have been fixed.

ASAP 1.0.1 (2007-06-10)

Plugin for MOC (Music On Console) has been created. WASAP, Winamp plugin and foobar2000 plugin can edit AUTHOR, NAME and DATE tags in SAP files. Winamp and XMMS plugins format titles as specified by the player. TMC files are now played in stereo. A few minor bugs have been fixed.

ASAP 1.0.0 (2007-05-28)

This release introduces completely new 6502 and POKEY emulation. SAP files with samples are supported. ASAP can be compiled as Java - an applet and an experimental midlet have been created. Winamp, foobar2000 and GSPlayer plugins support silence detection and muting selected POKEY channels. Winamp plugin supports subsongs and Winamp’s equalizer.

ASAP 0.3.0 (2007-05-06)

This release adds support for AUTHOR, NAME, DATE and TIME tags in SAP files. Winamp, foobar2000 and the new GSPlayer plugin have configurable playback time for songs with no TIME tag and songs marked with LOOP. foobar2000 plugin has been updated for version 0.9 of foobar2000. XMMS plugin supports the TM8 extension.

ASAP 0.2.1 (2006-01-28)

This release supports TM2 (Theta Music Composer 2.x) file format. Compilation and installation on Unix-like systems have been improved. foobar2000 plugin supports subsongs.

ASAP 0.2.0 (2006-01-15)

This release supports stereo and 16-bit audio output (enabled by default). Compressed SAP files (for example Fractals.sap) are played correctly. Subsongs are supported in RMT files. There are new plugins: for XMMS and for foobar2000 version 0.8. WASAP supports Windows Explorer’s "Open with".

ASAP 0.1.0 (2005-12-31)

This is the initial release of ASAP (Another Slight Atari Player) - a player/converter of 8-bit Atari music for modern computers. ASAP provides high-quality, identical to the popular Atari800 emulator, emulation of the POKEY sound chip and the 6502 processor.

This release includes: ASAP2WAV - portable command-line utility for converting 8-bit Atari music to WAV files, WASAP - a tiny player for Windows and in_asap - a Winamp plugin. Currently supported input formats are: SAP (except for samples and stereo), CMC, CMR, DMC, MPT (without samples), MPD, RMT (mono) and TMC (mono).

Authors

Piotr Fusik <fox@scene.pl>

Creator and main developer.

Atari800 Emulator Developers (http://atari800.sourceforge.net)

6502 and POKEY emulation used in 0.x.y versions of ASAP.

Zdenek Eisenhammer <pg@pinknet.cz>

Testing.

Henryk Karpowicz <henkar@poczta.tygrys.net>

CMC routine modified for the CM3 format.

Maciek Konecki <maciusk1@wp.pl>

Porting to C#.

Marek Konopka <konop11@poczta.onet.pl>

6502 routine for playing DLT.

Daniel Kozminski <daniel.kozminski@gmail.com>

Ideas.

Jerzy Kut <mono@atari.pl>

FC format support.

Marcin Lewandowski <jaskier@atari8.info>

6502 routines for playing CMC, MPT, TMC and TM2.

Ian Luck <il@un4seen.com>

Guided development of XMPlay and BASS plugins.

Adrian Matoga <epi@atari8.info>

COVOX information and test files. Testing. Porting to D.

Perry McFarlane <perry_m@fastmail.fm>

POKEY reverse-engineering.

Kostas Nakos <knakos@gmail.com>

Windows CE testing.

Mariusz Rozwadowski <ramosc64@o2.pl>

Suggested CMS, CM3, DLT and STIL format support.

Slawomir Sledz <slaves@scene.pl>

Windows Mobile setup. Thorough testing.

David Spilka

6502 routine for playing CMS.

Radek Sterba

6502 routine for playing RMT. Testing.

Lukasz Sychowicz <xray@scene.pl>

Windows icons. Testing.

Pawel Szewczyk <ripek@op.pl>

Windows setup graphics.

Michal Szpilowski <miker@atari.pl>

Testing.

Grzegorz Zyla <gsunr@poczta.onet.pl>

XBMC plugin testing.

Feedback

If you are interested in the ASAP project, please subscribe its mailing list. This list is for users and developers. Once you subscribe, you can post comments, ideas and questions about ASAP. They will be answered ASAP. ;-)

Use tracker to submit bug reports, feature requests and small code patches.