Sei sulla pagina 1di 37

C64 Tape loaders

http://www.luigidifraia.com/c64/docs/tapeloaders.html

Loaders documented by Luigi Di Fraia


In an effort to make information about C64 commercial turbo loaders available, I collected part of my work in this page. Please note that only docs in a "Released" status are trustworthy. Index of documented loaders: Accolade/EA (BY: J S EASTERBROOK) Ace of Aces Alternative Software Alternative Software (DK) Audiogenic Burner (Mastertronic variant) Cult tape Freeload Slowload Ocean New tape 4 ODEload Rainbow Arts tape (Microload variants) Tengen/Domark and Image Works tape Trilogic v3.2 Turbo tape 64 Flashload Power Load Snakeload V5.0 Snakeload V5.1 Elder Gremlin tape Gremlin's Fastload Gremlin tape 1 Gremlin tape 2 Ocean New tape 1 Ocean New tape 2 Ocean New tape 3 New Hi-Tec/Titus/Krisalis tape Atlantis tape FF tape Rack-it variant Ash & Dave tape Bleepload variant BITURBO (BY SC 85) Anirog tape (22/09-84) Tequila Sunrise Tape Fast Evil Last Updated on: November 6, 2011

Accolade/EA (BY: J S EASTERBROOK)

1 de 37

04/02/2013 04:15 p.m.

C64 Tape loaders

http://www.luigidifraia.com/c64/docs/tapeloaders.html

--------------------------------DOC Status: Released. Used in: "Apollo 18", "Mini Putt-The Ultimate Challenge", "Powerboat USA", "Rack'em", "Serve and Volley" (supplied by c64heaven). A variant was found in: "Card Sharks", "Chuck Yeager", "Bards Tale", "The Cycles-International Grand Prix Racing", "Grand Prix Circuit", "Jack Nicklaus Greatest 18 Holes of Major Championship Golf", "PHM Pegasus", "Steel Thunder", "Test Drive", "Test Drive 2" and "World Tour Golf" (supplied by c64heaven). Structure : After the CBM boot file, there is another CBM file that contains the main turbo loader. Turbo blocks : Threshold: 0x01EA (490) clock cycles (TAP value: 0x3D) Bit 0 pulse: 0x29 Bit 1 pulse: 0x4A Endianess: MSbF Pilot byte: 0x0F (size: 8 bytes) Sync byte: 0xAA Header -----16 02 02 01 Data ---Data is split in sub-blocks of 256 bytes each, or less for the last one. Each sub-block is followed by its XOR checksum byte. There are no pauses between sub-blocks. Trailer: 8 Bit 0 pulses + 1 longer pulse. Notes: The variant has Threshold: 0x01A9 (425) clock cycles, but uses the same pulsewidths, more or less. It's often used in EA releases (whose first CBM Data block CRC32 is sometimes 0xEA684D09).

bytes: bytes: bytes: byte :

Filename Load address (LSBF) Data size (LSBF) XOR Checksum of all Header bytes

2 de 37

04/02/2013 04:15 p.m.

C64 Tape loaders

http://www.luigidifraia.com/c64/docs/tapeloaders.html

The name of the author was found in "Apollo 18", who is credited for "Technical" contribution.

Ace Of Aces ----------DOC Status: Released. Used in: "Ace of Aces", "Express Rider", "Future Knight", "Knight Games", "Leviathan", "Questprobe Featuring the Human Torch and the Thing", "Way of the Tiger", "Xevious". Structure : The CBM Data contains the loader, encrypted. Autostart is achieved by overwriting vector at $0326. Turbo blocks : Threshold: 0x0168 (360) clock cycles (TAP value: 0x2D) Bit 0 pulse: 0x22 Bit 1 pulse: 0x44 (TAPClean uses 0x47) Endianess: MSbF Pilot byte: 0x80 (size: 256 bytes) Sync byte: 0xFF Header -----02 bytes: Load address (LSBF) 02 bytes: End address (LSBF) 16 bytes: File name Data 01 byte : XOR Checksum of Data Trailer: 1 longer pulse (e.g. 0x64). Notes: The programmer of "Ace of Aces" is J. Stuart Easterbrook, who I credit as the author of the Accolade/EA loader.

Alternative Software -------------------DOC Status: Released.

3 de 37

04/02/2013 04:15 p.m.

C64 Tape loaders

http://www.luigidifraia.com/c64/docs/tapeloaders.html

Used in: "Cricket Crazy", "Gold Or Glory", "S.M.A.S.H.E.D.", "Wiz-Biz" (supplied by Peepo and SLC). Structure : After one CBM boot file, there are 2 turbo blocks. CBM Data CRC is 0x823DBD1F. The turbo loader code is entirely inside the CBM Header block. Turbo blocks : Threshold: 0x02D0 (720) clock cycles (TAP value: 0x5A) Bit 0 pulse: 0x3D Bit 1 pulse: 0x7E Endianess: LSbF Pilot bit: 0x52 pulse (size: 0xA00 pulses) Sync bit: a single Bit 1 pulse Additional sync train (bytes): 0x00, 0x00, 0x1A, 0xBB Header -----01 byte : Ignored by loader 02 bytes: Load address (LSBF) 02 bytes: End address (LSBF) Data Trailer: none.

Alternative Software (DK) ------------------------DOC Status: Released. Used in: "Trap Door, The", "Popeye", "Strike Force Cobra" (supplied by Peepo). Structure : After one CBM boot file, there is one turbo file that loads at $CF00, part of the loader. All turbo files hold 0x0100 bytes and those that are loaded consecutively in RAM have no long silence between them. CBM Data CRC is 0x057A87A2. CBM files contain the string "DK". Turbo blocks (Type 1 - used in Trap Door only):

4 de 37

04/02/2013 04:15 p.m.

C64 Tape loaders

http://www.luigidifraia.com/c64/docs/tapeloaders.html

Bit Threshold: 0x0252 (594) clock cycles (TAP value: 0x4A) Pilot pulse Threshold: 0x047F (1151) clock cycles (TAP value: 0x90) Bit 0 pulse: 0x2B Bit 1 pulse: 0x64 Endianess: MSbF Pilot: 0xB5 pulse repeated (size: 0x1F pulses - a minimum of 5 is expected by the loader) Sync: 3 bits whose value is irrelevant (100 for file loaded at $CF00, 111 for all the others) Header -----01 byte : Load address (MSB) Data Trailer: 16 bits + 1 longer pulse to separate blocks Turbo blocks (Type 2): Bit Threshold: 0x0164 (356) clock cycles (TAP value: 0x2D) Pilot pulse Threshold: 0x03E8 (1000) clock cycles (TAP value: 0x7D) Bit 0 pulse: 0x21 Bit 1 pulse: 0x36 Endianess: MSbF Pilot: 0xA5 pulse repeated (size: 0x1F pulses - a minimum of 5 is expected by the loader) Sync: 3 bits whose value is irrelevant (100 for file loaded at $CF00, 111 for all the others) Header -----01 byte : Load address (MSB) Data Trailer: 16 bits + 1 longer pulse to separate blocks Notes: Load address LSB is always 0x00. Special values for MSB are: 0x00 = END OF PROGRAM - The BASIC program in RAM is executed. If the BASIC program uses the LOAD instruction, the turbo loader will be executed again. This is often used to display a load picture and then carry on with the loader. 0x01 = End of the chain of blocks that make up a single file. 0x02 = END OF PROGRAM and RESET VECTORS (via $fd15). The above special values are followed by a Data payload but its

5 de 37

04/02/2013 04:15 p.m.

C64 Tape loaders

http://www.luigidifraia.com/c64/docs/tapeloaders.html

contents are not loaded.

Audiogenic ---------DOC Status: Released. Used in: "Emlyn Hughes Soccer", "Exile", "Graham Gooch's All Star Cricket", "Impact", "Loopz", "World Cup Rugby" (supplied by c64heaven). Structure : CBM Data CRC32: 0x206A8B68. Turbo blocks : Threshold: 0x013F (319) clock cycles (TAP value: 0x28) Bit 0 pulse: 0x1A Bit 1 pulse: 0x36 Endianess: MSbF Pilot byte: 0xF0 (size: 4 bytes) Sync byte: 0xAA Header -----01 byte : Load address (MSB, LSB being always 0x00) Some values refer to special blocks. They are: 0x00, 0x01, 0x02, 0xCF. 0xCF: it is special since part of the loader code is contained in the first turbo file, ALWAYS loaded at $CF00-$CFFF (ALWAYS the same code). There we find some messages and a custom print routine. The messages read as follows: LOADING ERROR, PLEASE STOP THE TAPE, PLEASE PRESS REWIND, PLEASE PRESS PLAY. 0x00: restores the Default IRQ Routine and initializes CIA I/O Devices before executing a custom routine. 0x02: it is the same as 0x00, but also restores RAM Vectors for Default I/O Routines. 0x01: it's a re-initialization value. Sync is hunt for again if this value is found. Data: 256 bytes 01 byte : XOR Checksum of Data Trailer: If any chained turbo block follows, there's always a complete

6 de 37

04/02/2013 04:15 p.m.

C64 Tape loaders

http://www.luigidifraia.com/c64/docs/tapeloaders.html

byte, whose value is 0x01. When no block follows, but a long pulse, this byte is usually broken (read the first note below). So the trailer byte is NOT mandatory. Notes: The end of a chain (also just a file) is followed by 7 bit 0 pulses, and often there's also a longer pulse which doesn't match bit 0/1 pulses (a broken byte, to make the long story short). Then we have a long pulse (pause). In a perfect world, each block would be followed by 8 pulses which make up a value of 0x01. Data blocks smaller than 256 bytes must be padded. For a deeper analisys of this loader's behaviour, check Fabrizio Gennari's docs.

Burner (Mastertronic variant) ----------------------------DOC Status: Released (parts of it from FungusNOS). Used in: "Orbitron", "Magic Carpet", "Hektic", "Munch Mania", "Spectipede", "Starrace", and "Darkstar". Structure : A regular CBM part, whose CBM data CRC32 is sometimes 0x53A23D4D. After turbo blocks there's another CBM part followed by additional turbo blocks. CBM Header stores vital loader data. It's encrypted the same way as legacy Burner. The XOR value is 0x59. Turbo blocks : Threshold: 0x0180 (384) clock cycles (TAP value: 0x30) Bit 0 pulse: 0x23 Bit 1 pulse: 0x42 Endianess: Varies per tape Pilot byte: Varies per tape (size: 192 bytes) Sync byte: Varies per tape Header -----02 bytes: Load address (LSBF) 02 bytes: End address (LSBF) Data

7 de 37

04/02/2013 04:15 p.m.

C64 Tape loaders

http://www.luigidifraia.com/c64/docs/tapeloaders.html

01 byte: EOF marker (when it's 0x00 it means end of a chain) 02 bytes: Execution address (LSBF) (dummy value until the EOF marker is 0x00) 02 bytes: Execution address repeated (last pulse of which is usually broken, so it's NOT mandatory) Note: Hardcoded $033C+$87 $033C+$92 $033C+$82 inside CBM Header block: or $89: Pilot byte or $94: Sync byte or $84: ROR or ROL (Endianess is LSbF or MSbF respectively)

Cult tape --------DOC Status: Released. Used in: "Boxing Manager", "Cricket Captain", "International Football", "Scottish Football League", "Soccer Rivals", "World Cup" (supplied by c64heaven). Structure : A regular CBM part, whose CBM data CRC32 is always 0xF1D441D8. This data is loaded at $02E0-$0303. $02E0 is the loader entry point too. Turbo blocks : Threshold: 0x01A0 (416) clock cycles (TAP value: 0x34) Bit 0 pulse: 0x27 Bit 1 pulse: 0x3E Endianess: LSbF Pilot bit: Bit 0 pulses (size: 2064 pulses about) Sync bit: a single Bit 1 pulse Additional Sync byte: 0xAA Data Trailer: 2031 Bit 0 pulses + 1 Bit 1 pulse (possibly Bit 0 pulse shifted). Note: Hardcoded inside CBM Data block (loaded at $02E0): $02E0+$0A=$02EA: Load address (LSB)

8 de 37

04/02/2013 04:15 p.m.

C64 Tape loaders

http://www.luigidifraia.com/c64/docs/tapeloaders.html

$02E0+$0E=$02EE: Load address (MSB) (You may also search for pattern: A9 ll 85 AC A9 mm 85 AD) Hardcoded inside CBM $033C+$1B=$0357: End $033C+$1F=$035B: End (You may also search Header block (loaded at $033C): address+1 (LSB) address+1 (MSB) for pattern: A9 ll 85 AE A9 mm 85 AF)

Freeload Slowload ----------------DOC Status: Released. Used in: "Great Escape", "Platoon", "Rambo", "Top Gun" ("Hollywood" compilation). Structure : As genuine Freeload, but with a bigger threshold. CBM Data CRC32 is often: 0x0AC328F5. Turbo blocks : Threshold: 0x0768 (1896) clock cycles (TAP value: 0x77) Those games use pulses as per below:
Bit 0 1 Pulse 0x5A 0x85

Ocean New tape 4 ---------------DOC Status: Released. Used in: "Bart VS The Space Mutants", "Lethal Weapon", "Nick Faldo's Championship Golf", and "WWF European Rampage Tour" (supplied by c64heaven and cip). A variant was found in: "Outrun Europa" and "Liverpool". It doesn't use data padding at all and has a trailer made up of 7 bits + 1 longer pulse (e.g. 0x80).

9 de 37

04/02/2013 04:15 p.m.

C64 Tape loaders

http://www.luigidifraia.com/c64/docs/tapeloaders.html

Structure : Basically Freeload, with a different inner structure. CBM Data CRC32 is often 0xB211DFED. Turbo blocks : Threshold: 0x0168 (360) clock cycles (TAP value: 0x2D) Bit 0 pulse: 0x24 Bit 1 pulse: 0x44 Endianess: MSbF Pilot byte: 0x40 (size: 128 bytes = 1024 pulses) Sync byte: 0x5A Header -----01 01 02 02 Data ---Length is multiple of 256, so a block may be padded with zeroes or memory containings during the tape mastering operation. Trailer: 1 longer pulse (e.g. 0x80). Notes: Padding data must not be included in checksum calculation. Padding data must not be removed, even if those bytes can be set to 0.

byte : byte : bytes: bytes:

File ID XOR Checksum of Data ( NOT checked by the loader) Load address (LSBF) End address+1 (LSBF)

ODEload ------DOC Status: Released. Used in: "Pipe Mania (Empire), "Better Dead than Alien (Electra)", partly in "Yes prime minister" (c64heaven), and probably in "Block Busters (TV Games)". Structure: First character in CBM filename is: ">" (0x3E) CBM Data CRC32: 0xD5961DB0 Turbo blocks:

10 de 37

04/02/2013 04:15 p.m.

C64 Tape loaders

http://www.luigidifraia.com/c64/docs/tapeloaders.html

Threshold: 0x01B0 (432) clock cycles (Tap value: 0x36) Bit 0 pulse: 0x25 Bit 1 pulse: 0x50 Endianess: MSbF Pilot byte: 0x20 (size: 64 bytes) Sync byte: 0xDB Header -----02 bytes: Load address (LSBF) 02 bytes: End address+1 (LSBF) Data 01 byte : XOR checksum of Data Trailer: 1 longer pulse Note: The first TURBO file contains a copy of this loader (load address may vary) and the string with loader's name which is sometimes shown during load (not in PipeMania): 05 0E 28 6F 64 65 4C 4F 41 44 20 31 39 38 39 29 "..(odeLOAD 1989)"

Rainbow Arts tape (Microload variants) -------------------------------------DOC Status: Released. Used in: "Circus Attractions" (v1), "Curse of Ra" (v1/2), "Grand Monster Slam" (v1), "Logical" (v2), "Puffys Saga" (v1), "Rock'n'Roll" (v1/2), "Rolling Ronny" (v2), "Western Games" (v1), "X-Out" (v1/2) (supplied by c64heaven). Structure : CBM Data CRC32 is sometimes 0xED3BB9E4. Turbo blocks, type 1 : Threshold: 0x014D (333) clock cycles (TAP value: 0x2A) Bit 0 pulse: 0x19 Bit 1 pulse: 0x36 Endianess: LSbF Pilot byte: 0xA0 (size: 992 bytes, even if 867 were found too)

11 de 37

04/02/2013 04:15 p.m.

C64 Tape loaders

http://www.luigidifraia.com/c64/docs/tapeloaders.html

Sync train: 0x0A, 0x09, ... , 0x01 Header -----01 byte : File ID 02 bytes: Load address (LSBF) 02 bytes: 0x10000 - Block Size (LSBF) Data 01 byte : XOR Checksum of Data Trailer: a couple of Bit 0 and Bit 1 pulses followed by a "longer" pulse. Turbo blocks, type 2 : Threshold: 0x014D (333) clock cycles (TAP value: 0x2A) Bit 0 pulse: 0x19 Bit 1 pulse: 0x36 Endianess: LSbF Pilot byte: 0xA0 (size: 852 bytes) Sync train: 0x0B, 0x0A, 0x09, ... , 0x01 Header -----03 bytes: File name 02 bytes: Load address (LSBF) 02 bytes: 0x10000 - Block Size (LSBF) Data 01 byte : XOR Checksum of Data Trailer: a couple of Bit 0 and Bit 1 pulses followed by a "longer" pulse.

Tengen/Domark and Image Works tape ---------------------------------DOC Status: Released. Used in: "3D construction kit", "Cisco Heat" (IW) [Multiloaded], "Skull and Crossbones" [Multiloaded], "Pit Fighter" [Multiloaded], "Badlands", "Rampart" [Multiloaded], "Rugby the World Cup" [Multiloaded], "The Spy who loved me" [Multiloaded], (thanks to c64heaven for those last 4 taps and "3DCK") and probably a lot of other TENGEN/DOMARK Releases.

12 de 37

04/02/2013 04:15 p.m.

C64 Tape loaders

http://www.luigidifraia.com/c64/docs/tapeloaders.html

Structure : There are 2 complete CBM files. The first CBM file (DATA size: 2 -twobytes, Loads at $029F: 51 03, CRC32: 0x848FD0AF) autoexecutes, loads a 2nd complete CBM file (which contains the Turbo Loader) and executes it. Autostarting ROM cartridges are disabled. Turbo blocks : Threshold: 0x029F ??? (671) clock cycles (TAP value: 0x54) Bit 0 pulse: 0x44 Bit 1 pulse: 0x65 Endianess: LSbF Pilot byte: 0xA0 (size: 255 bytes, but a pulse is often missing in the beginning) Sync train: 0x0A, 0x09, ..., 0x01 Header -----Type 1 (used to load few initial blocks only) 02 bytes: Length of Data (LSBF) 01 byte : File ID Type 2 (used for multi-load parts, if any is present) 02 bytes: Length of Data (LSBF) 02 bytes: Load address (LSBF) n bytes: file name (size is customable) n=1 in "Skull and Crossbones" n=2 in "Cisco Heat", "Hydra" and "Pit Fighter" n=4 in "Rampart" Data ----Length of Data- bytes: encrypted data. To decrypt do: data = data ^ a; a = (a + 1) & 0xff; setting a=0 BEFORE reading the first encrypted data byte. 01 byte : XOR Checksum of decrypted Data 01 byte : 0x20 = EOF marker (last bit of which is broken if no trailer follows, so that it's NOT mandatory) Trailer: Often missing in Type 1 blocks. It is usually made up of 7 Bit 0 pulses followed by a bigger pulse (e.g. 0x76-0x82).

13 de 37

04/02/2013 04:15 p.m.

C64 Tape loaders

http://www.luigidifraia.com/c64/docs/tapeloaders.html

Notes: Header type can be identified using the EOF markers. "Load address" is sometimes ignored ("Cisco Heat", "Pit Fighter", "Rampart").

Trilogic v3.2 ------------DOC Status: Released. Used in: A lot of Alternative releases, as "Double Dare", "Fireman Sam", "Hellfire Attack", "Kentucky Racing", "Merlin", "Metranaut", "Strike Force", "Superted" (supplied by c64heaven). Structure : CBM Data CRC32: 0x848FD0AF. Turbo blocks : Threshold: 0x0141 (321) clock cycles (TAP value: 0x28) Bit 0 pulse: 0x1C Bit 1 pulse: 0x35 Endianess: MSbF Pilot byte: 0x0F (size: 256 bytes) Sync byte: 0x0E, 0x0D, ... 0x00 Header -----02 bytes: Load address (LSBF) 02 bytes: End address+1 (LSBF) Data 01 byte : Checkbyte Addition of data bytes, plus 1 for each added byte. Trailer: NONE found. Note: An equivalent way to calculate checksum is: (Addition of data bytes + data size LSB) & 0xFF.

Turbo tape 64

14 de 37

04/02/2013 04:15 p.m.

C64 Tape loaders

http://www.luigidifraia.com/c64/docs/tapeloaders.html

------------DOC Status: Released. Used in: A lot of older releases, among which: "China Miner", "Great Giana Sisters, The", "To be on Top". Structure : Each turbo file is made of a HEADER section and a DATA one, without gaps between them. Turbo blocks : Threshold: 0x0107 (263) clock cycles (TAP value: 0x21) Bit 0 pulse: 0x1A Bit 1 pulse: 0x28 Endianess: MSbF Pilot byte: 0x02 (size: the genuine tape mastering program saves 256*4+247 of them for HEADER and 256+247 for DATA) Sync train: 0x09, 0x08, ... 0x01 01 byte: File type 0x00 for DATA 0x01 (or any odd number) for HEADER (relocatable program) 0x02 (or any even number) for HEADER (non-relocatable program)

Header file ----------02 bytes: Load address (LSBF) 02 bytes: End address+1 (LSBF) 01 byte : Whatever $00B0 contained at the time of saving 187 bytes: Filename, padded with 0x20 Data file --------n bytes : Data 01 byte : Checkbyte XOR Checksum of Data Trailer: After the DATA file a trailer follows, made up of bytes whose value is $00. The genuine Tape Mastering program saves 255 of them. Notes: This is the "TURBO TAPE 64" format, written by Stephan Senz Freiburg in 1983. The loader description is based on previously available documents but

15 de 37

04/02/2013 04:15 p.m.

C64 Tape loaders

http://www.luigidifraia.com/c64/docs/tapeloaders.html

it was reviewed by looking at the tape mastering tool. Section type is determined by the (optional) secondary address used to save the file to tape: <-S "PROGRAM NAME"[,1,secondary address] A secondary address of zero (or any even number) means relocatable file, any odd number means non-relocatable. In other words, a non-zero value of Section type equals secondary address + 1. Pilot + sync bytes make up a block of 256*5 bytes for HEADER and 256*2 for DATA. Header hasn't got any XOR checksum. If the file name is longer than 16 characters, the excess will be truncated by the SEARCHING and FOUND messages, but will still be present on the tape.

Flashload --------Used in: "Ghostbusters", "Hacker", "On Court Tennis" (supplied by cip and BGK), "Master of Lamps", "Rock'n'Bolt" and "Great American Cross Country Road Racing" (supplied by c64heaven). Structure : After the CBM boot file (DATA size: 255 bytes, CRC32: 0x8E027BD2) there's another CBM Data block containing the loader. It checks for autostarting ROM cartridges (e.g. SIMON's BASIC) and disk drives. If any is found, usually load doesn't end successfully. Turbo blocks : Threshold: 0x0118 (280) clock cycles (TAP value: 0x22) Bit 0 pulse: 0x1F (very close to threshold!) Bit 1 pulse: 0x31 Endianess: MSbF Pilot bit: Bit 1 pulses (size: 2048 pulses about) Sync bit: a single Bit 0 pulse Additional Sync byte: 0x33 Header -----02 bytes: Load address (LSBF) 02 bytes: End address (LSBF) Data 01 byte : XOR Checksum of Data

16 de 37

04/02/2013 04:15 p.m.

C64 Tape loaders

http://www.luigidifraia.com/c64/docs/tapeloaders.html

Notes: Two variants were found so far (CBM DATA CRC32 not matching the documented one): Return of the Jedi: whole pilot is 20480 pulses Falcon Patrol 2: no sync byte at all

Power Load ---------Used in: "Felix in the factory", "Ghouls", "Jet Power Jack" - probably any other "Micro Power, Tynesoft" release -, and "Stock Car" (supplied by cip and BGK). Structure : There are 2 complete CBM files (first one DATA CRC32: 0xD407EAA3, second one HEADER CRC32: 0x4140B476). The second CBM file contains the Main Loader ($CE47-$CF09) where the needed load information is stored (e.g. Load Address, see Notes later). The name of this loader was found on game boxes. It's very similiar to "Anirog tape" and its variants. A clone with a different loader structure can be found on "Builder Ben" (supplied by BGK), and with small variants in its code on "Shockway Rider" (supplied by c64heaven). Turbo blocks : Threshold: 0x0107 (263) clock cycles (TAP value: 0x20) Bit 0 pulse: 0x1C Bit 1 pulse: 0x29 Endianess: MSbF Pilot byte: 0x02 (size: 1043 bytes) Sync train: 0x09 down to 0x00 Data n bytes: Additional Data not read (size varies) 1 byte : XOR checksum of all data bytes included those n additional bytes Trailer: 2048 Bit 0 pulses about Notes: Load Address is at: $CE48 (LSB)/$CE4A (MSB)

17 de 37

04/02/2013 04:15 p.m.

C64 Tape loaders

http://www.luigidifraia.com/c64/docs/tapeloaders.html

End Address+1 is at: $CE50 (LSB)/$CE52 (MSB) Execution Address is at: $CF07 (LSB)/$CF08 (MSB) The clones store those infos somewhere else, but, seeking for a common pattern, they can be extracted easily from both versions with a common method. Power Load-er doesn't read and check the checksum byte, but a checksum byte is present and just after data block.

Snakeload V5.0 -------------Used in: "Soldier of Light" (under check), "Shinobi", "Saint Dragon", "Ninja Warriors", "Narc" (these last two were supplied by c64heaven) and probably some more. Structure : This turbo loader is usually contained in a CBM file loaded at $0801 (BASIC area) without an autostart. The following text was found in "Ninja Warriors"' CBM Data block: SNAKELOAD V5.0 (C) STEVE SNAKE, KML 1987. THIS IS NOT SUPPOSED TO BE PROTECTED SO DON'T THINK YOU ARE GOOD FOR CRACKING IT !!!KYLIE RULES! Turbo blocks : 2 pulsewidth sets were found so far:
Bit 0 1 Th Shinobi, Saint Dragon, Ninja Warriors Narc 0x60 0xA0 0x3F 0x5F

0x03FF (0x80) 0x0240 (0x48)

Endianess: MSbF Pilot bit: Bit 0 pulses (size: 2063 pulses = 257 bytes + 7 bits) Sync bit: a single Bit 1 pulse Header -----05 bytes: 65 69 6C 79 4B: "eilyK" - Identifier (read backwards: "Kylie") 01 byte : File ID 02 bytes: Load address

(LSBF)

18 de 37

04/02/2013 04:15 p.m.

C64 Tape loaders

http://www.luigidifraia.com/c64/docs/tapeloaders.html

02 bytes: End address+1 (LSBF) Data 01 byte : Checksum (addition of data bytes) Trailer: Bit 0 pulses, last one being usually longer. size: 2032 = 0xFE bytes in "Shinobi" size: 248 = 0x1F bytes in "Narc", "Saint Dragon" and "Ninja Warriors"

Snakeload V5.1 -------------Used in: "Final Blow", "Rodland", "SWIV" (supplied by c64heaven) "Double Dragon 3", "Indy Heat" (supplied by Mr.Fox). Structure : This turbo loader is usually contained in a CBM file loaded at $0801 (BASIC area) without an autostart. Turbo blocks : Threshold: 0x01BE (446) clock cycles (TAP value: 0x38) Bit 0 pulse: 0x28 Bit 1 pulse: 0x48 Endianess: MSbF Pilot bit: Bit 0 pulses (size: 2055 pulses = 256 bytes + 7 bits) Sync bit: a single Bit 1 pulse Header -----08 bytes: Identifier, read backwards. 3 of them were found: B2 B4 B2 D4 CE CF D2 C6 (" FRONT242 " - Uppercase and reversed) in "Final Blow", "Rod Land (Side1)" 85 8C 8C 85 88 83 89 8D (" MICHELLE " - Lowercase and reversed) in "S.W.I.V. (Side1)" C8 C3 D4 C9 D2 C4 CC C5 (" ELDRITCH " - Uppercase and reversed) in "Rod Land (Side2)", "Double Dragon 3", "Indy Heat" 01 byte : File ID 02 bytes: End address+1 (MSBF) 02 bytes: Load address (MSBF) Data

19 de 37

04/02/2013 04:15 p.m.

C64 Tape loaders

http://www.luigidifraia.com/c64/docs/tapeloaders.html

01 byte : Checksum Its value is calculated by XORing Data bytes and adding 1 to the XOR checksum AFTER a byte is stored at an address with LSB being 0xFF (e.g. $08FF, $7DFF, etc.). Trailer: Bit 0 pulses (size: 512 = 0x40 bytes).

Elder Gremlin tape -----------------DOC Status: Released. Used in: "Blasteroids", "Deathwish 3", "Xybots", "Peter Beardsley International Football" and "Thunderbirds (Grandslam)" (supplied by c64heaven). Structure : There are 2 complete CBM files. The first CBM file is loaded at $02A7 (sometime Data CRC32 is: 0xF5D2B483), autoexecutes and loads a 2nd complete CBM file (which contains the Turbo Loader) at $0400 (video area) and executes it. The second CBM file is named "PROGRAM". There's just a single turbo block on tape. Turbo blocks : Threshold: 0x028E (654) clock cycles (TAP value: 0x52) Bit 0 pulse: 0x40 Bit 1 pulse: 0x70 Endianess: MSbF Sync Data Trailer: Usually a pattern made up of 79-80 bit 1 and bit 0 pulses. Here the patterns I found so far: Blasteroids: byte] PBIF : TB Part 1 : TB Part 2 : byte] TB Part 3 : TB Part 4 : byte] Xybots : F7F7: F7 B9 FF A6 04 3F B9 BD 21 [incomplete F7F7: 00 00 00 A6 04 00 00 00 00 2E F7F7: 00 00 00 AE 04 00 00 00 FF 2E F7F7: 00 00 00 AE 04 00 00 00 FF [incomplete F7F7: 00 00 00 AE 04 00 00 00 FF 2E F7F7: 00 00 00 AE 04 00 00 00 FF [incomplete F7F7: 00 00 00 A6 04 00 00 00 FF [incomplete byte: 0xF0

20 de 37

04/02/2013 04:15 p.m.

C64 Tape loaders

http://www.luigidifraia.com/c64/docs/tapeloaders.html

byte] I would say that this pattern should be present in legacy tapes and that the 0x04 value should always be at offset 0x05. When Trailer is missing (as in Deathwish 3), the last pulse is broken = not matching any of the given pulsewidths! Notes: Load address is found inside the second CBM file at: $0434 (LSB)/$0439 (MSB) Data Size -1 is found inside the second CBM file at: $043E (LSB)/$0442 (MSB) The last byte is always loaded at $FFF6 ( this fact may be used as a plausibility check when seeking this type of files). Load address is usually $0800, but in Deathwish 3. Due to these anomalties in Deathwish 3 I would say it's a non-genuine Elder Gremlin tape. That said, I would only consider genuine Elder Gremlin files those that are loaded at $0800-$FFF6 (included), ie I would completely ignore the values inside the second CBM data file. Additionally, I would make the trailer pattern mandatory (the first 9 bytes at least), even if the game doesn't rely on it. A check on that 0x04 value inside the trailer should be done too. Keep in mind that we want a safe scanner for those TAPs which are safe to clean, not a safe loader...

Gremlin's Fastload -----------------Used in: "Cybernoid" (from Zer0-X online archive), "Blood Brothers", "Deflektor", "Mask 2", "North Star", "Venom Strikes Back (Mask III)" (supplied by c64heaven). Structure : There are 2 complete CBM files. The first CBM file is loaded at $02A7, autoexecutes, loads a 2nd complete CBM file (which contains the Turbo Loader) at $0400 (video area), and executes it. The second CBM file has different names: "FASTLOAD" in "Deflektor", "Mask 2" and "Venom Strikes Back (Mask III)" (Header CRC32: 0x26768E85) "HELLO" in "Blood Brothers", "Cybernoid" and "North Star" (Header CRC32: 0xB3A82F14) Turbo blocks :

21 de 37

04/02/2013 04:15 p.m.

C64 Tape loaders

http://www.luigidifraia.com/c64/docs/tapeloaders.html

Threshold: 0x0350 (592) clock cycles (TAP value: 0x4A) Bit 0 pulse: 0x32 Bit 1 pulse: 0x63 Endianess: MSbF Pilot bit: Bit 1 pulses (size: 215 pulses about) Sync bit: a single Bit 0 pulse Header ----02 bytes: File ID ("01", "02", "03", etc.) 02 bytes: Load address (LSBF) 02 bytes: Data Size (LSBF) Data ---Last pulse is usually broken = not matching any of the given pulsewidths! Notes : Some pulses were found before the first turbo block pilot. They were used as separator: 7-8 Bit 1 pulses and 169 Bit 0 pulses. They must be kept.

Gremlin tape 1 -------------DOC Status: Released. Used in: "Avenger" (supplied by Peepo) and "Footballer of the Year" (supplied by BASICDave). Structure : After the boot CBM file, there is another CBM DATA block, loaded at $0400. Data files are partly encrypted and some decrypting is needed before executing the Main Loader. Turbo blocks : Threshold: 0x0180 (384) clock cycles (TAP value: 0x30). Bit 0 pulse: 0x22 Bit 1 pulse: 0x41 Endianess: LSbF Pilot byte: 0xE3 (size: 256 bytes) Sync byte: 0xED

22 de 37

04/02/2013 04:15 p.m.

C64 Tape loaders

http://www.luigidifraia.com/c64/docs/tapeloaders.html

Blocks are chained, each one has its own header, without pauses between them: Header -----1 byte: Block ID (descending, last one is 0x01) 2 bytes: Load Address (LSBF) 1 byte: Block Size (0x00=256, 0xFF=255, and so on) Data ---"Block Size" encrypted bytes. To decrypt them you have to XOR each read byte with a Decrypt byte. Decrypt byte is one from the Decrypt block (see ahead), starting from the first one and advancing by one byte at time. Then you have to XOR the resulting value with its destination address, LSB and MSB. When the last Decrypt byte has been used, restart from the first one. See example from "Krakout" in Gremlin tape 2. After all blocks comes: 1 byte: Checkbyte (XOR of all DECRYPTED data bytes with 0x00). Trailer: 256 Bit 1 pulses with last one being bigger. Complete Decrypt block (which is the loader itself with a programspecific execution vector at offset 2 and 4) "Avenger": 40 FC DD 20 20 00 00 FD C5 8D 8D DD F9 05 3C 60 EE 07 07 20 86 D0 FF FA 0D A9 85 48 33 A9 20 00 00 07 F8 02 D0 FF DC 01 F8 B5 00 10 D0 C9 85 00 45 E6 03 8D 8D 8D A9 03 08 2C 60 E3 FD C6 FE FE 4C FE 0D 05 19 48 A2 0D 20 F0 20 01 45 C6 CD FF DD DD 8D 60 08 DC 14 F9 07 A6 FD FB 00 A9 AD 4A 0E 20 F0 00 C9 00 F8 91 D0 EE 00 0D 8D DD 14 FB 66 ED 85 55 FD D6 20 8D DC 20 4C 00 4E FC D0 FE 02 45 C6 D0 FB AD D0 27 66 0D A5 EA 20 E8 FF FA 4C FF 0D 8D 00 FC DD FC 20 07 E0 85 D0 89 8D DD 20 E6 CA A9 C9 07 00 D6 FF BE 00 FF A9 D0 F9 D0 19 E3 00 85 D0 E6 20 78 FF 80 85 A6 F8 8D D0 85 FB 02 01 07 A9 A9 8D FF F9 A5 0E F5 FA A0 A2 E6 00 02 7F 04 85 B5

"Footballer Of The Year": 40 3C 00 00 0A A2 08 20 14 00 66 FC CA D0 F8 A5

23 de 37

04/02/2013 04:15 p.m.

C64 Tape loaders

http://www.luigidifraia.com/c64/docs/tapeloaders.html

FC DD 20 20 00 00 FD C5 8D 8D DD F9 05

60 EE 07 07 20 86 D0 FF FA 0D A9 85 48

A9 20 00 00 07 F8 02 D0 FF DC 01 F8 B5

10 D0 C9 85 00 45 E6 03 8D 8D 8D A9 03

2C 60 E3 FD C6 FE FE 4C FE 0D 05 19 48

0D 20 F0 20 01 45 C6 CD FF DD DD 8D 60

DC 14 F9 07 A6 FD FB 00 A9 AD 4A 0E

F0 00 C9 00 F8 91 D0 EE 00 0D 8D DD

FB 66 ED 85 55 FD D6 20 8D DC 20 4C

4E FC D0 FE 02 45 C6 D0 FB AD D0 27

0D A5 EA 20 E8 FF FA 4C FF 0D 8D 00

DD FC 20 07 E0 85 D0 89 8D DD 20 E6

A9 C9 07 00 D6 FF BE 00 FF A9 D0 F9

19 E3 00 85 D0 E6 20 78 FF 80 85 A6

8D D0 85 FB 02 01 07 A9 A9 8D FF F9

0E F5 FA A0 A2 E6 00 02 7F 04 85 B5

Gremlin tape 2 -------------DOC Status: Released. Used in: "Auf Wiedersehen Monty", "Bulldog" (from Gremlin's "10 Great Games", supplied by cip), "Krakout", "Pool", "Snooker", and "West Bank" (supplied by c64heaven). Structure : After the boot CBM file, there is another CBM DATA block, loaded at $0400. Data files are partly encrypted and some decrypting is needed before executing the Main Loader. Turbo blocks : Threshold: 0x0160 (352) clock cycles (TAP value: 0x2B). Bit 0 pulse: 0x1E Bit 1 pulse: 0x3C Endianess: LSbF Pilot byte: 0xE3 (size: 256 bytes) Sync byte: 0xED Blocks are chained, each one has its own header, without pauses between them: Header -----1 byte: Block ID (descending, last one is 0x01) 2 bytes: Load Address (LSBF) 1 byte: Block Size (0x00=256, 0xFF=255, and so on) Data ----

24 de 37

04/02/2013 04:15 p.m.

C64 Tape loaders

http://www.luigidifraia.com/c64/docs/tapeloaders.html

"Block Size" encrypted bytes. To decrypt them you have to XOR each read byte with a Decrypt byte. Decrypt byte is one from the Decrypt block (see ahead), starting from the first one and advancing by one byte at time. Then you have to XOR the resulting value with its destination address, LSB and MSB. When the last Decrypt byte has been used, restart from the first one. Example from "Krakout" (loads a $F6F9 bytes-long block at $0900):
Block ID 1st 2nd . . . last Load Addr (LSBF) Size Remainder 0x00 Data 0x00 Data . . . . . .

0xF7 0x00 0x09 0xF6 0x00 0x0A . . . . . .

0x01 0x00 0xFF

0xF9 Data

After all blocks come: 2 bytes: Execution address (LSBF), immediately executed if Checkbyte matches. 1 byte: Checkbyte (XOR of all DECRYPTED data bytes with 0x00). Trailer: 256 Bit 1 pulses with last one being bigger. Complete Decrypt blocks (which is the loader itself) "Auf Wiedersehen Monty": 78 FF 8D 8D 19 CA CA 20 45 0A CA 6C 08 DC A9 A2 0D 05 8D 00 00 CA 09 E6 00 03 20 F0 E7 43 DD DD 0E C9 85 00 45 08 85 00 D7 FB 8D 9A AD A9 DD E3 08 A6 08 D0 03 AD 00 4E FA AD 0D 00 20 F0 20 02 C6 02 20 20 66 0D FF FD DC 8D D7 F9 CA 55 01 E6 CA D0 07 DD 8D FF AD 20 00 C9 00 0B 91 09 00 18 CA A9 FE 48 0D D0 66 ED 85 E8 08 C6 85 69 D0 19 FF A2 DD 8D 07 D0 09 E0 E6 06 04 04 F8 8D A9 FF A9 11 A5 EA 20 DC 01 D0 20 8D A5 0E 00 9A 60 D0 07 20 CA D0 8D D3 CA 20 07 DD 8D A9 8D 85 C9 CA 00 02 20 C6 00 D0 60 60 FB 7F 04 0A E3 00 85 A2 D0 05 C5 4C A9 FF 8D DD 85 D0 85 06 00 45 D0 0A BE 10 8D 0D A9 02 F5 05 A0 86 0A BB D0 00 2C FF DC 01 A9 20 20 00 02 85 20 03 A2 0D

"Bulldog", "Krakout", etc.:

25 de 37

04/02/2013 04:15 p.m.

C64 Tape loaders

http://www.luigidifraia.com/c64/docs/tapeloaders.html

78 FF 60 85 D0 85 FB 00 FF B1 6C 08 DC

A9 A9 8D F6 F5 FA A0 86 E6 00 F7 20 F0

D1 7F 04 A9 20 20 00 F6 FD 85 00 BE FB

8D 8D DD 19 B1 B1 20 45 D0 F7 AD 00 4E

FA 0D A9 8D 00 00 B1 FE 02 20 20 66 0D

FF DC 01 0E C9 85 00 45 E6 B1 D0 FC DD

8D 8D 8D DD E3 FD A6 FD FE 00 18 CA A9

FE 0D 05 20 F0 20 F6 C6 C6 85 69 D0 19

FF DD DD BE F9 B1 55 01 FB F8 04 F8 8D

A9 AD A9 00 C9 00 02 91 D0 20 8D A5 0E

00 0D 00 66 ED 85 E8 FD D6 B1 20 FC DD

8D DC 8D FC D0 FE E0 E6 C6 00 D0 60 EE

FB AD 20 A5 EA 20 CF 01 FA C5 4C A9 20

FF 0D D0 FC 20 B1 D0 45 D0 FF A5 10 D0

8D DD 85 C9 B1 00 02 FF BE D0 00 2C 60

FF A9 FF E3 00 85 A2 85 20 03 A2 0D

Note: The mastering tool must have had some issues with timings because all dumps, even from different contributors, show the same scattered pattern, as per picture below:

Ocean New tape 1

26 de 37

04/02/2013 04:15 p.m.

C64 Tape loaders

http://www.luigidifraia.com/c64/docs/tapeloaders.html

---------------Used in: "Addams Family", "Adidas Soccer", "Cool World", "Darkman", "Hook", "Hudson Hawk", "Midnight Resistance", "SlySpy" and "WWF Wrestlemania" (supplied by c64heaven). Structure : It's a freeload-like loader with an addictional byte before turbo block's header. Turbo blocks : 2 pulsewidth sets were found so far:
Adidas Soccer, Hudson Hawk, Hook, Midnight Resistance 0x22 0x42 Addams Family, Cool World, Darkman, SlySpy, WWF Wrestlemania 0x35 0x65

Bit

0 1

Endianess: MSbF Pilot byte: 0x40 (size: 128 bytes = 1024 pulses) Sync byte: 0x5A Header -----01 byte : File ID, mostly ignored by some games 02 bytes: Load address (LSBF) 02 bytes: End address+1 (LSBF) Data 01 byte : XOR checksum of all data bytes Trailer: 1 longer pulse (e.g. 0x65) or 8 bits (variuos combinations were found) + 1 longer pulse (type 2).

Ocean New tape 2 ---------------Used in: "Klax" and "Shadow Warriors" but also in "Hero Quest", "Hero Quest Return of Witchlord" (supplied by c64heaven).

27 de 37

04/02/2013 04:15 p.m.

C64 Tape loaders

http://www.luigidifraia.com/c64/docs/tapeloaders.html

Structure : It's a freeload-like loader with an addictional byte in turbo block's header, after End address. Turbo blocks : Threshold: 0x0168 (360) clock cycles (TAP value: 0x2D) Bit 0 pulse: 0x22 Bit 1 pulse: 0x42 Endianess: MSbF Pilot byte: 0x40 (size: 128 bytes = 1024 pulses) Sync byte: 0x5A Header -----02 bytes: Load address (LSBF) 02 bytes: End address+1 (LSBF) 01 byte : File ID (not checked if searching for 0x00) Data 01 byte : XOR checksum of all data bytes Trailer: 1 longer pulse (e.g. 0x80).

Ocean New tape 3 ---------------Used in: "Night Breed" and "Run the Gauntlet" (supplied by c64heaven). Structure : There are 2 or 3 CBM files, the last one containing the loader (loads at $0800, up to $0CFE). This loader outputs read data to the audio channel. Turbo blocks : Threshold: 0x01B3 (435) clock cycles (TAP value: 0x36) Bit 0 pulse: 0x2E Bit 1 pulse: 0x49 Endianess: MSbF Turbo blocks are chained with no pauses between them. Pauses were found after every 16 turbo files. Pilot pulse : 0x80 (size: 64 pulses)

28 de 37

04/02/2013 04:15 p.m.

C64 Tape loaders

http://www.luigidifraia.com/c64/docs/tapeloaders.html

Sync

pulse: a single Bit 0 pulse

Header -----01 01 01 01

byte byte byte byte

: : : :

0x00 File ID 0x00 XOR Checksum of Data

Data (256 bytes) (last one in a chain may be padded with 0x00's)

New Hi-Tec/Titus/Krisalis tape -----------------------------Used in: "Jahangir Khan World Championship Squash (2 versions)", "Manchester United Europe", "The Blues Brothers" (Titus), "The Jetsons" (Hi-Tec), supplied by c64heaven. Structure : As Ocean New Tape 2, but with a bigger threshold. CBM Data CRC32 is often: 0x7E4A9653. Turbo blocks : Threshold: 0x01B0 (432) clock cycles (TAP value: 0x36) Even if using the same threshold, those games use different pulses:
Bit 0 1 The Blues Bros, The Jetsons MUE, JKWCS 0x29 0x52 0x26 0x4A

Atlantis tape ------------Used in: "Cavemania", "Hob Goblin", "Moontorc", "Killing Machine", "Spooky Castle", "Superkid in space" (supplied by c64heaven) and probably any other Atlantis release. Turbo blocks : Threshold: 0x0180 (384) clock cycles (TAP value: 0x2F) Bit 0 pulse: 0x1E

29 de 37

04/02/2013 04:15 p.m.

C64 Tape loaders

http://www.luigidifraia.com/c64/docs/tapeloaders.html

Bit 1 pulse: 0x40 Endianess: LSbF Pilot byte: 0x02 (size: 254 bytes) Sync couple (bytes): 0x52, 0x42 Header -----02 bytes: Execution address (MSBF) 02 bytes: End address+1 (MSBF) 02 bytes: Load address (MSBF) Data 01 byte : XOR checksum of all data bytes 01 byte : internal use Trailer: 7 bits + 1 longer pulse or 1 longer pulse (e.g. 0x51).

FF tape ------Used in: "Addicta Ball", "Bug Bomber", "Football Manager", "Gremlin Pool", "Gremlin Snooker", "Skateboard Joust", "Turbo 64" (supplied by c64heaven), and all games in "The Thriller Pack" (supplied by Peepo). Structure : The boot CBM file (Filename "FF"; HEADER CRC32: 0x0E527A8B, but in "Bug Bomber"; DATA loaded at $02C0-$0303, CRC32: 0xE356E438) contains the turbo loader, inside the the Data block code Load and End addresses of 2 turbo blocks are hardcoded: *=$02D7 LDA #$00 ; Start: $6000 STA $AC LDA #$60 STA $AD LDA #$00 ; End+1: $7400 STA $AE LDA #$74 STA $AF JSR $0359 ; Go load it LDA #$00 STA $AC LDA #$14 ; Start: $1400

30 de 37

04/02/2013 04:15 p.m.

C64 Tape loaders

http://www.luigidifraia.com/c64/docs/tapeloaders.html

STA LDA STA LDA STA JSR

$AD #$E0 ; End+1: $23E0 $AE #$23 $AF $0359 ; Go load it

The first 2 turbo blocks are loaded at: $6000-$7400, $1400-$23E0. The third turbo block loads at $2400. The fourth one loads at $1400-$2400. Turbo blocks : Threshold: 0x01A0 (416) clock cycles (TAP value: 0x34) Bit 0 pulse: 0x28 Bit 1 pulse: 0x3F Endianess: LSbF Pilot bit: Bit 0 pulses (size: 2064 pulses about) Sync bit: a single bit 1 pulse Additional Sync byte: 0xAA Data Trailer: Bit 0 pulses (x2031 about) + 1 longer pulse (e.g. 0x8F) Notes : This loader has the same encoding parameters as Cult.

Rack-it variant --------------Used in: "Scorpion" (RackIt/Hewson) (supplied by c64heaven) Structure: Same as Rack-it without any encrypt value in header. Turbo blocks: Threshold : 0x0160 (352) clock cycles (TAP value: 0x2C). Bit 0 pulse: 0x1D Bit 1 pulse: 0x3D Endianess : MSbF Pilot byte: 0x8F (size: about 218 found, even if very noisy at the beginning)

31 de 37

04/02/2013 04:15 p.m.

C64 Tape loaders

http://www.luigidifraia.com/c64/docs/tapeloaders.html

Sync

byte: 0x97

Header -----01 01 02 02 01 Data

byte : byte : bytes: bytes: byte :

Bank-value (stored at 0x01) XOR checksum of data bytes End Address+1 (MSBF) Start Address (MSBF) File ID

Trailer: 8 x Bit 1 pulses, last one being slightly bigger. Note: Last block loads at $FFFC, which is the execution address, executed at $0218 with a "JMP ($FFFC)".

Ash & Dave tape --------------Used in: "Robin Hood-Legend Quest", "Slicks", "Hot Rod", "Johnny Quest". Also used (with small differences) in "Dynamix" and "Poseidon Planet Eleven" (all tapes supplied by c64heaven). Turbo blocks: Threshold: 0x0168 (360) clock cycles (TAP value: 0x2D) Bit 0 pulse: 0x22 Bit 1 pulse: 0x44 Endianess: MSbF Pilot byte: 0x80 (size: 255 bytes) Sync byte: 0x40 Header -----01 byte : File ID (doesn't seem to be unique) 02 bytes: Load address (LSBF) 02 bytes: End address+1 (LSBF) Data Trailer ------A sequence of Bytes: 0x00 0x01 0x02 0x04 0x08 0x10 0x20 0x40 0x80

32 de 37

04/02/2013 04:15 p.m.

C64 Tape loaders

http://www.luigidifraia.com/c64/docs/tapeloaders.html

0x11 0x22 0x33 0x44 0x55 0x66 0x77 (last pulse of which is corrupted) Notes: Pilot size is shorter (128 bytes) in Hot Rod, which also misses a trailer. Due to this fact, the last data pulse before a pause is always corrupted, as it happens in Gremlin tapes. I would consider Hot Rod a non genuine one and make the trailer pattern mandatory (the first 15 bytes at least), even if the game doesn't rely on it. Keep in mind that we want a safe scanner for those TAPs which are safe to clean, not a safe loader...

Bleepload variant ----------------Used in: "Lord Of Chaos" and "Laser Squad" (supplied by c64heaven). Turbo blocks: Threshold: 0x0232 (562) clock cycles (Tap value: 0x46) Bit 0 pulse: 0x31 Bit 1 pulse: 0x5A Endianess: MSbF Leading pulse: Bit 1 (size: 2048 pulses) Pilot byte: pb (size: 10 bytes) (custom value) Sync byte 1: pb^0xFF Sync byte 2: pb Header -----02 bytes: Data Size - 1 (LSBF) Data 01 byte : XOR checksum of Header + Data Trailer: 2048 Bit 1 pulses Notes: It looks hard to find out the pb, but it's not. MSb of pb is NEVER 1, therefore, immediately after the Leading Train we find pb. Load address and pb for some of the first blocks are hardcoded in the loader. Anyway, the core load routine is at $9100 and to call it, the asm program sets:

33 de 37

04/02/2013 04:15 p.m.

C64 Tape loaders

http://www.luigidifraia.com/c64/docs/tapeloaders.html

x=Load address (LSB) y=Load address (MSB) a=pb Here there's an example: A2 A0 A9 20 00 50 0D 00 91 LDX LDY LDA JSR #$00 #$50 #$0D $9100 ; Load address ($5000) ; Pilot 0x0D

BITURBO (BY SC 85) -----------------DOC Status: Released. Used in: Some magazine tapes (Radio, Elettronica & Computer). Structure : After the addresses More than has to be Turbo blocks : Threshold: 0x0107 (263) clock cycles (TAP value: 0x21) Bit 0 pulse: 0x1B Bit 1 pulse: 0x27 Endianess: MSbF Pilot byte: 0x02 (size: 496 bytes) Sync train: 0x10, 0x0F, ... 0x01, 0x00 Data 01 byte : XOR checksum Trailer: Bit 0 pulses (x2040 about) Note: Hardcoded inside $02BA+$4B=$0305: $02BA+$5D=$0317: $02BA+$59=$0313: $02BA+$52=$030C: CBM Data block (loaded at $02BA): Load address (LSB) Load address (MSB) End address (LSB) End address (MSB) CBM boot file, there's just one turbo block. Load/End are hardcoded inside the CBM Data block. one file per tape uses this loader, so the right CBM part checked for extracting Load/End addresses.

34 de 37

04/02/2013 04:15 p.m.

C64 Tape loaders

http://www.luigidifraia.com/c64/docs/tapeloaders.html

Anirog tape (22/09-84) ---------------------Used in: "Slapshot" (Advantage Artworx - (C) Superior Quality Software). May be used in (as a variant): "Alice in Videoland", "Battle through Time", "Ghostchaser", "Linkword languages", "Space Pilot". Structure : CBM DATA CRC32: 0x05E3D02B. The message "DATE:22/09-84" was found in CBM HEADER. The first Turbo Block is a copy of the Main Loader which shows the "ANIROG" logo while it unpacks its code. The following turbo block is game data (decrypted after load). Unfortunately, Load and End addresses are hardcoded. Turbo blocks : Threshold: 0x0107 (263) clock cycles (TAP value: 0x21) Bit 0 pulse: 0x1B Bit 1 pulse: 0x29 Endianess: MSbF Pilot byte: 0x02 (size: ???) Sync train: 0x09 down to 0x01 Header -----01 byte : File ID. Any value, but 0x00. Data

Tequila Sunrise Tape -------------------DOC Status: Released. Used in: "Bongo", "Police Cadet", "Strip Poker II", "Thai Boxing", "Zodiac", and "Space Pilot" ((C) Kingsoft). Structure :

35 de 37

04/02/2013 04:15 p.m.

C64 Tape loaders

http://www.luigidifraia.com/c64/docs/tapeloaders.html

As it happens with Anirog tape, multiple copies of the game are stored on the same tape. CBM DATA CRC32: 0x737CE3A9. Code is encrypted. Each tape's mastering date can be found inside the CBM HEADER, together with some copyright info. The first turbo block loads at $FE00-$0002 and contains the following text: "XROM SYSTEM TEQUILA SUNRISE BELGIUM BRUSSELS 1984". Turbo blocks : Threshold: 0x0107 (263) clock cycles (TAP value: 0x21) Bit 0 pulse: 0x1A Bit 1 pulse: 0x28 Endianess: MSbF up to "File ID" byte included, LSbF for the rest Pilot byte: 0x02 (size: 247 bytes) Sync train: 0x09 down to 0x01 Header -----01 byte : File ID. Any value, but 0x00. 02 bytes: Load Address (LSBF) 02 bytes: End Address+1 (LSBF) Data 02 bytes: Execution address - 1 (MSBF <- take care!) Trailer: NONE found.

Fast Evil --------DOC Status: Released. Used in: "The Evil Dead". This is probably the fastest loader produced back in those days. Turbo blocks: Threshold: 0x00F0 (240) clock cycles (TAP value: 0x1E) Bit 0 pulse: 0x17 Bit 1 pulse: 0x21 Endianess: MSbF Pilot byte: 0x10 (size: 383 bytes)

36 de 37

04/02/2013 04:15 p.m.

C64 Tape loaders

http://www.luigidifraia.com/c64/docs/tapeloaders.html

Sync

byte: 0x20 (the loader does not check its value)

Header -----02 bytes: Load address (MSBF) 02 bytes: End address+1 (MSBF) 02 bytes: Jump address (MSBF) (unused by the loader) Data Trailer ------A MANDATORY sequence of Bytes: 0x00 0xFF 0xFE 0xFD down to 0x01 If any of those bytes is missing or corrupted, load will not complete. Additional information about loaders available at: http://www.geocities.com/SiliconValley/Platform/8224/c64tape/

37 de 37

04/02/2013 04:15 p.m.

Potrebbero piacerti anche