Announcement
Collapse
No announcement yet.
Digital Loggers Web Power Switch - request for help
Collapse
X
-
Sorry my answer was incomplete. Neither hs.GetURL nor hs.URLAction support parsing of username: password@address. You'd have to generate the appropriate Authorization header as described here: https://forums.homeseer.com/forum/ho...58#post1337858
-
Originally posted by zwolfpack View PostI think your event action is confused. Looks like you're trying to execute hs.GetURL in a 'Run Another Program or Process' action, rather than a 'Run a Script or Script Command' action.
Furthermore, hs.GetURL doesn't support passing username/password credentials like that. You'll need to use hs.URLAction instead.
Unfortunately this didn't work either, changed the event to "Run a Script or Script Command"... nothing.
Also moved from hs.GetURL to hs.URLAction... and nothing.
I'm kinda losing hope with this, on Windows it just works so well (as well as from a Crestron controller). There must be something obvious that I'm missing.
Leave a comment:
-
I think your event action is confused. Looks like you're trying to execute hs.GetURL in a 'Run Another Program or Process' action, rather than a 'Run a Script or Script Command' action.
Furthermore, hs.GetURL doesn't support passing username/password credentials like that. You'll need to use hs.URLAction instead.
Leave a comment:
-
Code:hs.GetURL("http://admin:1234@192.168.1.150","outlet?4=ON",TRUE,80)
Code:-bash: syntax error near unexpected token `"http://admin:1234@192.168.1.150","outlet?4=ON",TRUE,80'
Leave a comment:
-
Try using putty or another ssh tool to connect to the Zee and then run the command manually to see if it spits out any errors. Make sure the file attributes are set to be executable. Yes, the HTTP set/post should work as well.
Leave a comment:
-
Originally posted by sparkman View Post
Yes, the exe looks to be Windows only. There's a perl script included in the download (UU.pl) which should work from the Zee.
Unfortunately that didn't work either, here's what I did:
I did try this under HS3 (installed on my Windows PC) and it worked perfectly, just like jono mentioned. Using the UU.exe instead of the UU.pl.
I can't seem to make this work under HS3 Linux.
EDIT: Here's the URL I get when clicking on one of the Outlets directly from the Power Switch web server:
http://192.168.1.150/outlet?4=ON
So shouldn't I be able to send a HTTP SET/POST string/command consisting of:
Credentials: admin:1234
Address:Port: 192.168.1.150:80
Parameters: outlet?4=ON
?
Leave a comment:
-
Originally posted by dchramcow View PostMaybe this .exe is windows only? What would be the steps neccesary to make this work on a HomeTroller Zee S2?
Leave a comment:
-
I'm having absolutely no luck controlling the Web Power Switch using the following steps:
* Downloaded the latest UU app found here: http://www.digital-loggers.com/cex.html
* Uploaded the UU.exe to my HomeTroller Zee S2 tmp folder via WinSCP
* Made this little test event:
But it's not working.
Maybe this .exe is windows only? What would be the steps neccesary to make this work on a HomeTroller Zee S2?
PS: I can ping the digital logger PDU just fine. So there shoudn't be any issues networking-wise.
Leave a comment:
-
Just an update for those running HS3 and using the Digital Loggers Web Power Switch. In HS3 the way to make it work is to select under THEN "Run Another Program or Process". Then choose UU.W32.exe (see prior post to get this program which should be installed on your HS3 computer C: drive).
Then fill in "Enter any command parameters to be appended to the program or file being lauched" with ipaddressort username
assword 5pulse
where ipaddressort username
assword are the ip address, port, username and password of your Web Power Switch, and 5 pulse will cycle plug number 5. You could also use 1off, 1on, 1pulse to control plug 1, etc.
for some reason colon followed by p shows up as the smiley face above. replace the smiley with colon followed by p.
Leave a comment:
-
mrhappy,
You set me on the right course. It turns out the script you suggested needs to be modified just a touch to remove "UserUtil" so it ends up as:
hs.launch("C:\UU.W32.exe", "192.168.0.100:80 admin:1234 5on")
Thanks also to Scott12v, where I got the hint to remove the "UserUtil by looking at this thread:
http://board.homeseer.com/showthread.php?t=143426
Now it works perfectly! Thanks very much.
So for anyone following this, download UU.W32.exe from the webpowerswitch website (I have attached it to this entry) and put it on your c:drive. Then run the script above, modified for your powerswitch LAN location and port; username and password; and the command you want to use.
JonoAttached FilesLast edited by jono; January 16, 2012, 08:04 AM.
Leave a comment:
-
Originally posted by mrhappy View PostFrom looking at it very quickly on the online test version the URL to control them is;
http://lpc.digital-loggers.com/outlet?6=OFF
(which you would replace with your IP address) which looks on the face of it very simple as you could get away with just putting that URL into a hs.geturl command and it might work. The problem is going to be that logon page as its not like a normal web logon page where you might be able to pass the username/password in the headers.
Upon looking at that utility though it looks possible to use just use that with a hs.launch command, you would launch the app using something like this and then pass the parameter with the other details. I am not sure how this is going to work in practice though as you might end up with console windows popping up everywhere...
hs.launch("C:\UU.W32.exe", "UserUtil 192.168.0.100:80 admin:1234 5on")
I'm not there yet but you have given me some things to think about. Thanks
Leave a comment:
-
From looking at it very quickly on the online test version the URL to control them is;
http://lpc.digital-loggers.com/outlet?6=OFF
(which you would replace with your IP address) which looks on the face of it very simple as you could get away with just putting that URL into a hs.geturl command and it might work. The problem is going to be that logon page as its not like a normal web logon page where you might be able to pass the username/password in the headers.
Upon looking at that utility though it looks possible to use just use that with a hs.launch command, you would launch the app using something like this and then pass the parameter with the other details. I am not sure how this is going to work in practice though as you might end up with console windows popping up everywhere...
hs.launch("C:\UU.W32.exe", "UserUtil 192.168.0.100:80 admin:1234 5on")
Leave a comment:
-
Digital Loggers Web Power Switch - request for help
I am trying to do some basic scripting to control the Digital Loggers Web Power Switch.
http://www.digital-loggers.com/lpc.html
It is a great device which serves a web page that allows the user to reboot devices that are plugged into it. There are 8 controllable power plugs.
The web power switch support site says the device can be controlled by scripting. I was hoping to have HS do that for me. According to the FAQs there are programming examples using Python, C++, .NET, Java, and compiled Windows Command Line.
http://www.digital-loggers.com/lpc3_faqs.html
Perl script and compiled Perl script examples
Usage: UserUtil <HOST>[ip addressort] <USERNAME;P<LOGIN
assword> <[n]{on|off|pulse|status}>
Examples:
UserUtil 192.168.0.100:80 admin:1234 5on
& UserUtil 192.168.0.100:80 admin:1234 5on
But it logged an error: Running script, init error: Syntax error
Thanks
Jono
<OTags: None
Leave a comment: