Star Micronics XB24-15 Patches necessary to use the BASIC interpreter, Monochrome display

Models: XB24-15 XB24-10

1 140
Download 140 pages 17.48 Kb
Page 111
Image 111
Patches necessary to use the BASIC interpreter

Of course, many more facilities are available with the printer, but this may give you some ideas as to how you can drive the printer using your own programs.

Patches necessary to use the BASIC interpreter

When using the Microsoft BASIC interpreter usually supplied with PCs and compatibles, a number of problems may arise. Firstly, if the interpreter transmits a carriage return (ODh) character to the printer, it automatically transmits a line feed as well. Secondly, the BASIC interpreter will not transmit EOF markers (1Ah) at all. Normally, this will not cause problems, but if such a character is included in a character definition or graphic data string, problems may occur. To get round these two problems, the use of the following subroutine patches is recommended:

1260 LPRINT H$;F$; :I=13 :GOSUB5000 :LPRINT"CODE 39";

Monochrome display

5000 ’

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

5020 OUT &H3BC,I :OUT &H3BE,5 :OUT &H3BE,4

5030 RETURN

Color display

5000 ’

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

5020 OUT &H378,1 :OUT &H37A,5 :OUT &H37A,4 SO;0 RETURN

Call these subroutines when downloading characters or bit-image data, instead of using an LPRINT CHR$(I) statement. For other languages, check the documentation to see how the compiler/interpreter handles end-of-line and end-of-file characters.

NOTE

Thesepatchesareonly for use with MicrosoftBASIC interpretersunderPC-DOS or MS-DOS on PCs/PC-ATs or compatibles. They will not work with other languages, machines and/or operating systems.

103

Page 111
Image 111
Star Micronics XB24-15, XB24-10 Patches necessary to use the BASIC interpreter, Monochrome display, Color display