0001 * Equates ("Magic Numbers" and BUFFALO routines) 0002 ffc7 OUTSTRG EQU $FFC7 ; prints a string 0003 0004 * Put a stack in our program (mostly for BUFFALO/interrupt calls) 0005 d800 ORG $D800 ; Bottom of the stack 0006 d800 STACK RMB 256 ; 256 byte stack 0007 d8ff INITSP EQU *-1 ; Stack pointer initializer 0008 0009 * Data to locate the cursor and print the appropriate output 0010 d000 ORG $D000 0011 d000 1b TEST FCB $1B ; Locate the cursor in the upper right hand corner 0012 d001 3d FCB $3D 0013 d002 20 FCB $20 0014 d003 6b FCB $6B 0015 d004 04 FCB $04 0016 d100 ORG $D100 0017 d100 53 61 6d 6c 65 20 TEXT FCC 'Samle text here v.01' 74 65 78 74 20 68 65 72 65 20 20 76 2e 30 31 0018 d115 04 FCB $04 0019 0020 0021 c000 INITIT ORG $C000 0022 c000 8e d8 ff [ 3 ] LDS #INITSP ; Initializes the stack 0023 c003 cc 00 00 [ 3 ] LDAD #$00 0024 c006 ce 00 00 [ 3 ] LDX #$0000 0025 c009 18 ce 00 00 [ 4 ] LDY #$0000 0026 c00d 0e [ 2 ] CLI 0027 0028 c00e 36 [ 3 ] PSHA 0029 c00f 3c [ 4 ] PSHX 0030 c010 ce d0 00 [ 3 ] LDX #TEST ; Load up the location 0031 c013 bd ff c7 [ 6 ] JSR OUTSTRG ; Send it out 0032 c016 ce d1 00 [ 3 ] LDX #TEXT 0033 c019 bd ff c7 [ 6 ] JSR OUTSTRG 0034 c01c 38 [ 5 ] PULX 0035 c01d 32 [ 4 ] PULA 0036 c01e 3f [14 ] SWI INITIT d116 INITSP d8ff OUTSTRG ffc7 STACK d800 TEST d000 TEXT d100