Example: 10 DATA 28 , 34 ,65,65 ,54,34,0,0 20 OPEN 5,4,5 30 FOR I= 1 TO 8:READ A:A$ =A$+ CHR$(A):NEXT I 40 PRINT#5 ,A$ 50 OPEN 4,4 60 FOR I= 1 TO 10 70 PRINT#4,CHR$(14)CHR$(254)" (CURSOR UP)C(CUR- SOR DOWN)OMMODORE(CURSOR UP) B(CURSOR DOWN)USINESS (CURSOR UP)M(CURSOR DOWN)A- CHINES'' 80 NEXTI 90 CLOSE 5 100 CLOSE4 The following is a description of the program shown above: Line No. 20 OPEN 5,4,5 L Communicates to the primer whar funcrion you want executed. A secondary address of 5 indicates that you want something stored in the printer's custom character buffer.
The device number (the printer' s) The logical file number 30 The FOR/NEXT loop contained in this line reads the data contained in line 10 and constructs a string A$. contains the necessary information to print the Commodore logo. 40 Stores in printer memory. 50 Opens the print file for printing. 55