Changeset 8 for trunk/asma/Docs/Sap.txt

Sep 25, 1999, 4:33:18 PM (21 years ago)

Imported ASMA 0.8

1 edited


  • trunk/asma/Docs/Sap.txt

    r6 r8  
    1 General information
    2 ~~~~~~~~~~~~~~~~~~~
    31SAP file divides into two parts. First part (in text format) describes
    42player/music type. Second part (in binary format) contains player and music
    75describes where the data end.
    86Init data block ($02E2,$02E3) is not supported.
     8A little example:
     10FF FF 00 20 05 20 01 42 A3 04 D5
     11\___/ \_________/ \____________/
     12  A        B            C
     14A - Binary file header identification (always FF FF)
     15B - Load addres (StartAddr, EndAddr in LO,HI order - $2000 to $2005)
     16C - Data (that will be loaded from StartAddr)
     18This example will load values 01,42,A3,04,D5 into memory from $2000 to
    2637               double-speed tune put here the value 156 (312/2). 99% of tunes
    2738               are single-speed which means that you don't have to define the
    28                FASTPLAY variable for them.
     39               FASTPLAY variable for them. Works for player TYPE "B".
    3041commands PLAYER, MUSIC, INIT contain addresses in hexadecimal format:
    4556TYPE B
    4657TYPE M
     58TYPE S
     59TYPE D
     60TYPE R
    4862TYPE C - player from CMC (Chaos Music Composer). In this case, also these
    87101         distinguish is for future SAP releases.
     103TYPE S - SoftSynth. Like type "C", this type is temporary, and is used only
     104         for special type of songs, that where composed using program
     105         SoftSynth.
     106TYPE D - Digital. In SAP file with this type, must be also defined commands
     107         "INIT" and "PLAYER". "PLAYER" (like in type "B") sets address of
     108         procedure that will be called in 1/50s intervals and (like in type
     109         "B") must end with RTS opcode. INIT this time is a bit different. It
     110         sets address of procedure that will be called (with number of song
     111         in register A) to initialize program, but it can't end with RTS. It
     112         should start playing digis in endless loop. In SAP player there are
     113         emulated two ANTIC registers $D40A and $D40B that can help playing
     114         samples. D40B register increases its contents each two screen lines.
     115         D40A holds CPU till the end of actually created line. SAP emulates
     116         Atari in PAL with disabled screen. It means that we have 312 PAL
     117         lines, while each lines has 105 CPU cycles and 9 cycles of memory
     118         refresh (114 cycles per line).
     120Planned features:
     121TYPE R - Registers. In this type, binary part is not an Atari binary file.
     122         This part contains values that will be directly written to Pokey
     123         registers ($D200-$D208) in 1/50s intervals.
     124TIME xx:xx - song duration
    90126How to create .SAP file
    97133copy /b music.txt+music.bin
    99 The file is done!
     135The file is done now!
     136If you didn't find that song in ASMA, feel free to send it to
     137with all needed information (see ASMA.TXT for detailed information). The song
     138should be included in the nearest ASMA update.
Note: See TracChangeset for help on using the changeset viewer.