BASIC TRACK Statements - fvdhoef/aquarius-plus GitHub Wiki

PLAY TRACK

TYPE: BASIC System statement


FORMAT: PLAY TRACK

Action: The PLAY TRACK statement is used to play music files in the background while other plusBASIC commands continue to execute (asynchronously).

Notes:

  • Due to the complexities of system interrupts, the PLAY TRACK command only supports 3-voice songs (or the first three voices from a multi-part song).
  • Music is played on the FIRST virtual AY-3-8910 (PSG1). PSG2 is still available for additional AY calls, but performance may be degraded.

Examples of PLAY TRACK Statements:

LOAD TRACK "songfile.pt3"

Stops the currently playing track (if applicable), and loads the file "songfile.pt3" into memory.

PLAY TRACK

Plays the currently loaded song file asynchronously (in the background) as other plusBASIC commands are processed. Issuing another PLAY TRACK command while the song is playing causes the song to restart from the beginning.

STOP TRACK

Stops and "rewinds" the currently loaded and playing track file to the beginning, but does not play the song.

PAUSE TRACK

Pauses the currently loaded and playing track file.

RESUME TRACK

Resumes playing of the currently loaded track file from the point at which is was previously paused.