windows HS4 python support/api
Announcement
Collapse
No announcement yet.
HS-391 - windows HS4 python support/api
Collapse
X
-
HS-391 - windows HS4 python support/api
Regards Bart
------------------------------------------
Win7 64Bit on Intel NUCI7 with SSD
HSPRO 3.
Devices; 1370 Events; 691
Jon00 Scripts, JowHue, HSTouch, Plugwise, Z-wave, Ultranetatmo, Ultracam, PHlocation, BLUSBUIRT, MeiHarmony, Buienradar, MEiUnifi Pushover 3P, Random, Nest HSPhone and Blueiris
Visonic Powermax Alarm System (HS3) Interface: http://www.domoticaforum.eu/viewtopic.php?f=68&t=11129Tags: None
- Likes 3
-
I'm a Perl guy. When HS dropped external Perl support, they provided the JSON API. I wrote a common Perl module containing the necessary JSON API functions I need allowing for getting and setting HS data.
for example:
Code:use Homeseer::API; my %status_hash; $hs = Homeseer::API->new( { server => 'http://homeseer.local.net', port => 82, debug => 1, user => 'asfd', password => 'asdfaasfklj', } ); $hs->getStatus(\%status_hash, {ref => 164, location1 => 'Living Room', location2 => '1st Floor'} ); $hs->controlDeviceByValue(\%status_hash, {ref => 164, value => 0} ); $hs->controlDeviceByLabel(\%status_hash, {ref => 164, label => 'On'} ); $hs->getStatus(\%status_hash, {ref => 164, location1 => 'Living Room', location2 => '1st Floor'} ); print "'%status_hash{'Devices'}[0]->{'name'}' is "; print "'%status_hash{'Devices'}[0]->{'status'}'\n";
Code:./getHsDevice.pl -r 1005 -a name,value Todays Rain Amount,0.02
Code:./getHsDevice.pl -f 'Todays Rain Amount' -a ref,name,value 1005,Todays Rain Amount,0.02
Comment
-
+1Preferred -> Jon's Plugins, Pushover, Phlocation, Easy-trigger,
Rfxcom, Blade Plugins, Pushbullet, homekit, Malosa Scripts
HS3Pro 4.1.14.0 on windows 10 enterprise X64 on hp quadcore laptop 8 GB.
Comment
Comment