Previous Next Contents

7. User EnhancementsHow to make a cable

This section is just from messages I've seen on the net. I haven't done it so I can't write from experience. If anyone has, please write this section for me :). See also the message about the GPS1000 contained in section GPS1000 from ACCODATA

   >From miquels@caution.cistron.nl.mugnet.org Wed Jul 21 14:26:33 1993
   Newsgroups: comp.os.linux
   Subject: Re: UPS interface for Linux?
   From: miquels@caution.cistron.nl.mugnet.org (Miquel van Smoorenburg)
   Date: Sat, 17 Jul 93 18:03:37
   Distribution: world
   Organization: Cistron Electronics.

   In article <1993Jul15.184450.5193@excaliber.uucp>
   joel@rac1.wam.umd.edu (Joel M. Hoffman) writes:
   >I'm in the process of buying a UPS (Uninteruptable Power Supply), and
   >notice that some of them have interfaces for LAN's to signal the LAN
   >when the power fails.
   >
   >Is there such an interface for Linux?
   >
   >Thanks.
   >
   >-Joel
   >(joel@wam.umd.edu)
   >

   When I worked on the last versioon of SysVinit (Now version 2.4),
   I temporarily had a UPS on my computer, so I added support for it.
   You might have seen that in the latest <signal.h> header files there
   is a #define SIGPWR 30 now :-). Anyway, I did not have such a special
   interface but the output of most UPS's is just a relais that makes or breaks
   on power interrupt. I thought up a simple way to connect this to the
   DCD line of the serial port. In the SysVinit package there is a daemon
   called 'powerd' that keeps an eye on that serial line and sends SIGPWR
   to init when the status changes, so that init can do something (such as
   bringing the system down within 5 minutes). How to connect the UPS to
   the serial line is described in the source "powerd.c", but I will
   draw it here for explanation:

                        +------------------------o  DTR
                        |
                      +---+
                      |   | resistor
                      |   | 10 kilo-Ohm
                      |   |
                      +---+                                To serial port.
                        |
          +-----o-------+------------------------o  DCD
          |             |
          o  UPS        |
        \    relais     |
         \              |
          |             |
          +-----o-------+------------------------o  GND

   Nice drawing eh?

   Hope this helps.
   SysVinit can be found on sunsite (and tsx-11 probably) as
   SysVinit2.4.tar.z

   Mike.

   --

   Miquel van Smoorenburg, <miquels@cistron.nl.mugnet.org>
   Ibmio.com: cannot open CONFIG.SYS: file handle broke off.


   >From danny@caution.cistron.nl.mugnet.org Wed Jul 21 14:27:04 1993
   Newsgroups: comp.os.linux
   Subject: Re: UPS interface for Linux?
   From: danny@caution.cistron.nl.mugnet.org (Danny ter Haar)
   Date: Mon, 19 Jul 93 11:02:14
   Distribution: world
   Organization: Cistron Electronics.

   In article <9307174330@caution.cistron.nl.mugnet.org>
   miquels@caution.cistron.nl.mugnet.org (Miquel van Smoorenburg) writes:
   >How to connect the UPS to the serial line is described in the source
   >"powerd.c", but I will draw it here for explanation:

   The drawing wasn't really clear, please use this one in stead !
   >
   >                     +------------------------o  DTR
   >                     |
   >                   +---+
   >                   |   | resistor
   >                   |   | 10 kilo-Ohm
   >                   |   |
   >                   +---+                                To serial port.
   >                     |
   >       +-----o-------+------------------------o  DCD
   >       |
   >       o  UPS
   >     \    relais
   >      \
   >       |
   >       +-----o--------------------------------o  GND
   >

   The DTR is kept high, when the UPS's power input is gone it
   will close the relais . The computer is monitoring
   the DCD input port to go LOW . When this happens it will start a
   shutdown sequence...

   _____
   Danny

   --
   <=====================================================================>
   Danny ter Haar  <dannyth@hacktic.nl> or <danny@cistron.nl.mugnet.org>
   Robins law #103: 'a couple of lightyears can't part good friends'


Previous Next Contents