View topic - Problem printing to serial port with lpd

Problem printing to serial port with lpd

Discussion about the general applications that run on QNX6

Problem printing to serial port with lpd

Postby slipbull » Fri Oct 30, 2009 10:45 am

Hi all,

I want to print to a printer connected to the serial port. So this is how I set up the /etc/printcap file:

imp1:\
:lp=/dev/ser1:sd=/usr/spool/output/imp1:


But when I print with:

lpr -Pimp1 filetoprint

File gets spooled, but the settings of the serial port change! -Like parity checking gets set to "odd", and baud rate to "13" (!). Even if I change the printcap file to look like this:

imp1:\
:lp=/dev/ser1:br#9600:sd=/usr/spool/output/imp1:


Lpd keeps leaving /dev/ser1 in bad state. The spooled fiel print when I change the settings of the serial port correctly with:

stty baud=9600 par=none < /dev/ser1

Any clues on why is this happening? How to fix it?

Thank you!

Jose
slipbull
Active Member
 
Posts: 10
Joined: Fri Oct 30, 2009 10:44 am
Location: Barcelona

RE: Problem printing to serial port with lpd

Postby juanplacco » Fri Oct 30, 2009 2:38 pm

Did you try echo "Hi world" > /dev/ser1 ?
juanplacco
Senior Member
 
Posts: 318
Joined: Wed May 17, 2006 2:30 pm

Postby slipbull » Fri Oct 30, 2009 3:34 pm

Yeah, that works. I mean, the serial port is ok until lpd tries to use it
slipbull
Active Member
 
Posts: 10
Joined: Fri Oct 30, 2009 10:44 am
Location: Barcelona

Postby slipbull » Tue Nov 03, 2009 8:25 am

So, any more ideas???
slipbull
Active Member
 
Posts: 10
Joined: Fri Oct 30, 2009 10:44 am
Location: Barcelona

Postby juanplacco » Thu Nov 05, 2009 12:48 am

Did you configure /etc/config/lpsrvr ?
juanplacco
Senior Member
 
Posts: 318
Joined: Wed May 17, 2006 2:30 pm

Postby slipbull » Thu Nov 05, 2009 7:59 am

No, using only lpd because printers are serial.
slipbull
Active Member
 
Posts: 10
Joined: Fri Oct 30, 2009 10:44 am
Location: Barcelona

Postby slipbull » Wed Nov 11, 2009 2:40 pm

slipbull
Active Member
 
Posts: 10
Joined: Fri Oct 30, 2009 10:44 am
Location: Barcelona

Postby davidk2 » Tue Jan 05, 2010 12:11 pm

Yes this is a bug in QNX 6.3.2 and below.

It has been fixed in 6.4.0:

I had a qnx rep raise a PR for me: PR55791 (search for 55791 at http://www.qnx.com/developers/articles/ ... ware_fixes).
davidk2
Active Member
 
Posts: 46
Joined: Mon Mar 03, 2008 4:06 pm


Return to QNX6 - Applications

Who is online

Users browsing this forum: No registered users and 2 guests