- The first, called the BAT required a subscription to a monitoring service and if any local connection was possible, it was not obvious.
- The second, called the AD2USB was priced right (~$80) but it was USB based and it was not obvious how to have more than one process talking it at a time (like a virtual keypad and a fault monitoring program, and Indigo triggers.) Also, this unit is not available at the moment, and the response on their support forums seems non-existant.
- The final option is the VistaICM, from Honeywell. This unit is widely available and sells for around $250. Being IP based, it is no problem to have multiple processes access it and USB wiring limitations are not an issue.
After a little research and trial-and-error I succeeded in getting a Perl script to talk to the VistaICM and monitor the alarm panel's messages. The Vista keypad message line is pretty chatty and it took a little work to sort out the noise and develop a state table to track the state of the various zones. Although I did the development of the script on my Indigo server, I have now moved the Perl script to my gateway FreeBSD box where it runs as a daemon. Once the basic interface coding was done, I created virtual devices in Indigo for each alarm zone and added RESTful API calls to Indigo in the Perl script to update the Indigo devices whenever a zone's state changed. (see picture 1, below).
With this part working, I then set out to add alarm control into Indigo. This was simple since the VistaICM can be controlled by http. I created Action groups to arm and disarm the system. All I had to do was perform a series of http requests in an embedded AppleScript to simulate key presses like:
- Code: Select all
do shell script "/usr/bin/curl \"http://192.168.1.16/cmd_list?cmd=(0.1.1)5\""
do shell script "/usr/bin/curl \"http://192.168.1.16/cmd_list?cmd=(0.1.1)1\""
do shell script "/usr/bin/curl \"http://192.168.1.16/cmd_list?cmd=(0.1.1)8\""
do shell script "/usr/bin/curl \"http://192.168.1.16/cmd_list?cmd=(0.1.1)7\""
do shell script "/usr/bin/curl \"http://192.168.1.16/cmd_list?cmd=(0.1.1)3\""
At this point, while still a little crude, it all works. I still need to display the system state (Disarmed, Armed-Stay, Armed-Away) in the control page and improve the looks of the buttons.
If there is interest, I can package this up and put it in the User Contributions Library.