c64 tape loaders

37
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) C64 Tape loaders http://www.luigidifraia.com/c64/docs/tapeloaders.html 1 de 37 04/02/2013 04:15 p.m.

Upload: thierry-olmedo

Post on 14-Apr-2015

132 views

Category:

Documents


11 download

TRANSCRIPT

Page 1: C64 Tape Loaders

Loaders documented by Luigi Di Fraia

In an effort to make information about C64 commercial turbo loadersavailable, 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 AcesAlternative SoftwareAlternative Software (DK)AudiogenicBurner (Mastertronic variant)Cult tapeFreeload SlowloadOcean New tape 4ODEloadRainbow Arts tape (Microload variants)Tengen/Domark and Image Works tapeTrilogic v3.2Turbo tape 64FlashloadPower LoadSnakeload V5.0Snakeload V5.1Elder Gremlin tapeGremlin's FastloadGremlin tape 1Gremlin tape 2Ocean New tape 1Ocean New tape 2Ocean New tape 3New Hi-Tec/Titus/Krisalis tapeAtlantis tapeFF tapeRack-it variantAsh & Dave tapeBleepload variantBITURBO (BY SC 85)Anirog tape (22/09-84)Tequila Sunrise TapeFast Evil

Last Updated on: November 6, 2011

Accolade/EA (BY: J S EASTERBROOK)

C64 Tape loaders http://www.luigidifraia.com/c64/docs/tapeloaders.html

1 de 37 04/02/2013 04:15 p.m.

Page 2: C64 Tape Loaders

---------------------------------

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-InternationalGrand Prix Racing", "Grand Prix Circuit", "Jack Nicklaus Greatest 18Holes of Major Championship Golf", "PHM Pegasus", "Steel Thunder","Test Drive", "Test Drive 2" and "World Tour Golf" (supplied byc64heaven).

Structure :

After the CBM boot file, there is another CBM file that contains themain turbo loader.

Turbo blocks :

Threshold: 0x01EA (490) clock cycles (TAP value: 0x3D)Bit 0 pulse: 0x29Bit 1 pulse: 0x4AEndianess: MSbF

Pilot byte: 0x0F (size: 8 bytes)Sync byte: 0xAA

Header------

16 bytes: Filename02 bytes: Load address (LSBF)02 bytes: Data size (LSBF)01 byte : XOR Checksum of all Header bytes

Data----

Data is split in sub-blocks of 256 bytes each, or less for thelast 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 thesame pulsewidths, more or less. It's often used in EA releases (whosefirst CBM Data block CRC32 is sometimes 0xEA684D09).

C64 Tape loaders http://www.luigidifraia.com/c64/docs/tapeloaders.html

2 de 37 04/02/2013 04:15 p.m.

Page 3: C64 Tape Loaders

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 byoverwriting vector at $0326.

Turbo blocks :

Threshold: 0x0168 (360) clock cycles (TAP value: 0x2D)Bit 0 pulse: 0x22Bit 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 creditas the author of the Accolade/EA loader.

Alternative Software--------------------

DOC Status: Released.

C64 Tape loaders http://www.luigidifraia.com/c64/docs/tapeloaders.html

3 de 37 04/02/2013 04:15 p.m.

Page 4: C64 Tape Loaders

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 is0x823DBD1F. The turbo loader code is entirely inside the CBM Headerblock.

Turbo blocks :

Threshold: 0x02D0 (720) clock cycles (TAP value: 0x5A)Bit 0 pulse: 0x3DBit 1 pulse: 0x7EEndianess: LSbF

Pilot bit: 0x52 pulse (size: 0xA00 pulses)Sync bit: a single Bit 1 pulseAdditional sync train (bytes): 0x00, 0x00, 0x1A, 0xBB

Header------

01 byte : Ignored by loader02 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 thatare loaded consecutively in RAM have no long silence between them. CBMData CRC is 0x057A87A2. CBM files contain the string "DK".

Turbo blocks (Type 1 - used in Trap Door only):

C64 Tape loaders http://www.luigidifraia.com/c64/docs/tapeloaders.html

4 de 37 04/02/2013 04:15 p.m.

Page 5: C64 Tape Loaders

Bit Threshold: 0x0252 (594) clock cycles (TAP value: 0x4A)Pilot pulse Threshold: 0x047F (1151) clock cycles (TAP value: 0x90)Bit 0 pulse: 0x2BBit 1 pulse: 0x64Endianess: MSbF

Pilot: 0xB5 pulse repeated (size: 0x1F pulses - a minimum of 5 isexpected 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: 0x21Bit 1 pulse: 0x36Endianess: MSbF

Pilot: 0xA5 pulse repeated (size: 0x1F pulses - a minimum of 5 isexpected 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 loaderwill be executed again.This is often used to display a load picture and then carry onwith 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

C64 Tape loaders http://www.luigidifraia.com/c64/docs/tapeloaders.html

5 de 37 04/02/2013 04:15 p.m.

Page 6: C64 Tape Loaders

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: 0x1ABit 1 pulse: 0x36Endianess: 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 iscontained in the first turbo file, ALWAYS loaded at$CF00-$CFFF (ALWAYS the same code).There we find some messages and a custom print routine. Themessages read as follows: LOADING ERROR, PLEASE STOP THETAPE, PLEASE PRESS REWIND, PLEASE PRESS PLAY.0x00: restores the Default IRQ Routine and initializes CIAI/O Devices before executing a custom routine.0x02: it is the same as 0x00, but also restores RAM Vectorsfor Default I/O Routines.0x01: it's a re-initialization value. Sync is hunt for againif 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

C64 Tape loaders http://www.luigidifraia.com/c64/docs/tapeloaders.html

6 de 37 04/02/2013 04:15 p.m.

Page 7: C64 Tape Loaders

byte, whose value is 0x01.When no block follows, but a long pulse, this byte is usuallybroken (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/1pulses (a broken byte, to make the long story short). Then we have along pulse (pause).In a perfect world, each block would be followed by 8 pulses whichmake up a value of 0x01.Data blocks smaller than 256 bytes must be padded.For a deeper analisys of this loader's behaviour, check FabrizioGennari'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 additionalturbo blocks. CBM Header stores vital loader data. It's encrypted thesame way as legacy Burner. The XOR value is 0x59.

Turbo blocks :

Threshold: 0x0180 (384) clock cycles (TAP value: 0x30)Bit 0 pulse: 0x23Bit 1 pulse: 0x42Endianess: 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

C64 Tape loaders http://www.luigidifraia.com/c64/docs/tapeloaders.html

7 de 37 04/02/2013 04:15 p.m.

Page 8: C64 Tape Loaders

01 byte: EOF marker (when it's 0x00 it means end of a chain)

02 bytes: Execution address (LSBF) (dummy value until the EOF markeris 0x00)

02 bytes: Execution address repeated (last pulse of which is usuallybroken, so it's NOT mandatory)

Note:

Hardcoded inside CBM Header block:$033C+$87 or $89: Pilot byte$033C+$92 or $94: Sync byte$033C+$82 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 byc64heaven).

Structure :

A regular CBM part, whose CBM data CRC32 is always 0xF1D441D8. Thisdata 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: 0x27Bit 1 pulse: 0x3EEndianess: LSbF

Pilot bit: Bit 0 pulses (size: 2064 pulses about)Sync bit: a single Bit 1 pulseAdditional Sync byte: 0xAA

Data

Trailer: 2031 Bit 0 pulses + 1 Bit 1 pulse (possibly Bit 0 pulseshifted).

Note:

Hardcoded inside CBM Data block (loaded at $02E0):$02E0+$0A=$02EA: Load address (LSB)

C64 Tape loaders http://www.luigidifraia.com/c64/docs/tapeloaders.html

8 de 37 04/02/2013 04:15 p.m.

Page 9: C64 Tape Loaders

$02E0+$0E=$02EE: Load address (MSB)(You may also search for pattern: A9 ll 85 AC A9 mm 85 AD)

Hardcoded inside CBM Header block (loaded at $033C):$033C+$1B=$0357: End address+1 (LSB)$033C+$1F=$035B: End address+1 (MSB)(You may also search 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 isoften: 0x0AC328F5.

Turbo blocks :

Threshold: 0x0768 (1896) clock cycles (TAP value: 0x77)

Those games use pulses as per below:

Bit Pulse

0 0x5A

1 0x85

Ocean New tape 4----------------

DOC Status: Released.

Used in:

"Bart VS The Space Mutants", "Lethal Weapon", "Nick Faldo'sChampionship Golf", and "WWF European Rampage Tour" (supplied byc64heaven and cip).

A variant was found in:

"Outrun Europa" and "Liverpool". It doesn't use data padding at alland has a trailer made up of 7 bits + 1 longer pulse (e.g. 0x80).

C64 Tape loaders http://www.luigidifraia.com/c64/docs/tapeloaders.html

9 de 37 04/02/2013 04:15 p.m.

Page 10: C64 Tape Loaders

Structure :

Basically Freeload, with a different inner structure. CBM Data CRC32is often 0xB211DFED.

Turbo blocks :

Threshold: 0x0168 (360) clock cycles (TAP value: 0x2D)Bit 0 pulse: 0x24Bit 1 pulse: 0x44Endianess: MSbF

Pilot byte: 0x40 (size: 128 bytes = 1024 pulses)Sync byte: 0x5A

Header------

01 byte : File ID01 byte : XOR Checksum of Data (NOT checked by the loader)02 bytes: Load address (LSBF)02 bytes: End address+1 (LSBF)

Data----

Length is multiple of 256, so a block may be padded with zeroes ormemory 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.

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 (TVGames)".

Structure:

First character in CBM filename is: ">" (0x3E)CBM Data CRC32: 0xD5961DB0

Turbo blocks:

C64 Tape loaders http://www.luigidifraia.com/c64/docs/tapeloaders.html

10 de 37 04/02/2013 04:15 p.m.

Page 11: C64 Tape Loaders

Threshold: 0x01B0 (432) clock cycles (Tap value: 0x36)Bit 0 pulse: 0x25Bit 1 pulse: 0x50Endianess: 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 mayvary) and the string with loader's name which is sometimes shownduring 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) (suppliedby c64heaven).

Structure :

CBM Data CRC32 is sometimes 0xED3BB9E4.

Turbo blocks, type 1 :

Threshold: 0x014D (333) clock cycles (TAP value: 0x2A)Bit 0 pulse: 0x19Bit 1 pulse: 0x36Endianess: LSbF

Pilot byte: 0xA0 (size: 992 bytes, even if 867 were found too)

C64 Tape loaders http://www.luigidifraia.com/c64/docs/tapeloaders.html

11 de 37 04/02/2013 04:15 p.m.

Page 12: C64 Tape Loaders

Sync train: 0x0A, 0x09, ... , 0x01

Header------

01 byte : File ID02 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: 0x19Bit 1 pulse: 0x36Endianess: LSbF

Pilot byte: 0xA0 (size: 852 bytes)Sync train: 0x0B, 0x0A, 0x09, ... , 0x01

Header------

03 bytes: File name02 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 andCrossbones" [Multiloaded], "Pit Fighter" [Multiloaded], "Badlands","Rampart" [Multiloaded], "Rugby the World Cup" [Multiloaded], "The Spywho loved me" [Multiloaded], (thanks to c64heaven for those last 4taps and "3DCK") and probably a lot of other TENGEN/DOMARK Releases.

C64 Tape loaders http://www.luigidifraia.com/c64/docs/tapeloaders.html

12 de 37 04/02/2013 04:15 p.m.

Page 13: C64 Tape Loaders

Structure :

There are 2 complete CBM files. The first CBM file (DATA size: 2 -two-bytes, Loads at $029F: 51 03, CRC32: 0x848FD0AF) autoexecutes, loads a2nd complete CBM file (which contains the Turbo Loader) and executesit.Autostarting ROM cartridges are disabled.

Turbo blocks :

Threshold: 0x029F ??? (671) clock cycles (TAP value: 0x54)Bit 0 pulse: 0x44Bit 1 pulse: 0x65Endianess: LSbF

Pilot byte: 0xA0 (size: 255 bytes, but a pulse is often missing in thebeginning)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 trailerfollows, so that it's NOT mandatory)

Trailer: Often missing in Type 1 blocks. It is usually made up of 7Bit 0 pulses followed by a bigger pulse (e.g. 0x76-0x82).

C64 Tape loaders http://www.luigidifraia.com/c64/docs/tapeloaders.html

13 de 37 04/02/2013 04:15 p.m.

Page 14: C64 Tape Loaders

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", "StrikeForce", "Superted" (supplied by c64heaven).

Structure :

CBM Data CRC32: 0x848FD0AF.

Turbo blocks :

Threshold: 0x0141 (321) clock cycles (TAP value: 0x28)Bit 0 pulse: 0x1CBit 1 pulse: 0x35Endianess: 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 : CheckbyteAddition 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

C64 Tape loaders http://www.luigidifraia.com/c64/docs/tapeloaders.html

14 de 37 04/02/2013 04:15 p.m.

Page 15: C64 Tape Loaders

-------------

DOC Status: Released.

Used in:

A lot of older releases, among which: "China Miner", "Great GianaSisters, The", "To be on Top".

Structure :

Each turbo file is made of a HEADER section and a DATA one, withoutgaps between them.

Turbo blocks :

Threshold: 0x0107 (263) clock cycles (TAP value: 0x21)Bit 0 pulse: 0x1ABit 1 pulse: 0x28Endianess: MSbF

Pilot byte: 0x02 (size: the genuine tape mastering program saves256*4+247 of them for HEADER and 256+247 for DATA)Sync train: 0x09, 0x08, ... 0x01

01 byte: File type

0x00 for DATA0x01 (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 saving187 bytes: Filename, padded with 0x20

Data file---------

n bytes : Data 01 byte : CheckbyteXOR Checksum of Data

Trailer: After the DATA file a trailer follows, made up of bytes whosevalue is $00. The genuine Tape Mastering program saves 255 of them.

Notes:

This is the "TURBO TAPE 64" format, written by Stephan Senz Freiburgin 1983.The loader description is based on previously available documents but

C64 Tape loaders http://www.luigidifraia.com/c64/docs/tapeloaders.html

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

Page 16: C64 Tape Loaders

it was reviewed by looking at the tape mastering tool.Section type is determined by the (optional) secondary address used tosave the file to tape:

<-S "PROGRAM NAME"[,1,secondary address]

A secondary address of zero (or any even number) means relocatablefile, any odd number means non-relocatable. In other words, a non-zerovalue of Section type equals secondary address + 1.Pilot + sync bytes make up a block of 256*5 bytes for HEADER and 256*2for DATA.Header hasn't got any XOR checksum.If the file name is longer than 16 characters, the excess will betruncated by the SEARCHING and FOUND messages, but will still bepresent 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 CountryRoad 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) anddisk 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: 0x31Endianess: MSbF

Pilot bit: Bit 1 pulses (size: 2048 pulses about)Sync bit: a single Bit 0 pulseAdditional Sync byte: 0x33

Header------

02 bytes: Load address (LSBF)02 bytes: End address (LSBF)

Data

01 byte : XOR Checksum of Data

C64 Tape loaders http://www.luigidifraia.com/c64/docs/tapeloaders.html

16 de 37 04/02/2013 04:15 p.m.

Page 17: C64 Tape Loaders

Notes:

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

Power Load----------

Used in:

"Felix in the factory", "Ghouls", "Jet Power Jack" - probably anyother "Micro Power, Tynesoft" release -, and "Stock Car" (supplied bycip 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 theneeded load information is stored (e.g. Load Address, see Noteslater).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 "BuilderBen" (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: 0x1CBit 1 pulse: 0x29Endianess: 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 additionalbytes

Trailer: 2048 Bit 0 pulses about

Notes:

Load Address is at: $CE48 (LSB)/$CE4A (MSB)

C64 Tape loaders http://www.luigidifraia.com/c64/docs/tapeloaders.html

17 de 37 04/02/2013 04:15 p.m.

Page 18: C64 Tape Loaders

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 commonpattern, they can be extracted easily from both versions with a commonmethod.Power Load-er doesn't read and check the checksum byte, but a checksumbyte is present and just after data block.

Snakeload V5.0--------------

Used in:

"Soldier of Light" (under check), "Shinobi", "Saint Dragon", "NinjaWarriors", "Narc" (these last two were supplied by c64heaven) andprobably 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 TOBE PROTECTEDSO DON'T THINK YOU ARE GOOD FOR CRACKING IT !!!KYLIE RULES!

Turbo blocks :

2 pulsewidth sets were found so far:

Bit Shinobi,

Ninja WarriorsSaint Dragon,

Narc

0 0x60 0x3F

1 0xA0 0x5F

Th 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 ID02 bytes: Load address (LSBF)

C64 Tape loaders http://www.luigidifraia.com/c64/docs/tapeloaders.html

18 de 37 04/02/2013 04:15 p.m.

Page 19: C64 Tape Loaders

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 "NinjaWarriors"

Snakeload V5.1--------------

Used in:

"Final Blow", "Rodland", "SWIV" (supplied by c64heaven) "Double Dragon3", "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: 0x28Bit 1 pulse: 0x48Endianess: 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 andreversed) in "Final Blow", "Rod Land (Side1)"85 8C 8C 85 88 83 89 8D ("MICHELLE " - Lowercase andreversed) in "S.W.I.V. (Side1)"C8 C3 D4 C9 D2 C4 CC C5 ("ELDRITCH " - Uppercase andreversed) in "Rod Land (Side2)", "Double Dragon 3", "IndyHeat"

01 byte : File ID02 bytes: End address+1 (MSBF)02 bytes: Load address (MSBF)

Data

C64 Tape loaders http://www.luigidifraia.com/c64/docs/tapeloaders.html

19 de 37 04/02/2013 04:15 p.m.

Page 20: C64 Tape Loaders

01 byte : ChecksumIts value is calculated by XORing Data bytes and adding 1 to theXOR checksum AFTER a byte is stored at an address with LSB being0xFF (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 InternationalFootball" 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 2ndcomplete CBM file (which contains the Turbo Loader) at $0400 (videoarea) 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: 0x40Bit 1 pulse: 0x70Endianess: MSbF

Sync byte: 0xF0

Data

Trailer:Usually a pattern made up of 79-80 bit 1 and bit 0 pulses.Here the patterns I found so far:

Blasteroids: F7F7: F7 B9 FF A6 04 3F B9 BD 21 [incompletebyte]PBIF : F7F7: 00 00 00 A6 04 00 00 00 00 2ETB Part 1 : F7F7: 00 00 00 AE 04 00 00 00 FF 2ETB Part 2 : F7F7: 00 00 00 AE 04 00 00 00 FF [incompletebyte]TB Part 3 : F7F7: 00 00 00 AE 04 00 00 00 FF 2ETB Part 4 : F7F7: 00 00 00 AE 04 00 00 00 FF [incompletebyte]Xybots : F7F7: 00 00 00 A6 04 00 00 00 FF [incomplete

C64 Tape loaders http://www.luigidifraia.com/c64/docs/tapeloaders.html

20 de 37 04/02/2013 04:15 p.m.

Page 21: C64 Tape Loaders

byte]

I would say that this pattern should be present in legacy tapesand that the 0x04 value should always be at offset 0x05.When Trailer is missing (as in Deathwish 3), the last pulse isbroken = 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 aplausibility check when seeking this type of files). Load address isusually $0800, but in Deathwish 3.Due to these anomalties in Deathwish 3 I would say it's a non-genuineElder Gremlin tape.

That said, I would only consider genuine Elder Gremlin files thosethat are loaded at $0800-$FFF6 (included), ie I would completelyignore the values inside the second CBM data file. Additionally, Iwould make the trailer pattern mandatory (the first 9 bytes atleast), even if the game doesn't rely on it. A check on that 0x04value inside the trailer should be done too.Keep in mind that we want a safe scanner for those TAPs which are safeto 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 TurboLoader) at $0400 (video area), and executes it.The second CBM file has different names:

"FASTLOAD" in "Deflektor", "Mask 2" and "Venom Strikes Back (MaskIII)" (Header CRC32: 0x26768E85)"HELLO" in "Blood Brothers", "Cybernoid" and "North Star" (HeaderCRC32: 0xB3A82F14)

Turbo blocks :

C64 Tape loaders http://www.luigidifraia.com/c64/docs/tapeloaders.html

21 de 37 04/02/2013 04:15 p.m.

Page 22: C64 Tape Loaders

Threshold: 0x0350 (592) clock cycles (TAP value: 0x4A)Bit 0 pulse: 0x32Bit 1 pulse: 0x63Endianess: 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 givenpulsewidths!

Notes:

Some pulses were found before the first turbo block pilot. They wereused as separator: 7-8 Bit 1 pulses and 169 Bit 0 pulses. They must bekept.

Gremlin tape 1--------------

DOC Status: Released.

Used in:

"Avenger" (supplied by Peepo) and "Footballer of the Year" (suppliedby 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 neededbefore executing the Main Loader.

Turbo blocks :

Threshold: 0x0180 (384) clock cycles (TAP value: 0x30).Bit 0 pulse: 0x22Bit 1 pulse: 0x41Endianess: LSbF

Pilot byte: 0xE3 (size: 256 bytes)Sync byte: 0xED

C64 Tape loaders http://www.luigidifraia.com/c64/docs/tapeloaders.html

22 de 37 04/02/2013 04:15 p.m.

Page 23: C64 Tape Loaders

Blocks are chained, each one has its own header, without pausesbetween 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 Decryptbyte. 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 destinationaddress, LSB and MSB.When the last Decrypt byte has been used, restart from the firstone.

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 program-specific execution vector at offset 2 and 4)

"Avenger":

40 3C 33 00 08 A2 08 20 14 00 66 FC CA D0 F8 A5FC 60 A9 10 2C 0D DC F0 FB 4E 0D DD A9 19 8D 0EDD EE 20 D0 60 20 14 00 66 FC A5 FC C9 E3 D0 F520 07 00 C9 E3 F0 F9 C9 ED D0 EA 20 07 00 85 FA20 07 00 85 FD 20 07 00 85 FE 20 07 00 85 FB A000 20 07 00 C6 01 A6 F8 55 02 E8 E0 D6 D0 02 A200 86 F8 45 FE 45 FD 91 FD 45 FF 85 FF E6 01 E6FD D0 02 E6 FE C6 FB D0 D6 C6 FA D0 BE 20 07 00C5 FF D0 03 4C CD 00 EE 20 D0 4C 89 00 78 A9 028D FA FF 8D FE FF A9 00 8D FB FF 8D FF FF A9 7F8D 0D DC 8D 0D DD AD 0D DC AD 0D DD A9 80 8D 04DD A9 01 8D 05 DD 4A 8D 20 D0 8D 20 D0 85 FF 85F9 85 F8 A9 19 8D 0E DD 4C 27 00 E6 F9 A6 F9 B505 48 B5 03 48 60

"Footballer Of The Year":

40 3C 00 00 0A A2 08 20 14 00 66 FC CA D0 F8 A5

C64 Tape loaders http://www.luigidifraia.com/c64/docs/tapeloaders.html

23 de 37 04/02/2013 04:15 p.m.

Page 24: C64 Tape Loaders

FC 60 A9 10 2C 0D DC F0 FB 4E 0D DD A9 19 8D 0EDD EE 20 D0 60 20 14 00 66 FC A5 FC C9 E3 D0 F520 07 00 C9 E3 F0 F9 C9 ED D0 EA 20 07 00 85 FA20 07 00 85 FD 20 07 00 85 FE 20 07 00 85 FB A000 20 07 00 C6 01 A6 F8 55 02 E8 E0 D6 D0 02 A200 86 F8 45 FE 45 FD 91 FD 45 FF 85 FF E6 01 E6FD D0 02 E6 FE C6 FB D0 D6 C6 FA D0 BE 20 07 00C5 FF D0 03 4C CD 00 EE 20 D0 4C 89 00 78 A9 028D FA FF 8D FE FF A9 00 8D FB FF 8D FF FF A9 7F8D 0D DC 8D 0D DD AD 0D DC AD 0D DD A9 80 8D 04DD A9 01 8D 05 DD 4A 8D 20 D0 8D 20 D0 85 FF 85F9 85 F8 A9 19 8D 0E DD 4C 27 00 E6 F9 A6 F9 B505 48 B5 03 48 60

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 neededbefore executing the Main Loader.

Turbo blocks :

Threshold: 0x0160 (352) clock cycles (TAP value: 0x2B).Bit 0 pulse: 0x1EBit 1 pulse: 0x3CEndianess: LSbF

Pilot byte: 0xE3 (size: 256 bytes)Sync byte: 0xED

Blocks are chained, each one has its own header, without pausesbetween 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----

C64 Tape loaders http://www.luigidifraia.com/c64/docs/tapeloaders.html

24 de 37 04/02/2013 04:15 p.m.

Page 25: C64 Tape Loaders

"Block Size" encrypted bytes.

To decrypt them you have to XOR each read byte with a Decryptbyte. 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 destinationaddress, LSB and MSB.When the last Decrypt byte has been used, restart from the firstone.

Example from "Krakout" (loads a $F6F9 bytes-long block at $0900):

Block ID Load Addr (LSBF) Size Remainder

1st 0xF7 0x00 0x09 0x00 Data

2nd 0xF6 0x00 0x0A 0x00 Data

. . . . .

. . . . .

. . . . .

last 0x01 0x00 0xFF 0xF9 Data

After all blocks come:

2 bytes: Execution address (LSBF), immediately executed ifCheckbyte 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 A9 E7 8D FA FF 8D FE FF A9 00 8D FB FF 8D FFFF A2 43 9A AD FD FF 48 A2 FF 9A A9 7F 8D 0D DC8D 0D DD AD 0D DC AD 0D DD A9 60 8D 04 DD A9 018D 05 DD A9 00 8D 20 D0 8D 11 D0 85 0A 85 02 A919 8D 0E DD 20 D7 00 66 07 A5 07 C9 E3 D0 F5 20CA 00 C9 E3 F0 F9 C9 ED D0 EA 20 CA 00 85 05 20CA 00 85 08 20 CA 00 85 09 20 CA 00 85 06 A0 0020 CA 00 A6 02 55 0B E8 E0 DC D0 02 A2 00 86 0245 09 45 08 C6 01 91 08 E6 01 8D 20 D0 45 0A 850A E6 08 D0 02 E6 09 C6 06 D0 D3 C6 05 D0 BB 20CA 00 85 03 20 CA 00 85 04 20 CA 00 C5 0A D0 036C 03 00 AD 20 D0 18 69 04 8D 20 D0 4C BE 00 A208 20 D7 00 66 07 CA D0 F8 A5 07 60 A9 10 2C 0DDC F0 FB 4E 0D DD A9 19 8D 0E DD 60

"Bulldog", "Krakout", etc.:

C64 Tape loaders http://www.luigidifraia.com/c64/docs/tapeloaders.html

25 de 37 04/02/2013 04:15 p.m.

Page 26: C64 Tape Loaders

78 A9 D1 8D FA FF 8D FE FF A9 00 8D FB FF 8D FFFF A9 7F 8D 0D DC 8D 0D DD AD 0D DC AD 0D DD A960 8D 04 DD A9 01 8D 05 DD A9 00 8D 20 D0 85 FF85 F6 A9 19 8D 0E DD 20 BE 00 66 FC A5 FC C9 E3D0 F5 20 B1 00 C9 E3 F0 F9 C9 ED D0 EA 20 B1 0085 FA 20 B1 00 85 FD 20 B1 00 85 FE 20 B1 00 85FB A0 00 20 B1 00 A6 F6 55 02 E8 E0 CF D0 02 A200 86 F6 45 FE 45 FD C6 01 91 FD E6 01 45 FF 85FF E6 FD D0 02 E6 FE C6 FB D0 D6 C6 FA D0 BE 20B1 00 85 F7 20 B1 00 85 F8 20 B1 00 C5 FF D0 036C F7 00 AD 20 D0 18 69 04 8D 20 D0 4C A5 00 A208 20 BE 00 66 FC CA D0 F8 A5 FC 60 A9 10 2C 0DDC F0 FB 4E 0D DD A9 19 8D 0E DD EE 20 D0 60

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

Ocean New tape 1

C64 Tape loaders http://www.luigidifraia.com/c64/docs/tapeloaders.html

26 de 37 04/02/2013 04:15 p.m.

Page 27: C64 Tape Loaders

----------------

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 turboblock's header.

Turbo blocks :

2 pulsewidth sets were found so far:

Bit

Adidas Soccer,Hudson Hawk,

Hook,Midnight Resistance

Addams Family,Cool World,Darkman,SlySpy,

WWF Wrestlemania

0 0x22 0x35

1 0x42 0x65

Endianess: MSbF

Pilot byte: 0x40 (size: 128 bytes = 1024 pulses)Sync byte: 0x5A

Header------

01 byte : File ID, mostly ignored by some games02 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 combinationswere found) + 1 longer pulse (type 2).

Ocean New tape 2----------------

Used in:

"Klax" and "Shadow Warriors" but also in "Hero Quest", "Hero QuestReturn of Witchlord" (supplied by c64heaven).

C64 Tape loaders http://www.luigidifraia.com/c64/docs/tapeloaders.html

27 de 37 04/02/2013 04:15 p.m.

Page 28: C64 Tape Loaders

Structure :

It's a freeload-like loader with an addictional byte in turbo block'sheader, after End address.

Turbo blocks :

Threshold: 0x0168 (360) clock cycles (TAP value: 0x2D)Bit 0 pulse: 0x22Bit 1 pulse: 0x42Endianess: 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 (loadsat $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: 0x2EBit 1 pulse: 0x49Endianess: MSbF

Turbo blocks are chained with no pauses between them. Pauses werefound after every 16 turbo files.

Pilot pulse: 0x80 (size: 64 pulses)

C64 Tape loaders http://www.luigidifraia.com/c64/docs/tapeloaders.html

28 de 37 04/02/2013 04:15 p.m.

Page 29: C64 Tape Loaders

Sync pulse: a single Bit 0 pulse

Header------

01 byte : 0x0001 byte : File ID01 byte : 0x0001 byte : 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)", "ManchesterUnited 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 isoften: 0x7E4A9653.

Turbo blocks :

Threshold: 0x01B0 (432) clock cycles (TAP value: 0x36)

Even if using the same threshold, those games use different pulses:

Bit The Blues Bros,

MUE, JKWCSThe Jetsons

0 0x29 0x26

1 0x52 0x4A

Atlantis tape-------------

Used in:

"Cavemania", "Hob Goblin", "Moontorc", "Killing Machine", "SpookyCastle", "Superkid in space" (supplied by c64heaven) and probably anyother Atlantis release.

Turbo blocks :

Threshold: 0x0180 (384) clock cycles (TAP value: 0x2F)Bit 0 pulse: 0x1E

C64 Tape loaders http://www.luigidifraia.com/c64/docs/tapeloaders.html

29 de 37 04/02/2013 04:15 p.m.

Page 30: C64 Tape Loaders

Bit 1 pulse: 0x40Endianess: 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 byc64heaven), 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) containsthe turbo loader, inside the the Data block code Load and Endaddresses of 2 turbo blocks are hardcoded:

*=$02D7LDA #$00 ; Start: $6000STA $ACLDA #$60STA $ADLDA #$00 ; End+1: $7400STA $AELDA #$74STA $AFJSR $0359 ; Go load it

LDA #$00 ; Start: $1400STA $ACLDA #$14

C64 Tape loaders http://www.luigidifraia.com/c64/docs/tapeloaders.html

30 de 37 04/02/2013 04:15 p.m.

Page 31: C64 Tape Loaders

STA $ADLDA #$E0 ; End+1: $23E0STA $AELDA #$23STA $AFJSR $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: 0x28Bit 1 pulse: 0x3FEndianess: LSbF

Pilot bit: Bit 0 pulses (size: 2064 pulses about)Sync bit: a single bit 1 pulseAdditional 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: 0x1DBit 1 pulse: 0x3DEndianess : MSbF

Pilot byte: 0x8F (size: about 218 found, even if very noisy at thebeginning)

C64 Tape loaders http://www.luigidifraia.com/c64/docs/tapeloaders.html

31 de 37 04/02/2013 04:15 p.m.

Page 32: C64 Tape Loaders

Sync byte: 0x97

Header------

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

Data

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 PlanetEleven" (all tapes supplied by c64heaven).

Turbo blocks:

Threshold: 0x0168 (360) clock cycles (TAP value: 0x2D)Bit 0 pulse: 0x22Bit 1 pulse: 0x44Endianess: 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

C64 Tape loaders http://www.luigidifraia.com/c64/docs/tapeloaders.html

32 de 37 04/02/2013 04:15 p.m.

Page 33: C64 Tape Loaders

0x11 0x22 0x33 0x44 0x55 0x66 0x77 (last pulse of which iscorrupted)

Notes:

Pilot size is shorter (128 bytes) in Hot Rod, which also misses atrailer. Due to this fact, the last data pulse before a pause isalways corrupted, as it happens in Gremlin tapes.

I would consider Hot Rod a non genuine one and make the trailerpattern mandatory (the first 15 bytes at least), even if the gamedoesn't rely on it.Keep in mind that we want a safe scanner for those TAPs which are safeto 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: 0x31Bit 1 pulse: 0x5AEndianess: MSbF

Leading pulse: Bit 1 (size: 2048 pulses)Pilot byte: pb (size: 10 bytes) (custom value)Sync byte 1: pb^0xFFSync 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 theloader. Anyway, the core load routine is at $9100 and to call it, theasm program sets:

C64 Tape loaders http://www.luigidifraia.com/c64/docs/tapeloaders.html

33 de 37 04/02/2013 04:15 p.m.

Page 34: C64 Tape Loaders

x=Load address (LSB)y=Load address (MSB)a=pb

Here there's an example:

A2 00 LDX #$00 ; Load address ($5000)A0 50 LDY #$50A9 0D LDA #$0D ; Pilot 0x0D20 00 91 JSR $9100

BITURBO (BY SC 85)------------------

DOC Status: Released.

Used in:

Some magazine tapes (Radio, Elettronica & Computer).

Structure :

After the CBM boot file, there's just one turbo block. Load/Endaddresses are hardcoded inside the CBM Data block.More than one file per tape uses this loader, so the right CBM parthas to be checked for extracting Load/End addresses.

Turbo blocks :

Threshold: 0x0107 (263) clock cycles (TAP value: 0x21)Bit 0 pulse: 0x1BBit 1 pulse: 0x27Endianess: 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 CBM Data block (loaded at $02BA):$02BA+$4B=$0305: Load address (LSB)$02BA+$5D=$0317: Load address (MSB)$02BA+$59=$0313: End address (LSB)$02BA+$52=$030C: End address (MSB)

C64 Tape loaders http://www.luigidifraia.com/c64/docs/tapeloaders.html

34 de 37 04/02/2013 04:15 p.m.

Page 35: C64 Tape Loaders

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", "Linkwordlanguages", "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 isgame data (decrypted after load). Unfortunately, Load and Endaddresses are hardcoded.

Turbo blocks :

Threshold: 0x0107 (263) clock cycles (TAP value: 0x21)Bit 0 pulse: 0x1BBit 1 pulse: 0x29Endianess: 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 :

C64 Tape loaders http://www.luigidifraia.com/c64/docs/tapeloaders.html

35 de 37 04/02/2013 04:15 p.m.

Page 36: C64 Tape Loaders

As it happens with Anirog tape, multiple copies of the game are storedon 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 followingtext: "XROM SYSTEM TEQUILA SUNRISE BELGIUM BRUSSELS 1984".

Turbo blocks :

Threshold: 0x0107 (263) clock cycles (TAP value: 0x21)Bit 0 pulse: 0x1ABit 1 pulse: 0x28Endianess: 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: 0x17Bit 1 pulse: 0x21Endianess: MSbF

Pilot byte: 0x10 (size: 383 bytes)

C64 Tape loaders http://www.luigidifraia.com/c64/docs/tapeloaders.html

36 de 37 04/02/2013 04:15 p.m.

Page 37: C64 Tape Loaders

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 0x01If any of those bytes is missing or corrupted, load will notcomplete.

Additional information about loaders available at:

http://www.geocities.com/SiliconValley/Platform/8224/c64tape/

C64 Tape loaders http://www.luigidifraia.com/c64/docs/tapeloaders.html

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