2016-12-07 03:18:33 +00:00
|
|
|
;;; Apple II audit routines
|
|
|
|
;;; Copyright © 2016 Zellyn Hunter <zellyn@gmail.com>
|
|
|
|
|
|
|
|
!convtab <apple ii/convtab.bin>
|
|
|
|
!to "audit.o", plain
|
|
|
|
* = $6000
|
|
|
|
|
|
|
|
HOME = $FC58
|
|
|
|
COUT = $FDED
|
2016-12-17 03:32:35 +00:00
|
|
|
CROUT = $FD8E
|
2016-12-08 04:05:07 +00:00
|
|
|
PRBYTE = $FDDA
|
2016-12-17 03:32:35 +00:00
|
|
|
PRNTYX = $F940
|
2016-12-07 03:18:33 +00:00
|
|
|
|
2016-12-14 02:26:45 +00:00
|
|
|
STRINGS = $7000
|
|
|
|
!set LASTSTRING = $7000
|
|
|
|
|
2016-12-15 01:16:55 +00:00
|
|
|
;; Printing and error macros.
|
|
|
|
!src "macros.asm"
|
|
|
|
|
2016-12-07 03:18:33 +00:00
|
|
|
main:
|
|
|
|
jsr HOME
|
2016-12-14 02:26:45 +00:00
|
|
|
+print
|
|
|
|
!text "APPLE II AUDIT",$8D,$8D
|
|
|
|
+printed
|
2016-12-11 03:23:36 +00:00
|
|
|
|
2016-12-15 01:16:55 +00:00
|
|
|
;; Detection and reporting of model and memory.
|
|
|
|
!src "detect.asm"
|
2016-12-11 03:23:36 +00:00
|
|
|
|
2016-12-15 01:16:55 +00:00
|
|
|
;; Language card tests.
|
|
|
|
!src "langcard.asm"
|
2016-12-08 04:05:07 +00:00
|
|
|
|
2016-12-07 03:18:33 +00:00
|
|
|
end: jmp *
|
|
|
|
|
2016-12-16 03:20:54 +00:00
|
|
|
print
|
2016-12-14 02:26:45 +00:00
|
|
|
lda $C081
|
|
|
|
lda $C081
|
2016-12-16 03:20:54 +00:00
|
|
|
pla
|
|
|
|
sta getch+1
|
|
|
|
pla
|
|
|
|
sta getch+2
|
|
|
|
- inc getch+1
|
|
|
|
bne getch
|
|
|
|
inc getch+2
|
|
|
|
getch lda $FEED ; FEED gets modified
|
2016-12-07 03:18:33 +00:00
|
|
|
beq +
|
|
|
|
jsr COUT
|
2016-12-16 03:20:54 +00:00
|
|
|
jmp -
|
2016-12-14 02:26:45 +00:00
|
|
|
+ rts
|
2016-12-17 03:32:35 +00:00
|
|
|
|
|
|
|
errora
|
|
|
|
pha
|
|
|
|
lda $C082
|
|
|
|
lda #'A'
|
|
|
|
jsr COUT
|
|
|
|
lda #':'
|
|
|
|
jsr COUT
|
|
|
|
pla
|
|
|
|
jsr PRBYTE
|
|
|
|
jsr CROUT
|
|
|
|
error
|
|
|
|
lda $C082
|
|
|
|
pla
|
|
|
|
sta getche+1
|
|
|
|
pla
|
|
|
|
sta getche+2
|
|
|
|
- inc getche+1
|
|
|
|
bne getche
|
|
|
|
inc getche+2
|
|
|
|
getche lda $FEED ; FEED gets modified
|
|
|
|
beq +
|
|
|
|
jsr COUT
|
|
|
|
jmp -
|
|
|
|
+
|
|
|
|
+print
|
|
|
|
!text "ZELLYN.COM/A2AUDIT/V0#E",0
|
|
|
|
+printed
|
|
|
|
jsr PRNTYX
|
|
|
|
rts
|
2016-12-15 03:57:37 +00:00
|
|
|
!src "technote2.asm"
|
|
|
|
|
2016-12-14 02:26:45 +00:00
|
|
|
; !if * != STRINGS {
|
|
|
|
; !error "Expected STRINGS to be ", *
|
|
|
|
; }
|
|
|
|
|
|
|
|
!if * > STRINGS {
|
|
|
|
!error "End of compilation passed STRINGS:", *
|
|
|
|
}
|
2016-12-15 03:57:37 +00:00
|
|
|
|