[sebhc] H8D files and labels

Barry Watzman Watzman at neo.rr.com
Mon Mar 27 21:13:57 CST 2006


If you are going to go modifying the format, I'd suggest a more extensive
modification that would allow for an arbitrary length and content of the
"comment" ... even to the point that the "comment" could contain, for
example, a JPEG file (photo of the original disk label).  Also, try to
devise a technique that does this while allowing for backward compatibility,
which probably means put the "comment" field at the end, not the beginning.


-----Original Message-----
From: sebhc-bounces at sebhc.org [mailto:sebhc-bounces at sebhc.org] On Behalf Of
Dave Dunfield
Sent: Monday, March 27, 2006 9:24 PM
To: sebhc at sebhc.org
Subject: [sebhc] H8D files and labels

I seem to have deleted it, but someone was just talking about keeping
labels for H8D files...

What I did when I defined the ImageDisk file format, was that I make
everything from the beginning of the file up to a 0x1A (^Z) character
a "comment". IMD puts in it's "IMD" signature, as well as the version
and timestamp as the first line, then the user-supplied comment can
go "on forever".

Because 0x1A (^Z) is the DOS text-EOF character, you can TYPE
these files to see the comment - TYPE stops output when it hits
the ^Z. IMD simply scans for the ^Z before it starts processing
track data.

We could easily modify the H8D definition to do the same thing.
It would be very easy to add support for this to the simulator(s).
Just check the file size - if < disk image, error (as now), if ==
disk image size, no comment. If > disk image size, scan for
the ^Z and check the remaining size == disk image. Record
the offset to ^Z and add this to all seeks within the file.

With this scheme, you can put plenty of information right in
the file, where you don't need to worry about it getting separated
from the image. When I record an image with IMD, I usually
type any label on the disk into the comment so that it is preserved
along with the data content.

Dave

--
dave06a (at)    Dave Dunfield
dunfield (dot)  Firmware development services & tools: www.dunfield.com
com             Collector of vintage computing equipment:
                http://www.parse.com/~ddunfield/museum/index.html

--
Delivered by the SEBHC Mailing List


--
Delivered by the SEBHC Mailing List



More information about the Sebhc mailing list