changeset 2661:9e9ed6d6b4c2

Updated so that scdwn handles SS.Montr dw3 now handles vwindow
author Boisy Pitre <boisy.pitre@nuance.com>
date Fri, 13 Jul 2012 21:46:26 -0500
parents adb21dec5e10
children 07cc32e3d96f
files defs/os9.d level1/coco/modules/makefile level1/modules/dw3.asm level1/modules/scdwn.asm level1/modules/scdwndesc.asm
diffstat 5 files changed, 58 insertions(+), 23 deletions(-) [+]
line wrap: on
line diff
--- a/defs/os9.d	Fri Jul 13 13:27:33 2012 -0500
+++ b/defs/os9.d	Fri Jul 13 21:46:26 2012 -0500
@@ -328,8 +328,8 @@
 SS.MpGPB       RMB       1                   SetStat to request a Get/Put Buffer be mapped in workspace
 SS.Slots       RMB       1                   Network 4 slots? getstat
 
-               IFGT      Level-1
-
+*               IFGT      Level-1
+               IFNE      1
 * Level 2 Windowing
 SS.WnSet       RMB       1                   Set up High Level Windowing Information
 SS.MnSel       RMB       1                   Request High level Menu Handler take determine next event
--- a/level1/coco/modules/makefile	Fri Jul 13 13:27:33 2012 -0500
+++ b/level1/coco/modules/makefile	Fri Jul 13 21:46:26 2012 -0500
@@ -206,28 +206,28 @@
 	$(AS) $< $(ASOUT)$@ $(AFLAGS) -aAddr=14
 
 term_z_scdwn.dd: scdwndesc.asm
-	$(AS) $< $(ASOUT)$@ $(AFLAGS) -aAddr=65
+	$(AS) $< $(ASOUT)$@ $(AFLAGS) -aAddr=16
 
 z1_scdwn.dd: scdwndesc.asm
-	$(AS) $< $(ASOUT)$@ $(AFLAGS) -aAddr=66
+	$(AS) $< $(ASOUT)$@ $(AFLAGS) -aAddr=17
 
 z2_scdwn.dd: scdwndesc.asm
-	$(AS) $< $(ASOUT)$@ $(AFLAGS) -aAddr=67
+	$(AS) $< $(ASOUT)$@ $(AFLAGS) -aAddr=18
 
 z3_scdwn.dd: scdwndesc.asm
-	$(AS) $< $(ASOUT)$@ $(AFLAGS) -aAddr=68
+	$(AS) $< $(ASOUT)$@ $(AFLAGS) -aAddr=19
 
 z4_scdwn.dd: scdwndesc.asm
-	$(AS) $< $(ASOUT)$@ $(AFLAGS) -aAddr=69
+	$(AS) $< $(ASOUT)$@ $(AFLAGS) -aAddr=20
 
 z5_scdwn.dd: scdwndesc.asm
-	$(AS) $< $(ASOUT)$@ $(AFLAGS) -aAddr=70
+	$(AS) $< $(ASOUT)$@ $(AFLAGS) -aAddr=21
 
 z6_scdwn.dd: scdwndesc.asm
-	$(AS) $< $(ASOUT)$@ $(AFLAGS) -aAddr=71
+	$(AS) $< $(ASOUT)$@ $(AFLAGS) -aAddr=22
 
 z7_scdwn.dd: scdwndesc.asm
-	$(AS) $< $(ASOUT)$@ $(AFLAGS) -aAddr=72
+	$(AS) $< $(ASOUT)$@ $(AFLAGS) -aAddr=23
 
 # DriveWire 3 RBF descriptors
 ddx0.dd: dwdesc.asm
--- a/level1/modules/dw3.asm	Fri Jul 13 13:27:33 2012 -0500
+++ b/level1/modules/dw3.asm	Fri Jul 13 21:46:26 2012 -0500
@@ -352,12 +352,40 @@
 
 ; save back D on stack and build our U
 IRQGotOp       pshs      d
-          * mode switch on bits 7+6 of A: 00 = vserial, 01 = system, 10 = wirebug?, 11 = ?							
+          * mode switch on bits 7+6 of A: 00 = vserial, 01 = vwindow, 10 = wirebug?, 11 = ?							
                anda      #$C0                ; mask last 6 bits
                beq       mode00              ; virtual serial mode
           					; future - handle other modes
+               cmpa      #%01000000          ; vwindow?
+               beq       mode01
                lbra      IRQExit             ; for now, bail
 
+* Virtual Window Handler
+mode01
+               lda       ,s
+               anda      #%00110000
+               beq       key
+               lbra      IRQExit
+
+key
+               lda       ,s
+               anda      #$0F
+               ora       #$10
+               ifgt      Level-1
+               ldx       <D.DWStat
+               else      
+               ldx       >D.DWStat
+               endc      
+; cheat: we know DW.StatTbl is at offset $00 from D.DWStat, do not bother with leax
+;			leax    DW.StatTbl,x
+               lda       a,x
+               clrb      
+               tfr       d,u
+               puls      d
+               lbra      IRQPutch
+
+               
+* Virtual Serial Handler
 mode00         lda       ,s                  ; restore A		  
                anda      #$0F                ; mask first 4 bits, a is now port #+1
                beq       IRQCont             ; if we're here with 0 in the port, its not really a port # (can we jump straight to status?)
--- a/level1/modules/scdwn.asm	Fri Jul 13 13:27:33 2012 -0500
+++ b/level1/modules/scdwn.asm	Fri Jul 13 21:46:26 2012 -0500
@@ -1,5 +1,5 @@
 ********************************************************************
-* scdwn - CoCo DriveWire Network Driver
+* scdwn - DriveWire Network Driver
 *
 * $Id$
 *
@@ -50,14 +50,13 @@
 * Added FASTSERWRITE support
 *
                nam       scdwn
-               ttl       CoCo DriveWire Network Driver
+               ttl       DriveWire Network Driver
 
                ifp1      
                use       defsfile
                use       drivewire.d
                endc      
 
-
 tylg           set       Drivr+Objct
 atrv           set       ReEnt+Rev
 rev            set       $00
@@ -431,18 +430,26 @@
 
 GetKySns
                cmpa      #SS.KySns
-               bne       UnSvcErr            ; no, we have no more answers, report error
+               bne       GetSSMntr           ; no, we have no more answers, report error
 * Get key sense byte from server and return to caller
-               pshs      u
+               pshs      a,u
+               leax      ,s
+               ldy       #$001
                ifgt      Level-1
                ldu       <D.DWSubAddr
                else      
                ldu       >D.DWSubAddr
-               jsr       3,u
+               jsr       DW$Read,u
                endc      
-               puls      u
+               puls      a,u
                sta       R$A,x
+               puls      cc,dp,pc            ; restore Carry status, system DP, return			
 
+GetSSMntr      cmpa      #SS.Montr
+               bne       UnSvcErr            ; no, we have no more answers, report error
+               lda       #$01
+               sta       R$A,x
+               
                puls      cc,dp,pc            ; restore Carry status, system DP, return			
 
 * Advertise Stat Code to server
@@ -463,7 +470,7 @@
                else      
                ldu       >D.DWSubAddr
                endc      
-               jsr       6,u
+               jsr       DW$Write,u
                leas      3,s
                puls      a,y,x,u,pc
 
@@ -528,7 +535,7 @@
                else      
                ldu       >D.DWSubAddr
                endc      
-               jsr       6,u
+               jsr       DW$Write,u
                clrb      
 ssbye          rts       
 
--- a/level1/modules/scdwndesc.asm	Fri Jul 13 13:27:33 2012 -0500
+++ b/level1/modules/scdwndesc.asm	Fri Jul 13 21:46:26 2012 -0500
@@ -103,12 +103,12 @@
          IFEQ  Addr-255
          fcs   'N'
          ELSE
-         IFGT  Addr-64
-         IFEQ  Addr-65
+         IFGT  Addr-14
+         IFEQ  Addr-15
          fcs   /Term/
          ELSE
          fcc   /Z/
-         fcb   176+Addr-65
+         fcb   176+Addr-16
          ENDC
          ELSE
          fcc   /N/