From 0aa485762a877e352ff068ccc031fc07fcdf8d13 Mon Sep 17 00:00:00 2001
From: Oliver Schmidt
Date: Fri, 19 Aug 2022 10:13:05 +0200
Subject: [PATCH] Revert "Avoid unwanted i/o access."
Neither the original hardware type nor the alternative hardware type have any read and write i/o port share addresses. Therefore phantom reads aren't an issue with those hardware types.
This reverts commit ae5cb754fb9540794bdb5465a77e1263ca257539.
---
Apple2/RPi.Command.asm | 18 ++++++------------
Apple2/Shell.asm | 17 ++++++-----------
2 files changed, 12 insertions(+), 23 deletions(-)
diff --git a/Apple2/RPi.Command.asm b/Apple2/RPi.Command.asm
index bc5480d..529cbcc 100644
--- a/Apple2/RPi.Command.asm
+++ b/Apple2/RPi.Command.asm
@@ -17,15 +17,10 @@ XLEN = $BE52 ;length of command string-1.
XCNUM = $BE53 ;CI cmd no. (ext cmd - 0).
PBITS = $BE54 ;Command parameter bits.
XRETURN = $FF58 ;Known RTS instruction.
-
-; have 6502 absolute indexed access phantom reads
-; happen on page $bf to avoid unwanted i/o access
-IndexOffset = $8f
-
-InputByte = $c08e - IndexOffset
-OutputByte = $c08d - IndexOffset
-InputFlags = $c08b - IndexOffset
-OutputFlags = $c087 - IndexOffset
+InputByte = $c08e
+OutputByte = $c08d
+InputFlags = $c08b
+OutputFlags = $c087
ReadBlockCommand = $01
WriteBlockCommand = $02
@@ -81,10 +76,9 @@ DetectSlot:
asl
asl
asl
- clc
- adc #IndexOffset
tax
- bcc Start ;always
+ clc
+ bcc Start
nextSlot:
dex
bne DetectSlot
diff --git a/Apple2/Shell.asm b/Apple2/Shell.asm
index 82be6db..95496d3 100755
--- a/Apple2/Shell.asm
+++ b/Apple2/Shell.asm
@@ -19,14 +19,10 @@ IOError = $27
NoDevice = $28
WriteProtect = $2B
-; have 6502 absolute indexed access phantom reads
-; happen on page $bf to avoid unwanted i/o access
-IndexOffset = $8f
-
-InputByte = $c08e - IndexOffset
-OutputByte = $c08d - IndexOffset
-InputFlags = $c08b - IndexOffset
-OutputFlags = $c087 - IndexOffset
+InputByte = $c08e
+OutputByte = $c08d
+InputFlags = $c08b
+OutputFlags = $c087
ResetCommand = $00
ReadBlockCommand = $01
@@ -89,10 +85,9 @@ DetectSlot:
asl
asl
asl
- clc
- adc #IndexOffset
tax
- bcc Init ;always
+ clc
+ bcc Init
nextSlot:
dex
bne DetectSlot