4E6F | FD2A8312 | 0570 | | LD IY, (TEXT) | ; ZERO POINTER |
4E73 | FDE5 | 0580 | IN3 | PUSH IY | ; CALCULATE ADDRESS |
4E75 | E1 | 0590 | | POP HL | |
4E76 | ED4B8312 | 0600 | | LD BC, (TEXT) | ; BASE ADDRESS |
4E7A | B7 | 0610 | | OR A | ; RESET CARRY FLAG |
4E7B | ED42 | 0620 | | SBC HL, BC | ; SUB. BASE ADD. |
4E7D | DF66 | 0630 | | SCAL TBCD3 | ; PRINT ADDRESS |
4E7F | DF63 | 0640 | IN0 | SCAL INLIN | ; INPUT LINE |
4E81 | CDBB4E | 0650 | | CALL NUM16 | ; GET ADD. IN BC |
4E84 | FD2A8312 | 0660 | | LD IY, (TEXT) | ; CALCULATE PROPER |
4E88 | FD09 | 0670 | | ADDIY, BC | ; ADDRESS |
4E8A | 1A | 0680 | IN1 | LD A, (DE) | ; GET CHARACTER |
4E8B | FE20 | 0690 | | CP ' ' | ; A SPACE? |
4E8D | 2003 | 0700 | | JR NZ COMND | ; IF NOT, JUMP |
4E8F | 13 | 0710 | | INC DE | ; TRYNEXT |
4E90 | 18F8 | 0720 | | JR IN1 | ; CHARACTER |
4E92 | FE2E | 0730 | COMND | CP '.' | ; END OF PROGRAM |
4E94 | 284D | 0740 | | JR Z, END | |
4E96 | B7 | 0750 | | OR A | ; END OF LINE? |
4E97 | 28DA | 0760 | | JR Z, IN3 | ; GET NEXT LINE |
4E99 | FE2B | 0770 | | CP '+' | ; RELATIVE NUMBER? |
4E9B | 2014 | 0780 | | JR NZ, IN2 | ; IF NOT, 8 BIT NO. |
| | 0785 | ; |
| | 0790 | ; IF YES, THEN INPUT A 16 BIT NUMBER |
| | 0800 | ; AND ADD OFFSET TO PROPER ADDRESS |
| | 0805 | ; |
4E9D | 2A8312 | 0810 | | LD HL, (TEXT) | ; GET BASE ADD. |
4EA0 | 13 | 0820 | | INC DE | ; START OF NUMBER |
4EA1 | CDBB4E | 0830 | | CALL NUM16 | ; OFFSET IN BC |
4EA4 | 09 | 0840 | CHK | ADD HL, BC | ; CALCULATE ADDRESS |
4EA5 | FD7500 | 1010 | | JR NZ, ERROR | ; IF NOT, ERROR |
4ECC | C9 | 1020 | | RET | ; RETURN |
4ECD | DF64 | 1030 | NUM8 | SCAL NUM | ; GET 8 BIT NUMBER |
4ECF | 380C | 1040 | | JR C, ERROR | ; ERROR DETECTED |
4ED1 | ED4B210C | 1050 | | LD BC (NUMV) | ; GET NUMBER |
4ED5 | 3A200C | 1060 | | LD A, (NUMN) | ; CORRECT LENGTH? |
4ED8 | FE02 | 1070 | | CP 2 | ; TWO CHARACTERS |
4EDA | 2001 | 1080 | | JR NZ, ERROR | ; IF NOT, ERROR |
4EDC | C9 | 1090 | | RET | ; RETURN |
4EDD | ED53290C | 1100 | ERROR | LD (CURSR), DE | ; POSITION CURSOR |
4EE1 | 189C | 1110 | | JR IN0 | ; RE-INPUT LINE |
4EE3 | EF | 1120 | END | RST 40 | ; PRINT STRING |
4EE4 | 416E6F74 | 1130 | | DEFM "ANOTHER COMMAND (Y/N)" |
4EFB | 1100 | 1140 | | DEFB CUL, 0 | |
4EFD | DF7B | 1150 | END0 | SCAL BLINK | ; GET ANSWER |
4EFF | FE59 | 1160 | | CP 'Y' | ; IS IT 'YES' |
4F01 | 2008 | 1170 | | JR NZ, END1 | |
4F03 | F7 | 1180 | | RST CRT | ; PRINT IT |
4F04 | FD228312 | 1190 | | LD (TEXT), IY | ; RESET POINTER |
4F08 | C3004E | 1200 | | JP LOADR | ; AND CONTINUE |
4F0B | FE4E | 1210 | END1 | CP 'N' | ; ANSWER NO? |
4F0D | 20EE | 1220 | | JR NZ, END0 | ; INPUT AGAIN |
4F0F | F7 | 1230 | | RST CRT | ; PRINT N |
4F10 | FDE5 | 1240 | | PUSH IY | ; TRANSFER TO HL |
4F12 | E1 | 1250 | | POP HL | |
4F13 | 7D | 1260 | | LD A, L | ; IS IT ON A PAGE |
4F14 | B7 | 1270 | | OR A | ; BOUNDARY? |