Commodore MPS 1000 — Commodore MPS 1000 Dot Matrix Printer User's Manual PDF

To see how more than one line combines to form a figure, enter and run the following program, which uses two of the lines you have already typed and adds several more. If you are using Commodore BASIC: 5 OPEN4,4 10 PRINT#4,CHR$(27)"1"; 20FORR= 1TO3 30 PRINT#4, CHR$(27)"K"CHR$(100)CHR$(0); 40FORX= 1TO50: PRINT#4, CHR$(85)CHR$(42); 50 NEXT X: PRINT#4 60 PRINT#4, CHR$(27)"K"CHR$(100)CHR$(0); 70FORX=1TO50: PRINT#4, CHR$(42)CHR$(85); 80NEXTX: PRINT#4: NEXTR 90 PRINT#4, CHR$(27)"@" 100 CLOSE4 If you are using Microsoft BASIC: 10 LPRINT CHR$(27)" 1"; 20FORR= 1TO3 30 LPRINT CHR$(27)"K"CHR$(100)CHR$(0); 40 FOR X = 1 TO 50: LPRINT CHR$(85 )CHR$( 42); 50 NEXT X:

LPRINT 60 LPRINT CHR$(27)"K"CHR$(100)CHR$(0); 70 FOR X = 1 TO 50: LPRINT CHR$(42)CHR$(85 ); 80 NEXT X: LPRINT: NEXT R 90 LPRINT CHR$(27)"@" Now run the program to see the six print lines combine into a pattern: This short and simple program that produced the pattern demon- suates many elements of graphics programming. Therefore, we'll explain each line. Line 10 changes the line spacing to 7-dot, which is the height of the dot patterns used in the program. Therefore, there is no space between the print lines. 87