[Webinar] Streamline your web hosting managementRegister Today

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 558
  • Last Modified:

parallel port not detected, RH 6.1, asus K7M motherboard

My new installation of RH 6.1 upon a pc using a
Asus K7M slot a motherboard is unable to
detect or use the parallel port for the printer. Commands
like  "cat file > /dev/lp0"  (and lp1 and lp2) results in the
message "/dev/lp0 no such device".  The reactions
from tunelp and printtest via printtool are similar.

I have tried adding the three lines suggested in the
recent print-howto into the conf.modules, without
success. And I have tried to change all PnP settings
in the bios of the motherboard to non PnP settings.

I have windows98 on the same pc, the printer works
perfectly on lpt1  Windows the reported setup is for
lpt1 is:
   input/output area 0378-037F
                                   0778-077A
 IRQ                   07
 DMA                       03

I would imagine that somehow one could force
linux to  use those, but I dont know how.
I, for example, I do "tunelp /dev/lp0 -i 5" the
reaction is again "no such device".
0
hv
Asked:
hv
1 Solution
 
jlevieCommented:
What's worked for me every time so far on RedHat is to:

1) Check the bios to make sure that the parallel port is not in PnP mode, that it's at the normal IRQ & IO (your's looks fine), and set the mode to Bi-Directional (ECP ought to work, but I normally use Bi-Dir as I don't have a need for ECP). I've had to change some that had that stupid PnP feature...

2) Add just this to /etc/conf.modules: "alias paraport_lowlevel paraport_pc" and reboot.

At this point I've always been able to set up a printer and have it print.


0
 
hvAuthor Commented:
Jewie, my 2 kids are having birthday
today (same day - two years apart),
wherefor I'll likely first be able to
check out your suggestions Thurdays
evening and report to you/expert-echange on Friday. (this is written on a computer at work.) /henrik
0
 
freesourceCommented:
You must mean you added these three lines:

alias /dev/printers lp            
alias /dev/lp*      lp            
alias parport_lowlevel parport_pc

You also checked for the PNP thing.

First, do this from the command line:

depmod -av | grep par

You should see something like this, but your version kernel which you can find with "uname -r":

/lib/modules/2.2.14/misc/parport_pc.o

If you don't then either this has been compiled into the kernel, or this module doesn't exist.

Now do this:

depmod -av | grep lp

and this is what you may see if lp is a module.

/lib/modules/2.2.14/misc/lp.o

Here's the order the modules required by the parallel port are installed in.  Probably parport is compiled right into the kernel in your case.

parport -> parport_pc -> lp

You need all three of these things either in the kernel or loaded as modules if you want the cat file > /dev/lp0 command to work.  Now you can try printing* (see note at the end).  If for some reason your port has special irq needs you can do something like this:

insmod parport_pc.o io=0x3bc,0x378,0x278 irq=none,7,auto

or add this to your conf.modules  ..

options parport_pc io=0x378,0x278 irq=7,auto

Realize that depmod -a sets up the dependencies so that kmod and modprobe can do their thing.  This (depmod -a) is usually ran automatically when you bootup the system.


*If you still can't do the cat thing, and you weren't able to find paport_pc and lp, you will have to go get the kernel sources (kernel.org) and you will have to configure the kernel so that you have these things compiled into the kernel or available as modules.  
0
Never miss a deadline with monday.com

The revolutionary project management tool is here!   Plan visually with a single glance and make sure your projects get done.

 
DVBCommented:
Just add the alias parport_lowlevel parport_pc to the modules.conf file. That will be enough
0
 
hvAuthor Commented:
Now the printerport works! Thanks for
the help to all three of you. I got
it to work by "manuall" loading
modules and options along the lines
of freesource. However, after went
carefully through the bios setups,
and reinstalled linux (redhat 6.1). The
setup which works now has all PnP
settings of the K7M motherboard
cancelled (set to ISA as I
recall it) and the parallel port
address(?) is set to 378 in the bios.
This is done in the bios->main->advanced->PnP section and the
bios->main->advanced->periphelia section
respectively.

The /etc/conf.modules contains the three
lines

alias /dev/printers lp              
alias /dev/lp*      lp              
alias parport_lowlevel parport_pc.

Why this didn't work on my first attempt, which is why I asked you guys,
I don't know. Maybe
a typing error in conf.models?

It may well be that even less
restrictive settings of the bios and
fewer aliases in conf.modules does
the job, as suggested by DVB.

But the above will at least
permit other people in a similar
situation to get the port working.

0
 
hvAuthor Commented:
All three answers may be correct,
but it was freesource's who allowed me
to beat the computer.
0

Featured Post

Hire Technology Freelancers with Gigs

Work with freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely, and get projects done right.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now