Tiny Core Linux

Tiny Core Base => TCB Bugs => Topic started by: simonc_67 on August 14, 2009, 10:54:14 AM

Title: Problem with speed of printing to parallel port. (lp/parport Module)
Post by: simonc_67 on August 14, 2009, 10:54:14 AM
Connected simple line printer on parallel port. Boot DSL.

$ sudo modprobe lp
$ cat /etc/inittab > /dev/lp0

Prints at normal/acceptable speed.

Do the same thing on TC 2.2 and works but a lot slower, and a line at a time. More serial than parallel.

Is it a bug or problem with lp/parport module?
Title: Re: Problem with speed of printing to parallel port. (lp/parport Module)
Post by: roberts on August 14, 2009, 01:24:21 PM
No issue here. In fact you will find my text2lp0 script in the base, /usr/bin/text2lp0.
I use it to print my programs and scripts while developing TC/MC.
Title: Re: Problem with speed of printing to parallel port. (lp/parport Module)
Post by: curaga on August 15, 2009, 02:48:47 PM
Maybe the DMA mode isn't autodetected on your hardware?

Quote
$ dmesg | grep parport
parport0: PC-style at 0x378 (0x778), irq 7, dma 3 [PCSPP,TRISTATE,COMPAT,ECP,DMA]
This is the output on my hardware, it recognizes the dma/irq/ecp fast modes. If they aren't autodetected for you, you might need to specify them for parport (see modinfo parport)
Title: Re: Problem with speed of printing to parallel port. (lp/parport Module)
Post by: simonc_67 on August 17, 2009, 04:32:39 AM
Thanks for the replies. It does look like the parport module parameters. I booted up a debian live cd and the print works fine. On debian live the parport dmesg output is ...

parport0: PC-style at 0x378 (0x778), irq 7 [PCSPP,TRISTATE]

Whereas on TC 2.2 ...

parport0: PC-style at 0x378 (0x778), irq 7, using FIFO [PCSPP,TRISTATE,COMPAT,ECP]

So I don't think its DMA but I'm trying to get the parport module to look like it does on Debian live. Without the FIFO. Perhaps the ECP/COMPAT are also causing problems. I'll have a look in the BIOS.

I'm actually trying to get lprng to work. I'm using TC to get wireless Windows :-( clients in some cranes.
TC works great because I can't rely on the power.
Title: Re: Problem with speed of printing to parallel port. (lp/parport Module)
Post by: curaga on August 17, 2009, 04:47:18 AM
All of ecp, compat, and fifo are supposed to improve printing speed :P

You could try enabling dma, see in your BIOS what the correct value is.
Title: Re: Problem with speed of printing to parallel port. (lp/parport Module)
Post by: simonc_67 on August 17, 2009, 09:09:11 AM
Enabling DMA worked! :-)

Odd how debian live & TC have different behaviours for the same BIOS settings.

Could it be down to the Kernel version or different parport module compilation options perhaps.

Anyway, thanks for your help, and thanks for TC.