[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: DOS/ProDOS Image Question



On Mon, 24 Feb 2003, Bryan Parkoff wrote:

> Date: Mon, 24 Feb 2003 12:35:14 -0600
> From: Bryan Parkoff <BParkoff@satx.rr.com>
> Newsgroups: comp.sys.apple2
> Subject: DOS/ProDOS Image Question
>

>     All images' extension DSK and PO are RAW data for all emulators.
I would say, it's rather the opposite. To me, raw data would be the data
found on the real disk, i.e. 6-2 nibbles including sector header and other
gap bytes. This would more or less correspond to the .NIB format. The .DSK
and .PO-format both store the data as normal bytes which you can take a look
at or change with a hex editor if you like. IOW: The 6-2 bytes are decoded
and stored the same way they are finally loaded into the Apple memory by
DOS. For an introduction to the various disk image formats, you may want to
take a look at e.g. <http://www.zip.com.au/~alexm/faq/disk.html>.

> Do all emulators read all images into memory BEFORE they are prenibbled
> into 342 bytes as 6-2 encoded?
Well, it depends. I know some (old) emulators that only convert the current
track (i.e. which the emulated drive's head is reading) to the 6-2 format.
The emulator will set up a flag, when a program writes new data to the
track. As soon as the emulated drive's head is moved, the emulator tests
this flag and, if it is set, it converts the new 6-2 data back to the .DSK
format. This method was mainly done to save ram space of the emulation
machine. Modern computers today have got far enough ram so that the whole
disk image can be loaded and converted in one go. This makes the drive
emulation much less complicated and also faster.

> By the way, all emulators can access to C600 routines
> and then postnibbled into 256 bytes as 8-0 decoded.  Is it correct?
I'm not sure what you mean by that. The emulators do convert the 6-2 format
by using an algorithm similar to the one found in the slot rom at $c600.
However, of course, this part of the emulation is mostly written in C/C++
today. The emulator itself does not use any of the routines found in the rom.
It only emulates them.

> --
> Yours Truly,
>
> Bryan Parkoff
> BParkoff@satx.rr.com

Kind regards

Holger