[Coco] Re: Disk Basic and 512 byte block floppies.

John E. Malmberg wb8tyw at qsl.net
Sun Jan 18 19:58:21 EST 2004


Robert Gault wrote:
> tim lindner wrote:
> 
>> John E. Malmberg <wb8tyw at qsl.net> wrote:
> 
>>> I formatted a 720K 3.5 inch floppy with 512 byte sectors
>>
>> Interesting experiement.
>>
>> The size of each sector is written to the disk. Disk BASIC expects all
>> the sectors to be 256 bytes, it doesn't check. It create 256 byte blocks
>> of RAM to read to and from these sectors.
>>
>> If the sector is larger, then the RAM buffer will overflow. On a read
>> sector command you will overwrite whatever is past the sector buffer in
>> RAM. The could be dangerous.
>>
>> On a write sector command you will write whatever data is after the
>> buffer to the larger sector.
>> 
> With Disk Basic, the buffer overflow will go into a second disk I/O 
> buffer; buffer0 $600-$6FF, buffer1 $700-$7FF. You would corrupt data 
> stored in the second buffer but in most cases you won't see any ill 
> effects.

According to the Disk-Basic-Unraveled series, the buffer at $700-$7ff is 
used for the verify function, and for the DSKINI function.

So with verify off, there should be no danger of data corruption by 
using the DSKI$ and DSKO$ functions.

> In general, 512 byte/sec floppies can be used in this fashion on a Coco. 
> Just don't expect these disks to then make any sense on a PC.

I expect them to make perfect sense for what I want to use them for.

My OpenVMS system can not read or write 256 byte block sector floppies, 
and my Microsoft Windows 2000 system can not either.  And apparently the 
newer Microsoft operating systems can not either.  And I do not want to 
have to reboot the Microsoft system down to DOS just for reading a 
floppy image.

But now it appears that I can write a DISK BASIC program that will copy 
COCO floppies on to media that I can read on my other systems.

If I poke or peek the data for the ODD sectors of a 256 byte block 
floppy in to $700-$7FF, I will be able to pack the data into the 512 
byte sector floppy, so a disk image of the first 35 sectors from it will 
look just like a one that is made by the existing tools.

Of course ROM basic is limited to the 35 tracks, but that is good enough.

And this DISK BASIC program can run on all Color Computers because it 
does not require patching the ROMS.

This is much better than I hoped for before I did this experiment.  I 
expected that I would only be able to read and write to the first 256 
bytes of each sector of the first 35 tracks of the 720K floppy, it it 
now appears I can do all 512 bytes with a little bit of BASIC hacking.

The next milestone is if I can use the DSKI$ to read the sectors on a 
FLEX-09 formatted floppy.

-John
wb8tyw at qsl.net
Personal Opinion Only





More information about the Coco mailing list