Usenet comp.unix.osf.osf1 (1992-2004)
 help / color / mirror / Atom feed
From: matthewm@sgate.com (Michael Matthews)
Subject: Monitoring serial port on 3000/400 OSF/1 3.0
Date: 23 Jan 1995 16:35:22 -0500	[thread overview]
Message-ID: <3g17eq$969@sgate.com> (raw)


I'm trying to get the upsd source (patch level 3, in comp.sources.unix volume
18) to work with our DEC 3000/400 OSF/1 3.0 machine.  The UPS is an APC unit.

The software basically just monitors the serial port, waiting for the UPS to
raise DCD to indicate a power failure, and to lower DCD (or shut the machine
down), depending on whether wall power is restored.

My problem, basically, is that once upsd fires up it things it's gone to
battery power.  The problem seems to be the opening of the /dev/tty00 port
does *not* block for the UPS to raise DCD, but rather it returns a valid file
descriptor and sets errno to 22 (EINVAL).  Since this open doesn't block,
upsd assumes that DCD is high and goes off its merry way broadcasting that
the power failed.

Now, it may be that the cable is incorrectly configured, but DCD should be
low by default in any event.  Should I be opening this port to monitor it by
some different name?

Thanks for any help on this one.. Email replies would be appreciated, as I
don't get to read news as often as I'd like.


-- 
------------------------------------------------------------------------------
Mike Matthews, Mike_Matthews@sgate.com (NeXTmail accepted)


                 reply	other threads:[~1995-01-23 21:35 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed
read-only archive

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox