Path: utzoo!news-server.csri.toronto.edu!cs.utexas.edu!ut-emx!ccwf.cc.utexas.edu From: andy@ccwf.cc.utexas.edu (Andrew Hackard) Newsgroups: comp.sys.cbm Subject: Re: printing in direct mode? Summary: tell printer not to expect more data Keywords: help Message-ID: <45557@ut-emx.uucp> Date: 13 Mar 91 21:27:07 GMT References: <1991Mar13.161420.28673@cbnews.att.com> Sender: news@ut-emx.uucp Reply-To: andy@ccwf.cc.utexas.edu (Andrew Hackard) Distribution: na Organization: The University of Texas at Austin, Grackle Assault Team Lines: 35 In article <1991Mar13.161420.28673@cbnews.att.com> ewm@cbnews.att.com (edward.w.mcfarland) writes: [stuff deleted] > For printing I am using the method that is mentioned in the C64 >owners manual, ie. OPEN4,4,4 > CMD4: > CLOSE4,4,4 > [more stuff deleted] >Anyone know a better method than the above for printing in direct mode? > >Thanks, > Ed McFarland > ewm@mvuzr.att.com Looks good, except that you have to remember to close out the channel properly, something I've only seen explained clearly a couple of times. What this boils down to is that you have to send a blank line after you have finished printing your text, which somehow tells the printer you're through with it. (Also, if you're shooting for lowercase, Commodore printers use a 7 as the last digit in the OPEN; your interface may be different if you're using a non-CBM printer.) Couple of examples:1)Listing a file to the printer OPEN 4,4,7:CMD4:LIST PRINT#4:CLOSE4 2)Printing OPEN 4,4,7:CMD4 PRINT"Your message here..." PRINT#4:CLOSE4 Hope this helps. --Andrew Hackard andy@ccwf.cc.utexas.edu P.S. Remember, PRINT# is abbreviated pR (p SHIFT-r), not ?#.