Installing a printer from the text terminal on Slackware. The printer is an old dot matrix machine (Star Micronics NX-1000, https://www.star-m.jp/eng/service/usermanual/nx1000um.pdf), and I am using a parallel-to-USB convertor; P/N: 810-00 and S/N: 02963.
Please note that this is just what I did — may not be the most efficient! May have redundant steps.
First, I got CUPS running.
As superuser (prompt = #):
# chmod +x /etc/rc.d/rc.cups
# /etc/rc.d/rc.cups restart
Then as regular user (prompt = $):
$ links -g http://localhost:631
but CUPS web interface does not seem to work with browser (links -g
) in terminal.
OK, we’ll use the lp tools. First, where is the printer attached? I have the printer turned on, plugged into the USB converter and the converter plugged into the computer. So:
# lpinfo -v
network ipps
network ipp
network beh
network https
network http
network socket
network lpd
direct usb://Unknown/Printer
network smb
OK, so it seems to be on ‘direct usb://Unknown/Printer’.
Next, what drivers do we have available?
# lpinfo -m | grep -i star
gutenprint.5.2://star-lp_8/expert Star LaserPrinter 8 - CUPS+Gutenprint v5.2.11
gutenprint.5.2://star-ls-04/expert Star LS-04 - CUPS+Gutenprint v5.2.11
OK, neither of those fits the bill. But the NX-1000 is closely compatible with the old Epson 9-pin drivers, so…
# lpinfo -m | grep -i Epson | grep -i pin
drv:///sample.drv/epson9.ppd Epson 9-Pin Series
drv:///sample.drv/epson24.ppd Epson 24-Pin Series
OK, I’m not familiar with that ‘drv:///’ notation, but let’s try using lpadmin with that:
# lpadmin -p star -m drv:///sample.drv/epson9.ppd -D "Star NX-1000 as Epson 9-pin" -E -v usb://Unknown/Printer
What’s this?
- -p star — gives the name of the printer that we will use to specify it in print commands
- -m drv:///etc — specifies the driver to use
- -D — gives a readable description in quotes “Star …”
- -E — enables the printer — important!
- -v usb://Unknown/Printer — this is the deVice the printer is attached to
OK, now … does it work?
Let’s print this very file (scan thresholded):
$ lp -d star this_very_file.txt
Yep! It’s using some kind of default font that the printer is printing like graphics — it is not using the native printer fonts, like you would get in DOS if you just copied a text file to the printer.
Now, I printed as a user, not superuser. So, let’s just check what groups the user belongs to:
$ groups
users lp floppy dialout audio video cdrom plugdev power netdev scanner
And we can see the lp group is in there — probably important!
Then I went to use the printer via the GUI and the test page looked fine (scan thresholded):
(Please keep in mind the ribbon was dead and has been resurrected with WD40, which mobilises the ink and lets the ink from the unused edges move to where it can be useful, but which I may have done a bit heavily…)
Here’s a page printed from Okular (PDF viewer).
Can I sent text to it directly? Which /dev is it?
No entries including lp under /dev…
Well, if I use lpoptions to set star as default, I can use lpr and suchlike to print. Still not sure how to send raw stuff straight to the printer…
But OK.