Epson MX-70 User Manual - Page 92

Tricky Codes, Screen Width Versus Printer Width

Page 92 highlights

Appendix F Tricky Codes Most Apple users will encounter difficulty when using codes 9 and 13 in ESCAPE sequences and the graphics mode. To corral these and other rowdy codes, we can POKE the ASCII code numbers directly to the printer driver. Use: POKE 49296,9 in place of PRINT CHRS(9) Unfortunately, using the POKE statement instead of PRINT creates timing problems between the printer and computer. To avoid such complications, the POKE should always be followed by a test of the printer to see if it is ready for more DATA. On the Apple, this is done with a PEEK statement. Example: 10 PR#l 20 POKE 49296,9 30 IF PEEK (49601)

  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 8
  • 9
  • 10
  • 11
  • 12
  • 13
  • 14
  • 15
  • 16
  • 17
  • 18
  • 19
  • 20
  • 21
  • 22
  • 23
  • 24
  • 25
  • 26
  • 27
  • 28
  • 29
  • 30
  • 31
  • 32
  • 33
  • 34
  • 35
  • 36
  • 37
  • 38
  • 39
  • 40
  • 41
  • 42
  • 43
  • 44
  • 45
  • 46
  • 47
  • 48
  • 49
  • 50
  • 51
  • 52
  • 53
  • 54
  • 55
  • 56
  • 57
  • 58
  • 59
  • 60
  • 61
  • 62
  • 63
  • 64
  • 65
  • 66
  • 67
  • 68
  • 69
  • 70
  • 71
  • 72
  • 73
  • 74
  • 75
  • 76
  • 77
  • 78
  • 79
  • 80
  • 81
  • 82
  • 83
  • 84
  • 85
  • 86
  • 87
  • 88
  • 89
  • 90
  • 91
  • 92
  • 93
  • 94
  • 95
  • 96
  • 97
  • 98
  • 99
  • 100
  • 101
  • 102
  • 103
  • 104
  • 105
  • 106
  • 107

Appendix F
Tricky Codes
Most Apple users will encounter difficulty when using codes 9 and 13 in
ESCAPE sequences and the graphics mode. To corral these and other rowdy
codes, we can POKE the ASCII code numbers directly to the printer driver. Use:
POKE 49296,9
in place of
PRINT CHRS(9)
Unfortunately, using the POKE statement instead of PRINT creates timing
problems between the printer and computer. To avoid such complications, the
POKE should always be followed by a test of the printer to see if it is ready for
more DATA. On the Apple, this is done with a PEEK statement. Example:
10
PR#l
20
POKE 49296,9
30
IF PEEK (49601)
<O
GOT0
30
40
PR#O
If the value stored at location 49601 (ClCl Hex) is negative, the printer has not
yet picked up the DATA and stored it in its buffer. If location 49601 is positive,
the printer is ready to receive more DATA. By using this test we outflank the
funny code numbers like 9 and 13.
Screen Width Versus Printer Width
The Apple video screen display is limited to 40 characters per row. Unfortu-
nately, it restricts the printer line width to the same 40 characters during BASIC
program listings unless we take evasive action. Fortunately, the solution is
simple.
If we send this code sequence down the line:
(Don’t do it yet - wait for below)
<CTRL I> 80 N
the printer line width becomes the full 80 columns used by standard printer
paper. The “80” can be any number from 40 to 255 as far as the Apple is
concerned. The MX-70 might have different ideas.
92