Date : Sat, 24 Jan 2004 00:40:45 +0000
From : jgh@... (Jonathan Graham Harston)
Subject: Re: BBC Hard Drive Package Update
Richard Gellman <splodge@...> wrote:
> Hard drive support will be in the next version of BeebEm (due out
> spring-ish).
I was just thinking of a long list of other emulated hardware to ask you
to consider implementing, when I realised there's a better idea.
At http://www.mdfs.net/Docs/Comp/Spectrum/RISCOS/EmulatedIO is a proposal
to allow Spectrum emulators running on RISC OS to pass unknown hardware
I/O access to other modules, so then other people could build emulated
hardware themselves and "plug" it in.
I'm not too up to speed with Windows DLLs and stuff, but I imagine a
similar concept could work with BeebEm and Windows-based BBC emulators in
general.
What would be needed is a generally agreed protocol by which a BBC
emulator passes hardware access to hardware it doesn't implement itself to
other modules to allow them to pick it up. A minimum would be the
following:
BBC_Resetting:
The emulated BBC is performing a hardware reset. To the emulated hardware
this would be like the ~RST signal on the 1MHz bus. Nothing should claim
this call.
BBC_IOWrite:
The emulated BBC is attempting to write to an address in &FCxx/&FDxx to
something that is not emulated by the emulator itself. If an external
module can deal with this, claim the call.
BBC_IORead:
The emulated BBC is attempting to read from an address in &FCxx/&FDxx from
something that is not emulated by the emulator itself. If an external
module can deal with this, claim the call, and return a value.
So, if an emulator implements, for instance, a SCSI card at &FC40-&FC43,
then access to those addresses would not get passed to the calls. If
nothing claims a read call, then the emulator should assume it has read
&FF.
The emulator could even pass through access to addresses in &FExx that
aren't implemented by the emulator, so, for example, an external module
could emulate a 6854 ADLC at &FEA0-A7.
A more advanced implementation would allow the external emulated hardware
to generate 6502 IRQs and NMIs.
--
J.G.Harston (JGH BBC PD Library) 70 Camm Street, Walkley, SHEFFIELD S6 3TR
jgh@... - Running on BBCs & Masters with SJ MDFS FileServer
Z80+6502/CoPro+Tubes/Econet+SJ - - - - - - - http://www.mdfs.net/User/JGH/