change register assignment so that checksum is calculated properly.
authorNeal Andrew Crook <neal@pippaluk.org.uk>
Sun, 7 Aug 2016 21:05:46 +0000 (22:05 +0100)
committerNeal Andrew Crook <neal@pippaluk.org.uk>
Sun, 7 Aug 2016 21:05:46 +0000 (22:05 +0100)
This bug caused more weird behaviour than I can currently account
for. With the fix, it seems rock-solid.

Kernel/platform-multicomp09/dwread.s

index 457184e..c138e08 100644 (file)
@@ -64,9 +64,9 @@ rxAvail         lda       UARTSTA2
          bra       rxAvail             ; test again..
 
 * yes. Get it and move on
-rxGet    lda       UARTDAT2
+rxGet    ldb       UARTDAT2
          abx                           ; accummulate checksum
-         sta       ,u+                 ; store byte
+         stb       ,u+                 ; store byte
          leay      ,-y                 ; decrement count
          bne       rxNext
          lda       #4                  ; represents CC.Z=1