[Coco] Disk subroutines for Assembly?
Don Barber
don at dgb3.net
Thu Feb 3 16:00:17 EST 2022
Hi folks, hoping for a bit of advice.
I'm teaching myself coco assembly programming, and I've gotten to the
part where I'd like to save a file to disk...and finding that none of
the assembly programming books for the 6809 talk about how to do that.
On modern systems one would make a system call to the OS, but with the
CoCo I'd assumed there would a ROM routine for such just like in the 68k
Macintoshes. I did find the Disk edtasm manual
(https://colorcomputerarchive.com/repo/Documents/Manuals/Programming/Disk%20EDTASM%20%28Tandy%29.pdf)
specifically Section IV which talks about DOS routines including open,
write, read, and close functions for files. But its mixed up with
talking about 'overlays' which sounds like its something edtasm injects
into the assembled binary itself.
Note: I'm not using edtasm; I've been using lwasm on my linux laptop to
compile code into decb format and generally happy with it.
Can someone help educate me on:
1) Are there or are there not file access subroutines available in the
disk controller ROM that are appropriate for assembly programmers to
use? I found the dump of the color basic source
https://colorcomputerarchive.com/repo/Programming/Source/Color%20Basic/disk.asm
but there has to be a better way than reverse engineering what kind of
data structure that 'LC48D' expects. Pointing me to a programming
reference would be much appreciated.
2) If it does turn out that there are no ROM subroutines for disk
access, did every assembly programmer end up rolling their own wd7xxx
chip and file allocation table routines? Or are there example subroutine
libraries out there folks can use? Or did everyone just use the DOS
overlay with disk edtasm?
Thanks!
Don
More information about the Coco
mailing list