APLawrence.com -  Resources for Unix and Linux Systems, Bloggers and the self-employed

netcat postscript printer

© December 2004 (various authors)

What is this stuff?

If this isn't exactly what you wanted, please try our Search (there's a LOT of techy and non-techy stuff here about Linux, Unix, Mac OS X and just computers in general!):

From: Jeff Liebermann <jeffl@comix.santa-cruz.ca.us>
Newsgroups: comp.unix.sco.misc
Subject: Re: netcat and postscript printing problem
Date: Thu, 01 Jun 2000 10:10:49 -0700
Message-ID: <b04djs455dunff3uhjh7l3aeu3os46vil5@4ax.com> 
References: <O4uZ4.3560$pk3.189459@bgtnsc04-news.ops.worldnet.att.net> 

On Thu, 01 Jun 2000 14:05:34 GMT, "Greg K." <NSOM@att.net> wrote:

>We are using netcat in our offices for dot matrix and one laser printer and
>haven't had any problems until we tried to install a postscript printer to
>print picking tickets and generally to replace expensive preprinted forms by
>using Planet Press 3 from Objectif Lune.

Netcat can work in two different ways as illustrated in:
in the "Testing from print spooler" and "Testing from command line"
1.  to use the stock SCO print spooler scripts or the netcat-hp print
spooler script that I supplied to do the printing.  This has the advantage
of allowing some post processing and sending the printer PCL commands to
setup page orientation, LPI, CPI, etc.  All this is completely wasted on a
Postscribble printer.
2.  from the command line with absolutely no post processing of the data.
Data goes in, the same thing goes to the printer.  This is what you want to
send to a Postscribble printer.

To test the command line, run:
  cat filename.ps | netcat -h mita1200 -p 9500
Duz it work?
The mita1200 is the hostname of the printer from /etc/hosts.  The 9500 is
whatever port number you assigned in the Axis 540 print server.  My use of
9101 and 9102 was a very bad idea(tm) because the 540+ print server uses
those for HP emulation.  Pick a different number if you have the 540+.  I'll
fix the Axis instructions when I drag myself to the office tonight.

>The printer is a Mita DP-1800 installed as Local with an Axis 540 print
>server in PCL6 mode.

https://www.kyoceramita.com/PDF/DP14001800.pdf  (3.4MB)

There's something basically wrong with sending Postscribble files to a
printer setup to recognize PCL6.  The Mita DP-1800 supports Postscribble 2.
Duz it properly autoswitch?  Probably not.  Are you doing anything in the
Axis 540 print server to tweak the output such as cr-lf translations?
Basically, the problem is that your printer is not properly autoswitching
between PCL and Postscribble.  It it printed the *TEXT* of the postscript
file, then netcat and the printer are working.  Force the printer to the PS
mode, and try again.  It should print the PS file.

Why are you using the external Axis 540 instead of the built in ethernet

>Being a SCO UNIX (V5.0.5) novice I'm wondering if
>during the netcat installation (script and binary), lp services were
>assigned to netcat with chgrp and chmod.

The installation of netcat was designed to not touch any SCO supplied
programs, services, directories, or sacred cows.  Everything is added,
nothing is changed.

>I'm guessing this because when I attempt to set up the Mita in scoadmin
>printer and select anything other than netcat as the model, print requests
>appear to be successful but no data is sent to the printer...it sits there
>saying its ready.

Sits where?  Try:
        lpstat -t
for a list of pending print jobs and printer status.  Look for disabled
printers or printers that are set to not accept jobs.  Cancel any pending
jobs with:
        cancel job-id-number
and start clean.

>When I select netcat as the model the print job is sent
>to the printer but the output consists of about 8 pages of letters and
>numbers with some readable script thrown in. (see a small sample below);

Yep.  That makes sense.  You printer is set to PCL6 (HP's printer control
language) and doesn't like Postscribble.  If the printer doesn't support
postscribble, you can always install "Ghostscript" which will convert
postscipt incantations to PCL.  Ghostscript can be found under:

>#sample print output
> %!PS-Adobe-2.0

>Is there any way to keep netcat so I don't have to use hpnpcfg and still set
>up the postscript printer?

I don't understand the question.  Each printer *NAME* in netcat is
completely independent of each other.  Different names can go to different
port numbers or with different filters and spooler scripts.  Lots of ways to
configure it.

>Sorry for the length of this...I'm trying to be brief but concise.  Thanks
>in advance for any help you all may be able to provide.

Hint:  Start with what you are trying to accomplish.  After that, explain
where you're stuck and how you got there.  Some clue as to how you currently
have it setup (with real IP's, names, and config exerts) would be nice.  A
URL pointing to the printer specifications would make research a bit easier.

Jeff Liebermann   jeffl@comix.santa-cruz.ca.us
150 Felker St #D  Santa Cruz CA  95060
831-421-6491 pager   831-429-1240 fax
https://www.cruzio.com/~jeffl/sco/   SCO stuff

Got something to add? Send me email.

(OLDER)    <- More Stuff -> (NEWER)    (NEWEST)   

Printer Friendly Version

-> netcat postscript printer ––>Re: netcat and postscriptprinting problem

Inexpensive and informative Apple related e-books:

Sierra: A Take Control Crash Course

Digital Sharing Crash Course

Take Control of Pages

iOS 10: A Take Control Crash Course

El Capitan: A Take Control Crash Course

Printer Friendly Version

Have you tried Searching this site?

This is a Unix/Linux resource website. It contains technical articles about Unix, Linux and general computing related subjects, opinion, news, help files, how-to's, tutorials and more.

Contact us

Printer Friendly Version

There are two ways to write error-free programs; only the third one works. (Alan Perlis)

Linux posts

Troubleshooting posts

This post tagged:


Unix/Linux Consultants

Skills Tests

Unix/Linux Book Reviews

My Unix/Linux Troubleshooting Book

This site runs on Linode

SCO Unix Sales, Support, & Service

Phone:  707-SCO-UNIX (707-726-8649Toll Free: 833-SCO-UNIX (833-726-8649)