2

Is there any way by which I can power off RPI2 when system is on UPS after sometime using software only. My UPS communicates with the system using USB. But it has windows support. I want to have similar mechanism with RPI2.

I'm using this UPS model.

Thank You.

dhruvvyas90
  • 2,853
  • 3
  • 19
  • 32
Amol
  • 21
  • 1
  • May be more info on UPS model how it gets connected to windows could be useful. – dhruvvyas90 Nov 04 '15 at 11:12
  • 1
    I believe that you can download its source from this site : http://www.apcupsd.com and follow this instructions to compile and run it on Rpi. : https://code.google.com/p/quickanddirty/wiki/APCinLinux Hope it helps. – dhruvvyas90 Nov 04 '15 at 11:28
  • Thanks a lot Dastaan. I will follow the steps. I will update this thread with my findings. – Amol Nov 04 '15 at 11:52
  • @dastaan - apcupsd is the answer I would have provided - can you turn your comment into an answer with a little more explanation? – Phil B. Nov 04 '15 at 12:17
  • @PhilB. Added. :) – dhruvvyas90 Nov 04 '15 at 12:29

1 Answers1

2

I think for this particular UPS, vendor also provides source on their site.

You can download source from this link.

Untar it and copy it on Raspberry pi.

And as per this guide,

  1. Install dependencies by sudo apt-get install libgd2-xpm-dev libusb-dev

  2. cd to source directory.

  3. ./configure --enable-usb --enable-cgi

  4. Once configuration done, make && sudo make install to compile and install binaries.

  5. To test, run : apcaccess

I didn't test it but it should ideally work.

Hope it helps. :)

dhruvvyas90
  • 2,853
  • 3
  • 19
  • 32