diff --git a/NOTES.txt b/NOTES.txt index f8f32ef..28ef36f 100644 --- a/NOTES.txt +++ b/NOTES.txt @@ -1,7 +1,7 @@ Name Year MS Version ROM 9digit extensions comment Commodore BASIC 1 1977 Y Y CBM OSI BASIC 1977 1.0 REV 3.2 Y N - -AppleSoft I 1977 1.1 N Y Apple -KIM BASIC 1977 1.1 N Y - +AppleSoft I 1977 1.1 N Y Apple CONFIG_11 +KIM BASIC 1977 1.1 N Y - CONFIG_11A Commodore BASIC 2 1979 Y Y CBM KBD BASIC 1980 Y N KBD diff --git a/defines_apple.s b/defines_apple.s index e44c8be..3e73a7f 100644 --- a/defines_apple.s +++ b/defines_apple.s @@ -36,7 +36,7 @@ INPUTFLG := $0015 CPRMASK := $0016 Z14 := $0017 ; Ctrl+O flag Z15 := $0018 -Z16 := $0050 +POSX := $0050 Z17 := $0051 Z18 := $0052 LINNUM := $0053 diff --git a/defines_cbm.s b/defines_cbm.s index b2fe1c9..6fc8665 100644 --- a/defines_cbm.s +++ b/defines_cbm.s @@ -11,7 +11,7 @@ CONFIG_INPUTBUFFER_ORDER := 1 ; ldx/ldy or ldy/ldx .else CONFIG_CBM_ALL := 1 CONFIG_11 := 1 -CONFIG_11_NOAPPLE := 1 +CONFIG_11A := 1 CBM2_KBD := 1 CBM2_KIM := 1 CBM2_APPLE := 1 @@ -45,7 +45,7 @@ GOSTROUT := $0006 GOGIVEAYF := $0008 Z15 := $0004 -Z16 := $0005 +POSX := $0005 Z17 := $0006 Z18 := $0007 LINNUM := $0008 @@ -94,7 +94,7 @@ GOGIVEAYF := $0008 Z03 := $000E;3 ; same LINNUM := $0011;0008 Z96 := $00E8-82 -Z16 := $0118-82 +POSX := $0118-82 TXPSV = LASTOP INPUTBUFFER := $0200;00A diff --git a/defines_kbd.s b/defines_kbd.s index 3fb7bf4..6f76ca2 100644 --- a/defines_kbd.s +++ b/defines_kbd.s @@ -3,7 +3,7 @@ CONFIG_SMALL := 1 CBM2_KBD := 1 KIM_KBD := 1 CONFIG_11 := 1 -CONFIG_11_NOAPPLE := 1 +CONFIG_11A := 1 CONFIG_SAFE_NAMENOTFOUND := 1 ; INPUTBUFFER > $0100 @@ -21,7 +21,7 @@ GOGIVEAYF := $0008 USR := $000A Z15 := $000D -Z16 := $0010 +POSX := $0010 Z17 := $06FC;$000F Z18 := $06FD;$0010 LINNUM := $0013;11 diff --git a/defines_kim.s b/defines_kim.s index a29af67..36ca712 100644 --- a/defines_kim.s +++ b/defines_kim.s @@ -1,6 +1,6 @@ KIM_KBD := 1 CONFIG_11 := 1 -CONFIG_11_NOAPPLE := 1 +CONFIG_11A := 1 CONFIG_SAFE_NAMENOTFOUND := 1 CBM2_KIM_APPLE := 1 ; OUTDO difference KIM_APPLE := 1 @@ -33,7 +33,7 @@ INPUTFLG := $0012 CPRMASK := $0013 Z14 := $0014 ; Ctrl+O flag Z15 := $0015 -Z16 := $0016 +POSX := $0016 Z17 := $0017 Z18 := $0018 LINNUM := $0019 diff --git a/defines_osi.s b/defines_osi.s index d304b9c..75f9d01 100644 --- a/defines_osi.s +++ b/defines_osi.s @@ -23,7 +23,7 @@ GOGIVEAYF := $0008 USR := $000A Z15 := $000D -Z16 := $000E +POSX := $000E Z17 := $000F Z18 := $0010 LINNUM := $0011 diff --git a/flow.s b/flow.s index adb9c57..31e62a2 100644 --- a/flow.s +++ b/flow.s @@ -140,7 +140,7 @@ NEWSTT2: ; CARRY IS SET ; ---------------------------------------------------------------------------- EXECUTE_STATEMENT: -.ifndef CONFIG_11_NOAPPLE +.ifndef CONFIG_11A beq RET1 .ifndef APPLE sec @@ -338,7 +338,7 @@ LE68E: .endif .if .def(CONFIG_NULL) || .def(CBM1) ; CBM1 has the keyword removed, -; but the code is, still here +; but the code is still here NULL: jsr GETBYT bne RET1 @@ -351,7 +351,7 @@ NULL: L2739: jmp IQERR .endif -.ifndef CONFIG_11_NOAPPLE +.ifndef CONFIG_11A CLEAR: bne RET1 jmp CLEARC diff --git a/init.s b/init.s index 6f960b8..b4a7edb 100644 --- a/init.s +++ b/init.s @@ -76,8 +76,8 @@ COLD_START2: ldy #>L29D0 .endif .ifdef CBM_APPLE - sta L0001 - sty L0001+1 + sta USR+1 + sty USR+2 .endif .ifndef CONFIG_CBM_ALL .ifdef APPLE @@ -129,7 +129,7 @@ L4098: sta Z15 .endif .ifndef CONFIG_11 - sta Z16 + sta POSX .endif pha sta Z14 diff --git a/misc2.s b/misc2.s index 6eda058..6afdd8a 100644 --- a/misc2.s +++ b/misc2.s @@ -31,7 +31,7 @@ GIVAYF: ldx #$90 jmp FLOAT1 POS: - ldy Z16 + ldy POSX ; ---------------------------------------------------------------------------- ; FLOAT (Y) INTO FAC, GIVING VALUE 0-255 diff --git a/print.s b/print.s index f28630a..b013f3c 100644 --- a/print.s +++ b/print.s @@ -37,7 +37,7 @@ PRINT2: ldy #$00 lda (FAC_LAST-1),y clc - adc Z16 + adc POSX .ifdef KBD cmp #$28 .else @@ -103,7 +103,7 @@ LC9D8: .endif lda #CRLF_1 .ifndef CONFIG_CBM_ALL - sta Z16 + sta POSX .endif jsr OUTDO LE882: @@ -135,7 +135,7 @@ L29D3: dex bne L29D3 L29D9: - stx Z16 + stx POSX pla tax .else @@ -149,13 +149,13 @@ L29D9: L29DD: rts L29DE: - lda Z16 -.ifndef CONFIG_CBM_ALL -.ifdef KBD + lda POSX +.ifndef CONFIG_NO_CR + .ifdef KBD cmp #$1A -.else + .else cmp Z18 -.endif + .endif bcc L29EA jsr CRDO jmp L2A0D @@ -166,25 +166,25 @@ L29EB: .ifdef CONFIG_CBM_ALL sbc #$0A .else -.ifdef KBD + .ifdef KBD sbc #$0D -.else + .else sbc #$0E -.endif + .endif .endif bcs L29EB eor #$FF adc #$01 bne L2A08 L29F5: -.ifdef CONFIG_11_NOAPPLE +.ifdef CONFIG_11A php .else pha .endif jsr GTBYTC - cmp #$29 -.ifndef CONFIG_11_NOAPPLE + cmp #')' +.ifndef CONFIG_11A .ifdef APPLE beq L1185 jmp SYNERR @@ -211,7 +211,7 @@ L1185: bcc L2A09 .endif txa - sbc Z16 + sbc POSX bcc L2A0D .ifndef CONFIG_11 beq L2A0D @@ -321,7 +321,7 @@ LCA6A: nop .endif .ifdef CONFIG_PRINT_CR - lda Z16 + lda POSX cmp Z17 bne L2A4C .ifdef APPLE @@ -334,7 +334,7 @@ LCA6A: L2A4C: .endif .ifndef CONFIG_CBM_ALL - inc Z16 + inc POSX .endif L2A4E: .ifndef CBM2_KBD diff --git a/string.s b/string.s index 7cd13f2..c1c540b 100644 --- a/string.s +++ b/string.s @@ -703,7 +703,7 @@ ASC: ldy #$00 lda (INDEX),y tay -.ifndef CONFIG_11_NOAPPLE +.ifndef CONFIG_11A jmp SNGFLT1 .else jmp SNGFLT