- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: HP printer control sequence
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-26-2002 06:29 PM
06-26-2002 06:29 PM
HP printer control sequence
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-26-2002 06:37 PM
06-26-2002 06:37 PM
Re: HP printer control sequence
Do you mean to create a print queue? If so use either 'sam' or have alook at the man page for 'lpadmin'
Michael
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-26-2002 06:41 PM
06-26-2002 06:41 PM
Re: HP printer control sequence
Andy.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-27-2002 11:35 PM
06-27-2002 11:35 PM
Re: HP printer control sequence
Hi,
To add printer-control commands to the
print-job you must edit the model-script
for the printer. The model-script to
edit is found in /etc/lp/interface.
It has the same name as the queue-name for
the printer.
You will see that most model-scripts have
a lot of options (passed by using -o option
in the lp command)
It could be that what you are looking for
already is covered by an option.
Regards
Olav
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-28-2002 12:19 AM
06-28-2002 12:19 AM
Re: HP printer control sequence
First, getting PCL escape commands into a file, plus some examples:
The command that the printer needs for formatting or, adding carriage returns to
line feeds, is the PCL string:
ksh: print -n "\033&k2G" > afile
Inserted at the beginning of the ASCII text file, this will eliminate stair stepping.
Resetting printer:
ksh: print -n "\033E" > bfile
At the end to ensure that following jobs won't get fooled!
more pcl control codes (to combine codes use lower case on the final char):
portrait
landscape
symbol set ISO 8859-1
font courier
font arial
font times
primary pitch
Then I wrote a simple wrapper script (attached) that feeds lp the control codes and the file(s) to print. Not the worlds most elegant solution - but it works!
Robert
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-28-2002 12:30 AM
06-28-2002 12:30 AM
Re: HP printer control sequence
have a look at /usr/lib/lp/model/PCL5
There you can find many PCL escape sequences.
They are used with echo "\033&...."
The \033 represents the escape char in octal value (hex: 1b)
Regards