Cheap or free auto-shutdown setup (was: Reliability Sys V file sys)

Tim Wright tim at delluk.uucp
Mon Oct 1 19:13:08 AEST 1990


In <1030 at bilver.UUCP> bill at bilver.UUCP (Bill Vermillion) writes:

>Why couldn't you just use a cheap relay connected to the mains power
>source.  Then connect pins 2 & 3 of the rs232 to a pair of contacts that
>are closed when power is on.  Then just send something out and see if it
>echos.  If it doens't come back to you, the power is off!

Seems fine but why bother to go even this far. All the methods mentioned
so far imply polling. If you setup a relay etc. to pull up DCD on power loss,
and have a process try to open a modem-control enabled port, then all is
simple. The power dies, the relay trips, DCD goes high, open succeeds, the
process wakes up and shuts down the system.
Voila !

Tim
--
Tim Wright, Dell Computer Corp. (UK) | Email address
Dell Computer Corp. (UK), Bracknell  | Domain: tim at dell.co.uk
Tel: +44-344-860456                  | Uucp: ...!ukc!delluk!tim
"What's the problem? You've got an IQ of six thousand, haven't you?"



More information about the Comp.unix.questions mailing list