- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Spooler - Append Form Feed
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
03-31-2005 01:37 AM
03-31-2005 01:37 AM
0. The printer prints but we need a form-feed after each greenbar print job.
1. The OS's are... HP-Ux v10, v11
2. The Printronix P300 tech manual indicates that the top of form command is... ^P
3. Without any luck, I have been thrashing with...
cat - | lp -d greenbar | ^P
cat - | lp -d greenbar | "^P"
cat - | lp -d greenbar | echo -n ^P
cat - | lp -d greenbar | echo -n "^P"
--Bill
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-31-2005 01:52 AM
03-31-2005 01:52 AM
Re: Spooler - Append Form Feed
If files are coming from microsoft world, you may want to do dos2ux on those files.
If that does not help, How is this printer configured?? JetAdmin, network or remote??
If remote you can not do anything from OS side. If Jetadmin/Network, check the interface file and modify it to send form feed to the printer.
Anil
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-31-2005 01:57 AM
03-31-2005 01:57 AM
Solution(cat - ; echo "\f\c") | lp -dgreenbar
or
(cat mytextfile; echo "\f\c") | lp -dgreenbar
"\f" is echo speak for FF.
You might find it easier to modify the printer's interface file to append the FF so that you don't have to add it to the lp command each time.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-31-2005 04:06 AM
03-31-2005 04:06 AM
Re: Spooler - Append Form Feed
At the bottom of the dumb printer script, you'll see:
cat "$file" 2>&1
echo "\014\c"
The cat command sends the file to the printer and the echo "\014\c" sends the ASCII code FF (formfeed) to the printer. (the man page for ascii calls 014 the np or newpage character) FormFeed is the classic (more then 20 years) method to eject the paper and works on every HP printer, LaserJet, DeskJet, even the old impact printers. 014 means octal 14 and comes from CTRL-L on a typical keyboard.
CTRL-P produces octal 020 which is the DLE character (see man ascii) so you can code this as: echo "\020\c" The \c in the echo suppresses the appending of CR/LF to the end of the string. So you can just change the end of the script in /etc/lp/interface from 014 to 020.
Now I mention the formfeed character because using DLE (Data Link Escape) is defined as: "A transmission control character that changes the meaning of a limited number of contiguously following characters or coded representations." which is ASCII-speak for a character that tells the device to change how it looks at subsequent chaarcter strings, similar to the ESC (Escape chaarcter). Since DLE is unusual as a form feed control, I would test that CTRL-P actually does produce a form feed. Try this:
echo "test\020" | lp -d greenbar
If this produces a form feed, then it is the correct character. If that doesn't work, use:
echo "test\014" | lp -d greenbar
and if that works, all is well and your printer should be ejecting paper at thye end of the job. Since it isn't, you may have to describe your connections (parallel, serial, remote, network, etc).
Bill Hassell, sysadmin
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-31-2005 10:30 AM
03-31-2005 10:30 AM
Re: Spooler - Append Form Feed
Problem solved. Clay's fix nailed it.
Thanks to Clay, Bill, and RAC.