TIP: Click on subject to list as thread! ANSI
echo: cis.os9.6809.coco
to: Rick Ulland 70540,3305 (X)
from: Kevin Darling 76703,4227
date: 1991-05-09 14:38:45
subject: #10587-#hardware I/O

#: 10630 S10/OS9/6809 (CoCo)
    09-May-91  14:38:45
Sb: #10587-#hardware I/O
Fm: Kevin Darling 76703,4227
To: Rick Ulland 70540,3305 (X)

Rick - sorry for delay in response.  Yes, you'd just poke the slot switch,
but in order to stay out of each other's way, driver programmers adopted a
plan back in early 1988 for this.  Here's an old copy:


                    Driver Coordination Specs
                    =========================

1. Drivers that change the SCS slot should set D.DMAReq so that the floppy
   driver will know to hold off motor shutdown. Custom floppy controllers
   may not have to do this, but other drivers should if the production 
   CC3Disk and it's clones might be used in a system.

2. A floppy driver may assume at all times (except in its IRQ entry if used)
   that the MPI slot has been reset to the floppy controller. Again,
   this is for backward compatibility with CC3Disk.

3. Therefore, any driver that changes SCS in normal operation should:

    set D.DMAReq
    save the old slot
    set new slot
    do cmd setup code
    reset old slot
    clear D.DMAReq

3b. If you F$Sleep, reset the slot to the floppy first of course.

4. IRQ routines should:

    save the old slot
    set new slot
    do irq code
    reset old slot

5. Interrupt-driven devices that rely on GIME CART irq's should toggle the
   enable bit to allow use of multiple irq-driven devices either on the
   same main irq slot, or with MPI's that have all CARTs tied together.
   Example code in your interrupt routine (in addition to #4 above):

    ....            clear source device interrupt
    ldb $FF92      clear enable
    stb >$FF92      reset enable

6. If you don't use or set the CTS (slot for interrupt), be sure to use
   a mask algorithm to leave it as-is when you switch slots, so that
   interrupts from another device (like the RS232 pak) may get through
   while your code is running normally.

There is 1 Reply.

SOURCE: compuserve via textfiles.com

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.