95

If you want to print more characters using the < ESC > “\” command you must tell the printer how many characters should be printed. The total number of characters is equal to nl +

(~22 x 256).

For example, if you want to print 300 characters, nl = 44 and n2 = 1 (300 = 44 + 1 x 256), the control code will be the following:

< ESC > “\” CHR$(44) CHR$(l)

There is one more command to print a character in the control code area: < ESC > “A” n. This command prints one character determined by the value of ~1.You’ll get the same results as shown above with the following program.

10 ’ Demo of one character print

20FOR I=0 TO 31

30 LPRINT CHR$(27);"-";

40 LPRINT CHR$(I);

50 NEXT I

60LPRINT

70END

A note for IBM-PC users:

When you run these programs, you cannot get the right-pointed arrow (CHR$(26)) with the IBM-PC computer. Tlnis is because the IBM-PC does not send this code to the printer.

To avoid this problem, change line 40, and add lines 100 and 120 to either of the following lists.

40GOSUB 100

100 O=INP(&H379) : IF 0<128 THEN 100

110 OUT &H378,1 : OUT &H37A,5 : OUT &H37A,4

120RETURN

40GOSUB 100

100 O=INP(&H3BD) : IF 0<128 THEN 100

110 OUT GH3BC.I : OUT &H3BE,5 : OUT &H3BE,4

120RETURN

Page 101
Image 101
Star Micronics NR-15, NR-10 user manual Lprint CHR$I Next