Want to Print Plain ASCII TEXT
Topic: Want to Print Plain ASCII TEXT
started by: Ankuryu
Posted by Ankuryu on Mar. 25 2006,06:53Dear Membars,
I would like to print plain ASCII Text with the program sending the necessary ESC codes for formatting. Is this possible ? I have installed cups.dsl however the printing is done as in windows, (Graphic Mode of the printer) What I want is plain ASCII Mode to print various Bill / Ledgers etc.
Can anyone help me please
Posted by cbagger01 on Mar. 26 2006,04:56Maybe you can print directly to the parallel port, like this:
cat my_ascii_file.txt > /dev/lp0
Posted by Ankuryu on Mar. 27 2006,06:28Yeah I have managed to Do that, however how do I print from the programs. Like I want to use the Linux box as a File Printer Server. So the printer shall be used by various clients. How do I go about setting up the printer.
I have managed to create a [Printer1] share
but how does one linke it with the plain driver ?
Sorry for the trouble
Posted by Ankuryu on Mar. 28 2006,09:28I can print using the lpr command logged in as DSL on the Linux Box. However when I launch Samba , I can see the printer on my windows 2000 computer, however it gives the mssage "Access Denied, Cannot connect"
I have created a section in smb.conf as follows
comment = All printers
path = /usr/spool/samba
browseable = no
set public = yes
guest ok = yes
writeable = no
printable = yes
I even later on added the following command to the above section
print command = lpr %p %s
can anyone help ?
Posted by dtf on Mar. 28 2006,13:00I am not an expert but here is what I found when trying to setup a similar configuration.
Check your security assignment in the global section. Is it set to user (I don't know what the default is but I would guest it is user)? If so they you will need to login from the windows machine. You can try setting security to share (which is not recommended because of security concerns). This will at least let you test printing from the windows machine. If you want to login in from the windows machine it is important to set encrypt passwords = yes and point to the password file like; smb passwd file = /etc/samba/smbpasswd.
You need to add the user using smbpasswd (not exactly sure that is the correct spelling).
One thing I never was able to figure out was how to get a login prombt when accessing my printer. I had to log into my file system share then once I was in I could use the printer. In the end I gave up and just set my security share but restrict the user ip to my local network with something like; hosts allow = 192.168.100.0/24 127.0.0.1. I am sure this breaks a dozen or so rules.
I found using samba printing works well but I do it slightly differently.
I have installed the printer using CUPS and use the following command.
print command = lp -d kinux_printer -o raw %s
This allows me to install the print driver on the windows machine which has a driver to match my printer where as DSL and CUPS do not.
This works well in my home with 4 users and a mix of computers running different Operating Systems.