0100 ; LIST#D:AUTBUILD 0110 ; 0120 ; ROUTINE TO BOOT IN THE RS232 INTERFACE 0130 ; THEN EXECUTE A BASIC STATEMENT 0140 ; E.G. RUN"D:MENU 0150 ; 0000 0160 DUMMY = $0000 E459 0170 SIO = $E459 F3E4 0180 SCRNRD = $F3E4 000C 0190 DOSINI = $0C 0000 0200 *= $3800 3800 A950 0210 LDA #$50 3802 8D0003 0220 STA $0300 SET UP DCB TO 3805 A901 0230 LDA #1 INPUT "R" HANDLER 3807 8D0103 0240 STA $0301 FROM 850 INTERFACE 380A A93F 0250 LDA #$3F 380C 8D0203 0260 STA $0302 380F A940 0270 LDA #$40 3811 8D0303 0280 STA $0303 3814 A905 0290 LDA #5 3816 8D0503 0300 STA $0305 3819 8D0603 0310 STA $0306 381C A900 0320 LDA #0 381E 8D0403 0330 STA $0304 3821 8D0903 0340 STA $0309 3824 8D0A03 0350 STA $030A 3827 8D0B03 0360 STA $030B 382A A90C 0370 LDA #$0C 382C 8D0803 0380 STA $0308 382F 2059E4 0390 JSR SIO TO INPUT "R" HANDLER 0400 ; 3832 1003 0410 BPL IO.OK 3834 4C5738 0420 JMP LDBSC IF CAN'T INPUT 0430 ; 3837 A20B 0440 IO.OK LDX #$0B SET UP INPUT BUFFER 3839 BD0005 0450 LOOP LDA $0500,X 383C 9D0003 0460 STA $0300,X 383F CA 0470 DEX 3840 10F7 0480 BPL LOOP 3842 2059E4 0490 JSR SIO TO BOOT IN "R" 0500 ; 3845 3010 0510 BMI LDBSC IF BOOT FAILED 0520 ; 3847 200605 0530 JSR $0506 TO INIT. RS232 0535 ; 384A A50C 0540 LDA DOSINI CREATE IND. JSR 384C 8D5538 0550 STA INDJSR+1 384F A50D 0560 LDA DOSINI+1 3851 8D5638 0570 STA INDJSR+2 3854 200000 0580 INDJSR JSR DUMMY 0590 ; 3857 A967 0600 LDBSC LDA #SCRVEC SET UP ADDRESS 3859 8D2103 0610 STA $0321 TO "STEAL" SCREEN EDITOR 385C A938 0620 LDA #$38 VECTOR TABLE 385E 8D2203 0630 STA $0322 0640 ; 3861 A900 0650 LDA #$0 DUMMY VARIABLE FOR 3863 8DD638 0660 STA CMDLEN LENGTH OF BASIC COMMAND 0665 ; 3866 60 0670 RTS RETURN TO DOS 0680 ; 0067 0690 SCRVEC = *-$3800 3867 FBF3 0700 .DBYTE $FBF3 COPY OF SCREEN EDITOR 3869 33F6 0710 .DBYTE $33F6 VECTOR TABLE, EXCEPT 386B 7638 0720 .WORD SCRNWT WITH NEW SCREEN WRITE 386D A3F6 0730 .DBYTE $A3F6 386F 33F6 0740 .DBYTE $33F6 3871 3CF6 0750 .DBYTE $3CF6 3873 4CE4F3 0760 JMP SCRNRD 0770 ; 3876 0780 SCRNWT = * 3876 00 0790 .BYTE $0 3877 ACD638 0800 LDY CMDLEN NEW SCREEN WRITE ROUTINE 387A F009 0810 BEQ ENDBAS 387C B99138 0820 LDA BASCMD-1,Y WRITES THE STORED BASIC 387F CED638 0830 DEC CMDLEN COMMAND TO THE SCREEN 3882 A001 0840 LDY #1 3884 60 0850 RTS 0860 ; 3885 8C2103 0870 ENDBAS STY $0321 SETS UP VALUES FOR 3888 A9E4 0880 LDA #$E4 NORMAL RETURN 388A 8D2203 0890 STA $0322 388D A99B 0900 LDA #$9B 388F A001 0910 LDY #1 3891 60 0920 RTS 0930 ; 3892 0940 BASCMD = * STORAGE RESERVED FOR 3892 0950 *= *+$44 BASIC COMMAND 38D6 0960 CMDLEN = * LENGTH OF BASIC COMMAND 38D6 0970 .END
Back to previous page