LPT ports on PCIcard

Hi…
I have PCI card with 2 additional LPT ports (I have 3 ports). I want use it
for printing. But if I want to print to printer connected to LPT2 I must
write these commands into command line:

$devc-par -p 0xd400 &
$slay spooler
$spooler -d /dev/par2 &

but I have to do this always when i want use the printer, I can write
program in shell or C doing it instead of me. I want to ask if exist
another way.
(for example: rewrite something in system file)

Hi,

You can put those commands in the rc.local file (you must create this file
under /etc/rc.d). The commands in this file will executed automatically when
the system starts up.

You may want to do something like this to make sure the device is fully
initialized before you start spooler:

devc-par -p 0xd400 &
waitfor /dev/par2
slay spooler
spooler -d /dev/par2 &

Note: Make sure to set the appropriate permissions on the rc.local file.

Regards,

Joe

Kinc Pavel <pkinc@retia.cz> wrote in message
news:aooebi$g22$1@inn.qnx.com

Hi…
I have PCI card with 2 additional LPT ports (I have 3 ports). I want use
it
for printing. But if I want to print to printer connected to LPT2 I must
write these commands into command line:

$devc-par -p 0xd400 &
$slay spooler
$spooler -d /dev/par2 &

but I have to do this always when i want use the printer, I can write
program in shell or C doing it instead of me. I want to ask if exist
another way.
(for example: rewrite something in system file)

Thanks for this solution but i need anything else. I need something what
starts the driver only in case when the card is really in PCI slot.
And I have another question:
If I have more lpt ports how can I detect which of them is printer connected
to?


hwsupport pí¹e ve zprávì .

Hi,

You can put those commands in the rc.local file (you must create this file
under /etc/rc.d). The commands in this file will executed automatically
when
the system starts up.

You may want to do something like this to make sure the device is fully
initialized before you start spooler:

devc-par -p 0xd400 &
waitfor /dev/par2
slay spooler
spooler -d /dev/par2 &

Note: Make sure to set the appropriate permissions on the rc.local file.

Regards,

Joe

Kinc Pavel <> pkinc@retia.cz> > wrote in message
news:aooebi$g22$> 1@inn.qnx.com> …
Hi…
I have PCI card with 2 additional LPT ports (I have 3 ports). I want use
it
for printing. But if I want to print to printer connected to LPT2 I must
write these commands into command line:

$devc-par -p 0xd400 &
$slay spooler
$spooler -d /dev/par2 &

but I have to do this always when i want use the printer, I can write
program in shell or C doing it instead of me. I want to ask if exist
another way.
(for example: rewrite something in system file)
\