[plug] UPS & powerd

Matt Kemner zombie at wasp.net.au
Fri Sep 1 13:40:02 WST 2000


Brian Tombleson wrote:

> "pins 1 and 7 are low battery - pins 8 and 9 are on battery
> When the UPS goes on battery a relay closes and pins 8 and 9 are shorted
> together.
> When UPS battery is low, pins 1 and 7 short together. So, you need to
> monitor pins 8
> and 9 for a closed circuit. "

The problem is, pin 8 is CTS, pin 9 is Ring Indicator - both of which are
normally set high or low by the remote device (eg modem) - so shorting the
2 together isn't going to make any difference because there is no power
coming in anywhere.

Probably the easiest way would be to modify a serial cable so pin 9 is
really connected to pin 7, because pin 7 (RTS = Ready To Send) is normally
set high by the PC, so you can detect it has been shorted with pin 8 when
that (CTS = Clear To Send) goes high.

I've even got some Perl software I wrote (based it on statserial.c) that
will detect when pins 8 and 9 are shorted, that I can send you if you're
interested.

Also, if you run "statserial" it will tell you what each pin is called,
and whether it is currently high or low.

 - Matt




More information about the plug mailing list