Download Print this page

Epson MX-80 User Manual page 64

Hide thumbs Also See for MX-80:

Advertisement

Chapter 9
ght! The first 3 categories are present. Now, what coding scheme does each
-^category represent?
1. Greater than 100: Reserved for graphic characters. 32 added to the
number (for ASCII offset) and printed. Users in restricted TRS-80 mode
(SW# 2-4 ON), must remove the +32 in lines 20 & 30.
2. Between 0 and 100: Reserved for the "counter" in STRINGS. If " A "
reads a "counter", "B" then reads next DATA number which will be
>100, thus graphic. STRINGS prints B+32 a total of A times.
3. 0: Signals a CR and LF via a plain old LPRINT.
4. If none of above, defaults to line 50 which converts negative value to
positive, then ON-GOSUB to a print line (which we have yet to type in).
Even tho we haven't yet completed the program, isn't the logic flow nice and easy
to follow?
Micro-Analysis
Let's now go inside DATA line 90 and see what is being READ into the logic
system we examined above.
90 DATA
1 5 1 , 1 6 3 , 1 5 9 , 1 7 5 , 1 4 7 , 1 6 3 , 1 4 7 , 1 9 , 1 3 1 , 1 7 1 , 0
One Piece of Data At a Time
151 is a graphics character. 151 + 32 = 183. Check Appendix G to see
what it should look like.
Using the Editor, change(C) the comma following 1 5 1 in line 90 to a colon,
making it look like this
90 DATA 1 5 1 : 1 6 3 , 1 5 9 , 1 7 5
. . . .
e t c .
and RUN.
r
F i g u r e 7-5
Sure enuf, that's what we get.
Again using the Editor, move the colon to after the 163. Replace the comma
after 151.
What does ASCII 163 stand for? 163+32 = 195.
now RUN, READing 2 pieces of DATA
66

Advertisement

loading