Epson LQ-850X User Manual - Page 132
A Simple Graphics Program, Line 20 selects single-density 24-pin graphics mode mode 32
View all Epson LQ-850X manuals
Add to My Manuals
Save this manual to your list of manuals |
Page 132 highlights
For example, if you wish to send 1632 columns of graphics data, n1 should be 96 and n2 should be 6 because 1632 = 96 + (6 x 256). The printer interprets the number of bytes specified by n1 and n2 as graphics data, no matter what codes they are. This means that you must be sure to supply enough bytes of graphics data or the printer will stop and wait for more data and will seem to be locked. If, on the other hand, you supply too much graphics data, the excess will be interpreted and printed as regular text. A Simple Graphics Program This first program is just a simple example to show you how the graphics command, column reservation numbers, and data can be used in a BASIC program. Type in and run the following program. Be especially careful to include both semicolons. The program produces the printout you see below: 10 WIDTH "LET:".255 20 LPRINT CHR$(27)"*"CHR$(32)CHR$(40)CHR$(0); 30 FOR X-1 TO 120 40 LPRINT CHR$(170); 50 NEXT X Line 20 selects single-density 24-pin graphics mode (mode 32) and also reserves 40 columns for graphics. Since 24-pin graphics requires three bytes of data for each column, line 30 begins a loop to supply 120 bytes of data. Line 40 contains the number 170, which produces the first pin pattern shown in the section on pin labels, and line 50 ends the loop. 4-16 Software and Graphics