Mercurial > hg > Members > kono > os9 > sbc09
comparison os9/level2/cmds/fixbasic.pl @ 97:5aeff8abca9c
add echo control on sbc09
author | Shinji KONO <kono@ie.u-ryukyu.ac.jp> |
---|---|
date | Thu, 27 Dec 2018 01:17:31 +0900 |
parents | f20bf9874697 |
children |
comparison
equal
deleted
inserted
replaced
96:6ff8754c9749 | 97:5aeff8abca9c |
---|---|
1 #!/usr/bin/perl | 1 #!/usr/bin/perl |
2 # | 2 # |
3 # | |
4 # the basic source include direct ACIA access | |
5 # which is not allowed in OS-9 | |
6 # sbc09 emulator on OS-9, echos input in default | |
7 # the basic assumes input has no echo, so call echo | |
8 # off at initialization | |
3 | 9 |
4 while(<>) { | 10 while(<>) { |
5 next if (/^ACIA/ .. /^TDRE/) ; | 11 next if (/^ACIA/ .. /^TDRE/) ; |
6 next if (/^TSTBRK/ .. /^ END/) ; | 12 next if (/^TSTBRK/ .. /^ END/) ; |
7 if (/^CLEAR/) { | 13 if (/^CLEAR/) { |
8 print <<"EOFEOF" | 14 print <<"EOFEOF"; |
9 JSR \$24 ;; echo off (but it is not suuported on pty.asm ) | 15 JSR \$24 ;; echo off |
10 EOFEOF | 16 EOFEOF |
11 } | 17 } |
12 if (/^GL02/) { | 18 # if (/^GL02/) { |
13 print "GL02\n"; # do not echo input | 19 # print "GL02\n"; # do not echo input |
14 next; | 20 # next; |
21 # } | |
22 if (/FDB\s+CLEAR/) { | |
23 print; | |
24 print <<"EOFEOF"; | |
25 FCC /BYE/ | |
26 FCB EOL | |
27 FDB EXIT | |
28 EOFEOF | |
29 next; | |
15 } | 30 } |
16 print; | 31 print; |
17 } | 32 } |
18 | 33 |
19 | 34 print <<"EOFEOF"; |
20 print <<"EOFEOF" | 35 EXIT |
36 JSR \$24 ;; echo off | |
37 JSR \$27 ;; echo on | |
38 JMP \$2a ;; exit | |
39 | |
21 ****************************** | 40 ****************************** |
22 ****************************** | 41 ****************************** |
23 TSTBRK bsr BRKEEE | 42 TSTBRK bsr BRKEEE |
24 bcc GETC05 | 43 bcc GETC05 |
25 GETCHR bsr INEEE | 44 GETCHR bsr INEEE |
45 PULS D,PC | 64 PULS D,PC |
46 ****************************** | 65 ****************************** |
47 ****************************** | 66 ****************************** |
48 END | 67 END |
49 EOFEOF | 68 EOFEOF |
69 |