Bob,

It's been a while since I did PostScript programming. PS doesn't have
PCL  type "commands", since PS is really a low-level graphics
programming language. So you actually have to *draw* the page using PS,
which means setting up your page coordinates and drawing each individual
object (characters, lines, ...) in there (which also means a lot of
computations to align & setup the objects) before sending it to the
printer. The printer interprets the PS program to re-draw the page in
its memory before printing. I'd guess that there are tools out there
that can provide higher level interfaces to PS that maybe better suited
to your needs (like text2ps?), but I can't point to any off the top of
my head.

BTW, PS uses postfix notation, so it takes a bit getting used to
programming with it.

-Nilanjan


-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On
Behalf Of R. Mariotti
Sent: Tuesday, November 06, 2007 12:11 PM
To: [email protected]
Subject: [Boston.pm] Send Setup commands to Brother HL5250 printer?

Fellow luggers;

I have a short perl program that prints labels n-up on standard letter 
sized pages (actually Panduit Labels).

This originally printed to an HP2600 printer which has since been 
retired and replaced with a Brother HL5250DN printer.

This printer is connected via CUPS on Linux so I am not sure if cups is 
converting the output to postscript or sending pcl.  The printer 
emulation is set to pcl (but I know it can change dynamically).

I have been trying to send pcl commands from my perl program to modify 
the offsets, margins, typeface, etc with NO success.

Therefore, has anyone printed such commands before and especially to 
this printer?

My method is really simple such as:

print OFH "\x1B\&a0L";    # Set Left Margin to Zero columns

When run the esc (x1B) is being eaten but the &a0L prints as text 
indicating that the printer is NOT recognizing it as a command.

That would indicate to me that cups is sending the output as postscript 
which switches the printer to PS mode so it would not intercept the pcl 
commands.

If that is true, can anyone PLEASE provide some equiv PS commands to set

  some of the parameters?  I've search the PS docs with no clear
examples.

Thanks in advance for any assistance.

Bob
 
_______________________________________________
Boston-pm mailing list
[email protected]
http://mail.pm.org/mailman/listinfo/boston-pm
 
_______________________________________________
Boston-pm mailing list
[email protected]
http://mail.pm.org/mailman/listinfo/boston-pm

Reply via email to