Python plugin: UPS Monitor

Python and python framework

Moderator: leecollings

User avatar
ycahome
Posts: 248
Joined: Sunday 12 February 2017 10:55
Target OS: Linux
Domoticz version: lat Beta
Contact:

Re: Python plugin: UPS Monitor

Post by ycahome »

Also, am wondering if you could include a bash script on your plugin in order to update with a single command:

filename: upgrade.sh

Code: Select all

#!/bin/bash

git reset --hard
git pull --force
sudo chmod +x plugin.py
sudo chmod +x upgrade.sh
sudo /etc/init.d/domoticz.sh restart
this way, next time you can upgrade with a single command

Code: Select all

sudo ./upgrade.sh
Logread
Posts: 228
Joined: Sunday 28 August 2016 7:48
Target OS: Raspberry Pi / ODroid
Domoticz version:
Location: France
Contact:

Re: Python plugin: UPS Monitor

Post by Logread »

@ycahome,

Thanks for the suggestions... please feel free to contribute the script on GitHub and/or the wiki
hamster
Posts: 42
Joined: Friday 28 April 2017 19:11
Target OS: Raspberry Pi / ODroid
Domoticz version: 2020.2
Location: USA
Contact:

Re: Python plugin: UPS Monitor

Post by hamster »

Logread wrote: Thursday 15 February 2018 14:13 New version 0.2.1 is available.
AWESOME! Will install and begin testing.
manutremo
Posts: 67
Joined: Saturday 19 November 2016 17:02
Target OS: NAS (Synology & others)
Domoticz version:
Contact:

Re: Python plugin: UPS Monitor

Post by manutremo »

Hi, just wanted to let you know that I just installed it on my Synology and it works perfect. Many thanks!
Logread
Posts: 228
Joined: Sunday 28 August 2016 7:48
Target OS: Raspberry Pi / ODroid
Domoticz version:
Location: France
Contact:

Re: Python plugin: UPS Monitor

Post by Logread »

manutremo wrote: Saturday 17 February 2018 8:18 Hi, just wanted to let you know that I just installed it on my Synology and it works perfect. Many thanks!
Thanks for the positive feedback 8-)
nmaster
Posts: 54
Joined: Saturday 16 August 2014 17:17
Target OS: Linux
Domoticz version: 3.6304
Contact:

Re: Python plugin: UPS Monitor

Post by nmaster »

Hi Logread,

I upgraded to the last plugin version, all is fine here with 4 UPS.
Velly
Posts: 20
Joined: Sunday 22 October 2017 19:56
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Re: Python plugin: UPS Monitor

Post by Velly »

Help needed with EATON 9130 running on Windows 10:
EATON 9130
ip of Windows server : 192.168.1.107
port: 4679
Usp name in EATON Intelligent Power Manager: EATON9130

error:
2018-02-18 16:57:52.553 Error: (UPS EATON) Error reading UPS variables: HTTP/1.0 501 Not Implemented
2018-02-18 16:58:44.241 Error: (UPS EATON) Error reading UPS variables: HTTP/1.0 501 Not Implemented
2018-02-18 17:00:09.587 Error: (UPS EATON) Error reading UPS variables: HTTP/1.0 501 Not Implemented
2018-02-18 17:01:18.703 Error: (UPS EATON) Error reading UPS variables: HTTP/1.0 501 Not Implemented
2018-02-18 17:02:18.751 Error: (UPS EATON) Error reading UPS variables: HTTP/1.0 501 Not Implemented

Anybody with NUT on Windows Intelligent Power Manager?
Thank you!
Attachments
eaton 3.PNG
eaton 3.PNG (18.07 KiB) Viewed 4210 times
eaton.PNG
eaton.PNG (23.65 KiB) Viewed 4210 times
eaton2.PNG
eaton2.PNG (9.09 KiB) Viewed 4210 times
hamster
Posts: 42
Joined: Friday 28 April 2017 19:11
Target OS: Raspberry Pi / ODroid
Domoticz version: 2020.2
Location: USA
Contact:

Re: Python plugin: UPS Monitor

Post by hamster »

Latest update working great for me on pi Logread. Thanks!
Logread
Posts: 228
Joined: Sunday 28 August 2016 7:48
Target OS: Raspberry Pi / ODroid
Domoticz version:
Location: France
Contact:

Re: Python plugin: UPS Monitor

Post by Logread »

Velly wrote: Sunday 18 February 2018 15:05 2018-02-18 16:57:52.553 Error: (UPS EATON) Error reading UPS variables: HTTP/1.0 501 Not Implemented
@Velly, looks like you are configuring the plugin to hit a http webserver (the Eaton intelligent power manager) rather than a NUT server... first make sure you have a NUT server up and running and adjust to the right IP/Port
jeecee
Posts: 5
Joined: Tuesday 27 February 2018 13:46
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Re: Python plugin: UPS Monitor

Post by jeecee »

Tnx a lot, works perfectly!
febalci
Posts: 331
Joined: Monday 03 July 2017 19:58
Target OS: NAS (Synology & others)
Domoticz version:
Contact:

Re: Python plugin: UPS Monitor

Post by febalci »

@Logread, thanks for the great work! Works perfectly with 2 APC BX950U-GR UPSes. One of them is installed on a Synology and the other one on ubuntu Domoticz Server Intel NUC. Everything works perfectly, i also set a notification on UPS Alert Sensor; If svalue is 'ONBATTERY DISCHARGING', send a notification as 'Power Cut!!!', If 'ONLINE CHARGING' send 'Power Back ON!'. However, as you have guessed the status change waits up to 1 minute for UPS Status update. Is there any way you can suggest for the status change to be reflected instantenously?

Thanks again...
copernicnic
Posts: 3
Joined: Thursday 26 April 2018 10:27
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Re: Python plugin: UPS Monitor

Post by copernicnic »

Hello, thanks for the plugins :D . I have a little worry with nut, my ups is directly plugged into my raspberry and the server nut is also on the raspberry. my problem is that i can not disable user / password access.
do you have an idea of ​​how?
Logread
Posts: 228
Joined: Sunday 28 August 2016 7:48
Target OS: Raspberry Pi / ODroid
Domoticz version:
Location: France
Contact:

Re: Python plugin: UPS Monitor

Post by Logread »

@copernicnic, authentication is not yet handled by the plugin. Not difficult to implement, bear with me for a few days and I’ll send you by pm a new version for testing.
copernicnic
Posts: 3
Joined: Thursday 26 April 2018 10:27
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Re: Python plugin: UPS Monitor

Post by copernicnic »

hello, everything is ok now :D :D , just wait a moment that domoticz update the device.
do you know what value to put in the event to make interact?
screenshot 2018-04-27 à 10.54.41 1.jpg
screenshot 2018-04-27 à 10.54.41 1.jpg (34.77 KiB) Viewed 3740 times
Thank you very much for your work
copernicnic
Posts: 3
Joined: Thursday 26 April 2018 10:27
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Re: Python plugin: UPS Monitor

Post by copernicnic »

@Logread,
I just tested the plugin you sent me, it does not work unfortunately. here is the log
The attachment screenshot 2018-04-27 à 11.28.57.jpg is no longer available
I just saw in the command that there is a story of master and slave
The attachment screenshot 2018-04-27 à 11.28.57.jpg is no longer available
Attachments
screenshot 2018-04-27 à 11.31.21.jpg
screenshot 2018-04-27 à 11.31.21.jpg (49.13 KiB) Viewed 3736 times
screenshot 2018-04-27 à 11.28.57.jpg
screenshot 2018-04-27 à 11.28.57.jpg (38.82 KiB) Viewed 3738 times
Logread
Posts: 228
Joined: Sunday 28 August 2016 7:48
Target OS: Raspberry Pi / ODroid
Domoticz version:
Location: France
Contact:

Re: Python plugin: UPS Monitor

Post by Logread »

@copernicnic, let’s debug this by private message rather than posting on the public thread, to avoid clogging it... in my last pm, I told you that the edits were not tested... since my own setup does not require a login. Let me do some investigations in the network ups tools code and docs but this will not be before several days.
In the meantime, if you have the knowledge to do this, please try to login from shell with a telnet session and post me the result by pm, not on the forum thread pls.
toutazimuth
Posts: 16
Joined: Tuesday 29 September 2015 19:20
Target OS: NAS (Synology & others)
Domoticz version:
Contact:

Re: Python plugin: UPS Monitor

Post by toutazimuth »

Hi Logread
Your Python plugin UPS monitor, works perfectly with my Pi3B, Python 3.4, Domoticz béta 9424, Synology and eaton 650 Pro.
everything is great
Thx ;)
Logread
Posts: 228
Joined: Sunday 28 August 2016 7:48
Target OS: Raspberry Pi / ODroid
Domoticz version:
Location: France
Contact:

Re: Python plugin: UPS Monitor

Post by Logread »

toutazimuth wrote: Friday 11 May 2018 20:47 Hi Logread
Your Python plugin UPS monitor, works perfectly with my Pi3B, Python 3.4, Domoticz béta 9424, Synology and eaton 650 Pro.
everything is great
Thx ;)
Thanks for your appreciation !
User avatar
lmet
Posts: 23
Joined: Wednesday 19 July 2017 22:35
Target OS: Raspberry Pi / ODroid
Domoticz version: v4.9700
Location: France
Contact:

Re: Python plugin: UPS Monitor

Post by lmet »

Hi,
Now i have UPS Monitor working fine on Domoticz 4.9700 using stretch.
For me the reason was python version 3.5.1.x after downgrade it to 3.4.1.x all is Ok now.
Thanks a lot for this very usefull plugin.
legus49
Posts: 1
Joined: Monday 05 November 2018 1:26
Target OS: Linux
Domoticz version: 3.7207
Location: Bretagne ;-)
Contact:

Re: Python plugin: UPS Monitor

Post by legus49 »

Hi,
I just installed UPS Monitor and it's working fine on Domoticz 3.7207, but I do not have the units for the sensors (Volt, %, W...) Any idea ?
Thanks a lot for this very usefull plugin.
Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest