SourceFiles.org - Use the Source, Luke
Home | Register | News | Forums | Guide | MyLinks | Bookmark

Related Sites

Latest News
  General News
  Reviews
  Press Releases
  Software
  Hardware
  Security
  Tutorials
  Off Topic


Back to files

DESCRIPTION

This is a GNOME client for the Network UPS Tools Package (nut-0.42.1). It will display information about battery-status, load-status, AC-current and AC-frequency in a window. You can choose which machine to get the information from, and the rate at which it gets this information.

This package requires NUT on the machine the UPS is connected to. It does not require NUT installed on the machine you want to run gupsc on. For information about how to configure NUT, and how to allow external machines to connect to the upsd, please check the documentation for NUT.

I made this program using the GLADE interface builder for GNOME, the graphics were made in the Gimp, mail me if you would like to have the .xcf file. Somebody should really change this image.

USAGE

See INSTALL for information on how to install this program.

Using this program should be quite straightforward. All you need to do is type "gupsc" in a terminal window or the quicklauncher and things should start right up.

After the program has started for the first time, you might need to press the "Edit Preferences" button and select a hostname for your UPS. Most people have theire UPS on localhost (ie. the same machine they run gupsc from). If this is the case, you don't need to change the "Hostname" entry.

If you are using a UPS far away (RTT >= 100ms) or you experience packageloss, you should select TCP mode instead of UDP. This version of gupsc automatically changes from UDP to TCP if it experiences packageloss. Future versions may not do this, and you will lose data. It might be wise to choose a bigger delay aswell if contacting the UPS takes a lot of time. I will try to make this program multithreaded soon, but untill then, the UI stops responding while waiting for information from the UPS. This is no problem with a local UPS.

When you have configured the UPS hostname, you can press "apply". When you do this, gupsc contacts your UPS and asks what kind of information is avaliable. You can choose what information you want to see by using the menues.

Finally you can select what font to use in the gauges by pressing the button. The text on the button tells what font and fontsize you are currently using.

ADVANCED USAGE

Some people like to monitor more than one UPS at the same time. To make this easier I have added a commandline option called "--ups". You can use it like this:
gupsc --ups=MYUPSID
gupsc --ups MYUPSID
gupsc -u MYUPSID
gupsc -u=MYUPSID

If you use this option, you get a separate profile for this window. Any settings you set in this profile only affects this profile. It is therefore vitally important to remember the profile ID name.

Example
gupsc --ups=bestups I can now configure gupsc to use a different UPS than the default one. If I now start gupsc by issuing: gupsc I get the default setting, not the one I configured with the --ups parameter By running: gupsc --ups=bestups again, I get the settings I chose last time I used the --ups=bestups parameter.

You can have as many profiles as you like.

FUTURE DEVELOPMENT AND HELP NEEDED

See TODO

Please help the NUT team fixing the trust425+625 module.

VERSION NUMBERING

The versions are supposed to work like this...

Everything is currently 0.x since planned features are lacking. Once all of them are coded and stable, it will become 1.0.

"-pre" versions are potentially broken, but are used to make sure things work after making major changes.

ACKNOWLEDGEMENTS / CONTRIBUTIONS

I've made this program on my PII Machine running Mandrake 7.0 with a Linux 2.3.46 kernel. this machine is using a Trust 425 UPS. Unfortunately the trust425+625 module is very buggy, so I haven't been able to debug it as much as I wanted to. I've also tested it on a laptop PII running Mandrake 7.0beta1 (Oxygen) using the other computer as a host in gupsc. I had no trouble using gupsc on any of these computers.

The routines for fetching data from the UPS (upsfetch.h/upsfetch.c) were made by Russel Kroll <rkroll@exploits.org>. Without these routines I don't think this program would ever work.. :)

I would also like to thank the GNOME development and documentation team for making such a great free desktop environment.

As you probably has understood by now, English is not my native tounge. Please report any spelling-errors.


Other Sites

Discussion Groups
  Beginners
  Distributions
  Networking / Security
  Software
  PDAs

About | FAQ | Privacy | Awards | Contact
Comments to the webmaster are welcome.
Copyright 2006 Sourcefiles.org All rights reserved.