<< Previous Message Main Index Next Message >>
<< Previous Message in Thread This Month Next Message in Thread >>
Date   : Wed, 19 Oct 1994 08:55:22 -0600
From   : barnett@... (David Barnett)
Subject: Re: BBC: Disk Handling

Chris L. Rae Wrote:
>
>My gut feeling is that an emulator should emulate the *whole* machine, if
>possible. That means disks too. So I think that if you have a BBC
>emulator, you should be able to stick BBC disks in it.....
>
The only reason to do this would be if you wanted to interchange floppies
directly with the BBC.  In that case you should be able to handle the old
single density DISC system as well.

I can imagine this would be needed for some games which did obscure copy
protection things (you would have to emulate the entire controller for some
of these.  For the older games that would mean emulating the 8271 as well).
Some old programs were recorded in a dual 80/40 format following my
article in Acorn User c.1984.
>
>.....What I'm hoping to
>do is set up my emulator to read BBC disks (which looks like it might not
>be easy) and then just to fudge the ADFS read/write sector routines (or
>even just intercept the OS calls). Then when ADFS tries to read a sector,
>it will read it from the BBC disk in my PC drive. That means all the
>filing system will still be taken care of by ADFS and BBC disks will work
>fine.
>
>My other idea was to set up a virtual hard disk on the PC; just a big
>long file. Then I would intercept ADFS calls to read/write sectors to
>that as well, and hey presto - ADFS would do all of its own filing on a
>hard disk too.....
>
You could also set up virtual floppies - convert any floppies you had to PC
files in toto.

BUT I DON'T THINK IT IS NECESSARY

The BBC was designed to work with multiple filing systems.  There is no
reason why you should not make a simple PC/BBC filing system.  The BBC
portion would intercept the relevant BBC vectors and point them to some
unused poition of the memory map (say part of Shiela unused).  When the
emulator detected a branch to these addresses it would call regular PC
routines (are you writing is C?) to do file load/save, read/write,
open/close etc.

The only thing extra to do would be to include catalogue info: load and
execution addresses.  On a Mac I would put these in the resource fork (even
though it wastes disc space), on other platforms I would put these at the
beginning of the real file with the BBC virtual file starting from after
the cat block.  If you have programs which rely on directory level
separators being '.' then your emulator could translate these but in the
first instance I shouldn't bother.

David Barnett
<< Previous Message Main Index Next Message >>
<< Previous Message in Thread This Month Next Message in Thread >>