1834629 Members
3034 Online
110069 Solutions
New Discussion

Baud Rate Keeps Dropping

 
Michael Campbell
Trusted Contributor

Baud Rate Keeps Dropping

I have a dot matrix printer attached directly to one of our servers through a MUX card. When I run a job which uses this printer, the baud rate keeps dropping from 9600 to 300 and I have to run a stty script to reset it before the job will print. This happens twice or three times every time I try to run this. This problem has only come up in the last week or so and no changes were made to the job which runs. Has anyone got any ideas why this is happening and how I could sort it out? Thanks.
3 REPLIES 3
Paula J Frazer-Campbell
Honored Contributor

Re: Baud Rate Keeps Dropping

Hi

Check two things to start with :-

1. The baud rate set at the printer.
2. The baud rate in /etc./inittab.

Paula
If you can spell SysAdmin then you is one - anon
Jean Mesquida_1
Frequent Advisor

Re: Baud Rate Keeps Dropping

Hi,

Did someone change the interface file of this printer ? For example by deleting/recreating the printer ? If this has been done, try to restore the original interface file.

The baud rate should be set inside the file /etc/lp/interface/printer_name to reflect the actual baud rate of 9600 set on your printer, e.g. :
stty raw 9600 -parenb cs8 ixon -istrip clocal <&1 2>/dev/null

HTH
Jean
Bill Hassell
Honored Contributor

Re: Baud Rate Keeps Dropping

On every version of HP-UX, the default baud rate (300 baud) is set whenever the device is closed. It's been that way since the mid-80's. If you look at the 'dumb' model script, you'll see the stty command st the beginning and also at the end of the script. The stty at the end of the spooler script is to flush out any data left in the FIFO as closing the device file resets the card, even if there might be data left on the card.

Are you not using the lp spooler? If not, you'll need to run a process that keeps the printer device file open forever. Typically this is done with inittab and sleep where the printer is assigned stdin for the sleep command and the sleep process is respawned to keep the port open.


Bill Hassell, sysadmin