AppleIIAsm-Collection/disks/disk1_stdio/T.XPRINT.SUB
nathanriggs f5c097e70f STDIO disk 0.3.0 update
- added error handling
- no more massive library; just a subroutine per file. This is because Merlin doesn't like large files.
- added a "minify" BASIC utility that gets rid of *most* comments in a source textfile. This dramatically reduces space used if you're not terribly interested in non-inline comments.
- TFILL,THLIN,TVLIN and TPUT not directly access the video memory (page one), making for a much faster draw without interfering COUT.
- some stylistic changes, primarily to TFILL
- change required files to minified versions only. The whole files can be found on disk 2.
- got a norovirus so pretty much couldn't do anything requiring sustained attention, so focused on small things here and not on my dayjob. Cool.
- created a required.vars file that separates variables and settings from the other required files. Not minified.
- This current bout of revision will probably be the last, once all initial 6 disks are revamped, that focuses on all subroutines/macros in a given library at a single push. After this round, commits will be done on a subroutine or related file basis.
2019-01-13 23:48:09 -05:00

67 lines
1.7 KiB
Plaintext

*
*``````````````````````````````*
* XPRINT :: SPECIAL PRINT *
*- -*
* PRINTS DATA IMMEDIATELY *
*- -*
* CLOBBERS: *
* *
* FLAGS: NZC----- REG: AYM- *
*- -*
* CYCLES: 53+ *
* SIZE: *
*- -*
* USAGE: *
* JSR SPRINT *
* ASC "HELLO, WORLD!" *
*- -*
* ENTRY *
* *
* TOP OF STACK *
* *
* LOW BYTE OF RETURN ADDRESS *
* HI BYTE OF RETURN ADDRESS *
*- -*
* EXIT *
* *
* TOP OF STACK *
* *
* LOW BYTE OF RETURN ADDRESS *
* HI BYTE OF RETURN ADDRESS *
* *
* Y = LOW BYTE OF ADDRESS *
* X = UNCHANGED *
* A = LO BYTE *
*,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,*
*
XPRINT
*
** GET CURRENT EXEC ADDRESS
*
PLA
STA ADDR1
PLA
STA ADDR1+1
*
LDY #$01 ; POINT TO NEXT
; INSTRUCTION
:LOOP
LDA (ADDR1),Y
BEQ :DONE
JSR COUT1
INY
BNE :LOOP
:DONE ; RESTORE STACK
CLC ; EXEC POINTER
TYA ; TO RESUME
ADC ADDR1
STA ADDR1
LDA ADDR1+1
ADC #$00
PHA
LDA ADDR1
PHA
RTS
:EXIT
*