Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
printer installation
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware
View previous topic :: View next topic  
Author Message
mtPete
n00b
n00b


Joined: 20 Jul 2002
Posts: 40

PostPosted: Tue Nov 05, 2002 6:37 am    Post subject: printer installation Reply with quote

I have been having a hell of a time getting cups to work, so I figured I had better make sure my printer really is being recognized correctly.

dmesg turns up this:

Code:
parport0: PC-style at 0x378 [PCSPP,TRISTATE,EPP]
parport0: Printer, Canon BJC-2000
.
.
.
parport0: no more devices allowed
lp: driver loaded but no devices found


from that I assumed my printer was working. But doing the following from the Gentoo Printing Guide fails:

Code:

bash-2.05a# cat temp.txt
Hello World
bash-2.05a# cat temp.txt > /dev/parport0
cat: write error: Invalid argument
bash-2.05a# cat temp.txt > /dev/parports/0
cat: write error: Invalid argument
bash-2.05a# cat temp.txt > /dev/lp0-     
bash: /dev/lp0-: No such device or address
bash-2.05a# cat temp.txt > /dev/lp0
bash: /dev/lp0: Permission denied


I have no lp0. I have parport0 which is a sym link to parports/0 (are 0-15). There are also lp0- lp1- lp2-.

So I'm not really sure what to do. Any help will be appreciated.
Back to top
View user's profile Send private message
absi
n00b
n00b


Joined: 06 Nov 2002
Posts: 6

PostPosted: Wed Nov 06, 2002 12:25 am    Post subject: re: printer installation Reply with quote

I guess you compiled parport and lp support in the kernel:

Quote:

parport0: PC-style at 0x378 [PCSPP,TRISTATE,EPP]
parport0: Printer, Canon BJC-2000


OK, he found your parport!


Quote:

parport0: no more devices allowed
lp: driver loaded but no devices found


parport0 has already a device attached to it! This could be caused by having some I2C-settings you don't need!
Try compiling parport and lp as modules or post your complete dmesg, so that we can figure out what other device disturbs parport here!

For testing the printer a simple
Code:

echo "Hello printer" > /dev/lp0

is enough! Don't forget to press "Form Feed" on your printer after that, otherwise it would wait for more text to follow!

HTH,
absi
Back to top
View user's profile Send private message
mtPete
n00b
n00b


Joined: 20 Jul 2002
Posts: 40

PostPosted: Wed Nov 06, 2002 6:03 am    Post subject: Reply with quote

Hey thanks for the reply.

I did as you said, but hitting the form feed button produced no responce.

Code:

bash-2.05a# echo "hello printer" > /dev/parport0
bash-2.05a#

bash-2.05a# echo "hello printer" > /dev/lp0
bash: /dev/lp0: Permission denied
bash-2.05a# echo "hello printer" > /dev/lp0-
bash: /dev/lp0-: No such device or address
bash-2.05a#


From what I can see in /dev I have a lp0- but no lp0.

What follows is a larger portion of the results of dmesg (if anyone things the whole thing would be usefull I'll post that, but in the interests of space I'll refrain for now).


Code:

parport0: PC-style at 0x378 [PCSPP,TRISTATE,EPP]
parport0: Printer, Canon BJC-2000
i2c-core.o: i2c core module
i2c-dev.o: i2c /dev entries driver module
i2c-core.o: driver i2c-dev dummy driver registered.
i2c-algo-bit.o: i2c bit algorithm module
i2c-philips-par.o: i2c Philips parallel port adapter module
i2c-philips-par.o: attaching to parport0
i2c-dev.o: Registered 'Philips Parallel port adapter' as minor 0
i2c-core.o: adapter Philips Parallel port adapter registered as adapter 0.
i2c-elv.o: i2c ELV parallel port adapter module
i2c-velleman.o: i2c Velleman K8000 adapter module
i2c-velleman.o: Port 0x378 already in use.
i2c-algo-pcf.o: i2c pcf8584 algorithm module
i2c-proc.o version 2.6.1 (20010825)
keyboard: Timeout - AT keyboard not present?(ed)
keyboard: Timeout - AT keyboard not present?(f4)
pty: 256 Unix98 ptys configured
Serial driver version 5.05c (2001-07-08) with MANY_PORTS SHARE_IRQ SERIAL_PCI ISAPNP enabled
ttyS00 at 0x03f8 (irq = 4) is a 16550A
PCI: Found IRQ 9 for device 02:0b.0
PCI: Sharing IRQ 9 with 00:1f.2
Redundant entry in serial pci_table.  Please send the output of
lspci -vv, this message (12b9,1008,12b9,baba)
and the manufacturer and name of serial board or modem board
to serial-pci-info@lists.sourceforge.net.
ttyS04 at port 0xdfe0 (irq = 9) is a 16550A
parport0: no more devices allowed
lp: driver loaded but no devices found
Back to top
View user's profile Send private message
absi
n00b
n00b


Joined: 06 Nov 2002
Posts: 6

PostPosted: Thu Nov 07, 2002 1:07 am    Post subject: Reply with quote

mtPete wrote:


I did as you said, but hitting the form feed button produced no responce.

Code:

bash-2.05a# echo "hello printer" > /dev/lp0


From what I can see in /dev I have a lp0- but no lp0.


Yeah, you should have done that after the other modifcation i told you!

mtPete wrote:


What follows is a larger portion of the results of dmesg (if anyone things the whole thing would be useful I'll post that, but in the interests of space I'll refrain for now).
Code:

parport0: PC-style at 0x378 [PCSPP,TRISTATE,EPP]
parport0: Printer, Canon BJC-2000
[...]
i2c-philips-par.o: i2c Philips parallel port adapter module
i2c-philips-par.o: attaching to parport0
i2c-dev.o: Registered 'Philips Parallel port adapter' as minor 0
i2c-core.o: adapter Philips Parallel port adapter registered as adapter 0.
i2c-elv.o: i2c ELV parallel port adapter module
[...]
parport0: no more devices allowed
lp: driver loaded but no devices found


Thats enough of dmesg - thx!
parport0: this 2 lines are ok!
i2c-*: this are your problems! your compiled some Philips adapter module into the kernel, but you don't need it! You have to do recompile your kernel without this settings!! You know how to do this?
The last two lines say, that there is already a device attached to the parport - the i2c-philips! If this is removed from the kernel, everything will be OK!

Greetz,
absi
Back to top
View user's profile Send private message
mtPete
n00b
n00b


Joined: 20 Jul 2002
Posts: 40

PostPosted: Thu Nov 07, 2002 2:48 am    Post subject: thanks Reply with quote

I see it now. I'll try that, it looks like that should do the trick. I'll have time to recompile the kernel this weekend so I'll report back then.

Ya, I didn't recompile with modules because I like to compile things in, less hassle with modules. That and I really don't like to recompile unless I have a good reason because I am short on time (college keeps me busy). I'm not sure what the Phillips Parallel port adapter would do, but I think that was just one of those things that sounded like it might be usefull. Gentoo doesn't really have a good description of what all the kernel options are for so its sort of a trial and error thing.

Any idea why the kernel only lets one thing register with the parallel port? What would happen if you had a printer and another parallel port device you used (say you swapped them or had them on a switch)?

Thanks for the help, I've been at witts end trying to get printing working.
Back to top
View user's profile Send private message
mtPete
n00b
n00b


Joined: 20 Jul 2002
Posts: 40

PostPosted: Thu Nov 14, 2002 8:30 am    Post subject: Reply with quote

Thanks absi, that did the trick. Printing works under cups now. Though I still can't get the echo thing to work. Anyone know what the trick to that is?
Back to top
View user's profile Send private message
absi
n00b
n00b


Joined: 06 Nov 2002
Posts: 6

PostPosted: Sat Nov 16, 2002 5:47 pm    Post subject: Reply with quote

mtPete wrote:
Thanks absi, that did the trick. Printing works under cups now. Though I still can't get the echo thing to work. Anyone know what the trick to that is?


Does the following work?

Code:

echo -e "Hello printer\f" > /dev/lp0


Greetz, absi
Back to top
View user's profile Send private message
mtPete
n00b
n00b


Joined: 20 Jul 2002
Posts: 40

PostPosted: Sun Nov 17, 2002 12:15 am    Post subject: Reply with quote

No absi it didn't work; nor did it generate any errors on the command line. Pressing the formfeed on the printer didn't work either.

I don't know what the problem is but cups works now. And to my pleasant surprise, printing worked in all my apps without me having to do anything to configure them (opera,mozilla,openofice,evolultion,etc). But I can't garentee the sanity of my printer either. It died once for a few days, wouldn't respond to anything. And just the other day windows started thinking on bootup that the printer is a new device, even though its old drivers are still loaded. It also has a habbit of restarting itself when another device on its power strip is switched on/off. But is was just a cheap giveaway from my OEM. Of cource, given that cups works, I would be temped to say that the echo thing is a software problem, but you never know. I'm just releaved to get cups working.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum