Announcement

Collapse
No announcement yet.

APC UPS monitoring script enhancements

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    APC UPS monitoring script enhancements

    Jon,

    I just loaded your script that monitors an APC UPS running Business Edition - very cool stuff!

    The devices on the HS status page appear as white text on a black background. Is there a way to configure it so that they appear as other default HS devices with black text on a gray background?

    Also, would you consider adding a .ini parameter and script logic that would allow the temperature to be reported in F or C?

    Thanks for a very useful piece of work.

    #2
    The colour issue is easy to resolve. Open up the script and search for:

    class='tablecellunknown'

    and delete it. There are 3 instances in the script. When you re-run the script, it should all be normal.

    As for the temp issue, the readings come from the Powerchute software. As I do not use this software, could you remind me if it is possible to change the temperature from C to F or is it always fixed in C?

    If it is fixed, a small amount of code just needs to be inserted to do the temp conversion.
    Jon

    Comment


      #3
      Thanks for the info. on the color change. I will try that.

      As far as I know, the data is always fixed in C in the APC log file. Even when I use the APC console to monitor the UPS data and change the display to F for the screen presentation, the log remains in C. I think it's safe to assume it's always C in the APC file.

      Comment


        #4
        Jon

        Comment


          #5
          The color change worked along with the temperature unit change. FYI, I ended up not converting the raw data to an integer first as the raw data provides a fractional portion. Thus the end number in F is more accurate.

          I'd like to monitor all of my UPS's. It looks like it is straightforward to duplicate your script for each UPS and customize each script with unique device names, etc. I plan to do this.

          Thanks again!

          Comment


            #6
            I noticed the devices created have 'on' and 'off' controls associated with each of them. Since these don't do anything, how would I modify the script to create the devices without these controls? I see that 'hs.NewDevice' is used to create each device, but I don't see how you specify this. Is it done automatically if the device is created as a 'Virtual' device?

            Comment


              #7
              hmmm... Yes I need to change that!

              change:

              dv.dev_type_string = ("Virtual")

              to

              dv.dev_type_string = ("Status Only")
              Jon

              Comment


                #8
                I changed it here and the controls are gone. Thanks!

                Comment


                  #9
                  It only took a minor effort to customize the script for each of my UPS's. The scripts are running great. Thanks again.

                  One of these UPS's is running too hot in my opinion even though it's within the 104 degree APC spec. This will make it easy to monitor. My newer unit has a two-speed fan which keeps it cooler as it runs on low speed continuously at a minimum.

                  Check your piggybank.

                  Comment


                    #10
                    Thanks very much!

                    I've actually updated the script to V1.03 which incorporates the temperature unit selection, virtual device button & background colour removal.
                    Jon

                    Comment

                    Working...
                    X