Reply Return to Index Previous Next

Unixguide.net

Re: Unix Printer
By:Hussain Shabbir
Date: Tuesday, 11 July 2000, at 11:06 pm

If you want to print to a terminal attached printer,
you have to send an ESC code to tell your terminal
to redirect your output to the printer.

1. create a script called pass_print

vi pass_print
------------------------------------
#!/bin/sh
tput mc5 # turn on printer

cat $0

tput mc4 # turn off printer

-------------------------------
2. Make it executable

chmod +x pass_print

--------------------------------
3. To print myfile type

pass_print myfile

-----------------------------------
Note:

If you run tput mc5 interactively, you will lose
any output from your terminal. Type tput mc4 to regain
terminal output.


see terminfo for more information.

Codes for vt100 terminals

mc4=\E[4i
mc5=\E[5i,

: I need help configuring my printer on unix.The scenario is like this: The sever is at location X on a network.At location Y is a terminal and printer connected by high speed dialup lines.But the printer is not printing.The terminal on location Y is able to login but the printer does not respond to the print command either from location Y or location X where the server is.Need help urgently.And I shall be grateful to anyone who helps.






UNIXguide.net
English to Visayan Cebuano Dictionary

Find: Display: hits per page

Suggest a Site
Visayan Cebuano to English Dictionary