Page 1 of 2

Help Rescuing Tapes

Posted: Tue Jan 19, 2010 9:32 am
by ga5ket
I've managed to rescue quite a few dodgy tapes that I've got by rerecording them using wavs from the archives, but there are 4 that have totally stumped me:
Ket Trilogy, Return of the Ring, Nightflight and St. George and the Dragons.
I've tried to convert the cas files using dc, when a wav doesn't exist, but in most cases the resultant wav fails to load, even in xroar. If anyone could provide some insight (or even shiny new wav files!) I'd much appreciate it.

Re: Help Rescuing Tapes

Posted: Tue Jan 19, 2010 1:14 pm
by sixxie
I've rewritten CAS files for all of those here:

http://www.6809.org.uk/tmp/da/rewrites/

Not sure why the St. George and the Dragons WAV didn't work for you on a real machine, but maybe you'll have more luck converting these?

Re: Help Rescuing Tapes

Posted: Tue Jan 19, 2010 3:38 pm
by ga5ket
Thanks, that's everything fixed and working.
Out of curiosity how did you fix them?

Re: Help Rescuing Tapes

Posted: Tue Jan 19, 2010 7:40 pm
by sixxie
With the XRoar 'tapehack' patch. I've just rolled this into the main tree (so future releases should have it built-in) and generated a snapshot, so you can play with this yourself:

Source code

Windows binary

Basically, when run with the "-tapehack" command line option, anything read in on the input cassette file is rewritten to the output cassette file. While doing so, it tries to maintain byte sync (so the CAS files remain "readable") and inserts extra leaders where appropriate.

So, run with "-tapehack" on the command line, use Ctrl+L to attach a tape, press Ctrl+W to give a .cas filename to write to, then load the game. Any bytes read in while loading should be written out to the file you specify.

Input can be CAS, ASC/BAS or audio files. Output can only be CAS files at the moment. Be aware that as it is, it won't work for *everything* (really special loaders will cause issues), but most things are ok.

And actually, it doesn't quite work for Return of the Ring either - that needs some extra leader bytes inserting, as its loader turns the motor on and then waits long enough that the default leader isn't quite long enough. But that's rare.

Re: Help Rescuing Tapes

Posted: Tue Jan 19, 2010 8:10 pm
by ga5ket
Oh, that's cool. I'll give that a go! Thanks :D

Re: Help Rescuing Tapes

Posted: Thu Jan 21, 2010 12:55 am
by Alastair
ga5ket wrote:I've managed to rescue quite a few dodgy tapes that I've got by rerecording them using wavs from the archives, but there are 4 that have totally stumped me:
Ket Trilogy, Return of the Ring, Nightflight and St. George and the Dragons.
I've tried to convert the cas files using dc, when a wav doesn't exist, but in most cases the resultant wav fails to load, even in xroar. If anyone could provide some insight (or even shiny new wav files!) I'd much appreciate it.
I created the the Ket Trilogy CAS file and and did note that T3 displayed the error "Illegal Opcode $42 at $7F92" when playing the game. I think I created several Ket CAS files, all conversions giving the same error, so as the three games can all be completed when the emulator is instructed to ignore all op code errors I put the following in the accompanying text file:

Loading Instructions:
(Change emulator to ignore all op code errors.)
CLOADM
(Autoruns)

I haven't tested the CAS files with XRoar or reconverted them back to wave files, so given the above I wonder if the Ket Trilogy uses a non-standard tape format.

Re: Help Rescuing Tapes

Posted: Thu Jan 21, 2010 9:47 am
by admin
It does use a custom autoloader that traps I/O Errors so it may be doing something silly..... As all 3 are written in BASIC with a DATA file for the adventure it should be possible to produce a version without the autoloader if these really won't work.

Re: Help Rescuing Tapes

Posted: Thu Jan 21, 2010 6:41 pm
by zephyr
Here's my own patched version which fixes the 'illegal opcode' problem. All included cassette files have also been run through the Xroar 'tapemangle' process.

ENJOY! :)

Regards,
Steve

Re: Help Rescuing Tapes

Posted: Thu Jan 21, 2010 11:47 pm
by Alastair
I'd just like to point out that I have now tested the archive's copy of the Ket trilogy with XRoar and have found no problems, not even a mention of any op code error.

However reconverting these CAS files back into wave files with DC does cause a problem, so for the time being Ciaran's wave conversion seems the best bet.

Re: Help Rescuing Tapes

Posted: Fri Jan 22, 2010 12:41 am
by zephyr
Alastair wrote:I'd just like to point out that I have now tested the archive's copy of the Ket trilogy with XRoar and have found no problems, not even a mention of any op code error.
By default Xroar doesn't report illegal op codes. :?
Alastair wrote:However reconverting these CAS files back into wave files with DC does cause a problem, so for the time being Ciaran's wave conversion seems the best bet.
Surely my patched version is the best bet? You are getting the 100% original game without the illegal op code bug.