changeset 2720:482a547d5155 lwtools-port

Fixed so OP_DWINIT puts response in globals OP_SETTIME not sent unless response from OP_DWINIT from server is 128
author Boisy Pitre <boisy.pitre@nuance.com>
date Thu, 26 Jul 2012 12:19:43 -0500
parents 2fda91bdc268
children 06d492093592
files defs/os9.d level1/atari/bootfiles/makefile level1/atari/modules/makefile level1/modules/clock2_dw3.asm level1/modules/dw3.asm
diffstat 5 files changed, 41 insertions(+), 5 deletions(-) [+]
line wrap: on
line diff
--- a/defs/os9.d	Thu Jul 26 11:01:43 2012 -0500
+++ b/defs/os9.d	Thu Jul 26 12:19:43 2012 -0500
@@ -422,6 +422,7 @@
 D.DbgMem       RMB       2                   Debug memory pointer
 D.DWSubAddr    RMB  	 2                   DriveWire subroutine module pointer
 D.DWStat       RMB  	 2                   DriveWire statics page
+D.DWSrvID      RMB  	 1                   DriveWire server ID
 
                ORG       $20
 
--- a/level1/atari/bootfiles/makefile	Thu Jul 26 11:01:43 2012 -0500
+++ b/level1/atari/bootfiles/makefile	Thu Jul 26 12:19:43 2012 -0500
@@ -32,6 +32,7 @@
 		$(RBDW3) \
 		$(MD)/scdwv.dr \
 		$(SCDWV_NET) \
+		$(SCDWV_WIN) \
 		$(CD)/shell_21
 
 BOOTFILES	= bootfile
@@ -51,5 +52,5 @@
 	$(PADROM) -b 29696 $@
 
 clean:
-	$(RM) $(ALLOBJS) bootfile_p1 bootfile_p2
+	$(RM) $(ALLOBJS) $(BOOTFILE_P1) $(BOOTFILE_P2)
 
--- a/level1/atari/modules/makefile	Thu Jul 26 11:01:43 2012 -0500
+++ b/level1/atari/modules/makefile	Thu Jul 26 12:19:43 2012 -0500
@@ -25,7 +25,9 @@
 		scdwv.dr term_scdwv.dt n_scdwv.dd n1_scdwv.dd n2_scdwv.dd \
 		n3_scdwv.dd n4_scdwv.dd n5_scdwv.dd n6_scdwv.dd n7_scdwv.dd \
 		n8_scdwv.dd n9_scdwv.dd n10_scdwv.dd n11_scdwv.dd n12_scdwv.dd \
-		n13_scdwv.dd midi_scdwv.dd
+		n13_scdwv.dd midi_scdwv.dd \
+		z1_scdwv.dd z2_scdwv.dd z3_scdwv.dd z4_scdwv.dd z5_scdwv.dd \
+		z6_scdwv.dd z7_scdwv.dd
 
 PIPE		= pipeman.mn \
 		piper.dr \
@@ -110,6 +112,30 @@
 midi_scdwv.dd: scdwvdesc.asm
 	$(AS) $< $(ASOUT)$@ $(AFLAGS) -DAddr=14
 
+term_z_scdwv.dt: scdwvdesc.asm
+	$(AS) $< $(ASOUT)$@ $(AFLAGS) -DAddr=16
+
+z1_scdwv.dd: scdwvdesc.asm
+	$(AS) $< $(ASOUT)$@ $(AFLAGS) -DAddr=17
+
+z2_scdwv.dd: scdwvdesc.asm
+	$(AS) $< $(ASOUT)$@ $(AFLAGS) -DAddr=18
+
+z3_scdwv.dd: scdwvdesc.asm
+	$(AS) $< $(ASOUT)$@ $(AFLAGS) -DAddr=19
+
+z4_scdwv.dd: scdwvdesc.asm
+	$(AS) $< $(ASOUT)$@ $(AFLAGS) -DAddr=20
+
+z5_scdwv.dd: scdwvdesc.asm
+	$(AS) $< $(ASOUT)$@ $(AFLAGS) -DAddr=21
+
+z6_scdwv.dd: scdwvdesc.asm
+	$(AS) $< $(ASOUT)$@ $(AFLAGS) -DAddr=22
+
+z7_scdwv.dd: scdwvdesc.asm
+	$(AS) $< $(ASOUT)$@ $(AFLAGS) -DAddr=23
+
 # Clocks
 clock_60hz: clock.asm
 	$(AS) $(AFLAGS) $(ASOUT)$@ $< -DPwrLnFrq=60
--- a/level1/modules/clock2_dw3.asm	Thu Jul 26 11:01:43 2012 -0500
+++ b/level1/modules/clock2_dw3.asm	Thu Jul 26 12:19:43 2012 -0500
@@ -45,7 +45,15 @@
           bra       GetTime   	RTC Get Time
           nop
 
-SetTime   pshs      u,y,x,d
+SetTime   
+          IFGT      Level-1
+          lda       <D.DWSrvID
+          ELSE
+          lda       >D.DWSrvID
+          ENDC
+          cmpa      #128
+          bne       leave
+          pshs      u,y,x,d
           IFGT      Level-1
           ldu       <D.DWSubAddr
           ELSE
--- a/level1/modules/dw3.asm	Thu Jul 26 11:01:43 2012 -0500
+++ b/level1/modules/dw3.asm	Thu Jul 26 12:19:43 2012 -0500
@@ -126,7 +126,7 @@
                leas      1,s                 ; leave one byte on stack for response 
                
                ; read protocol version response, 1 byte
-               leax      ,s                  ; point X to stack head
+               ldx       #D.DWSrvID
                ldy       #1                  ; 1 byte to retrieve
                jsr       DW$Read,u                 ; call DWRead
                beq       InstIRQ             ; branch if no error
@@ -135,7 +135,7 @@
 
 * install ISR
 InstIRQ                  
-			   puls      a,u		; a has proto version from server.. not used yet
+			   puls      a,u
 
 			   ifgt      Level-1
                ldx       <D.DWStat