Honeywell Ademco Vista Alarm Panels Plugin via AD2USB

Version 2.2 is out!

The documentation has been updated with a more complete installation instructions. Also, I tried to explain some of the inner workings of the plugin and I gave some recommendations for the best usage experience. It’s worth reading to understand how to best configure the plugin.

The main goals for this release were compatibility and reliability. New in this version:

  • The case where only one partition is active is handled differently. This should bring an increase to reliability and compatibility.
  • The plugin must be configured with the addresses of the keypads assigned to each partition. This means that the plugin will work even if there are more keypads assigned to a partition.
  • Less messages are sent to the panel. This should bring an increase to reliability.
  • Zones are now removed from the faulted zones list when they are cleared.
  • The code has been streamlined for an increase in performance.

I didn’t have time to test it thoroughly, but I believe that there aren’t any major issues. Any feedback appreciated!

Edit: Here is the link to the Trac page: [url=http://code.mios.com/trac/mios_vista-alarm-panel-ad2usb/wiki/WikiStart]http://code.mios.com/trac/mios_vista-alarm-panel-ad2usb/wiki/WikiStart[/url]

Nice work @mcvflorin. The status is working. :smiley:

Comments.
Can you add a space between the two word status messages: ArmedInstant, StayInstant, NotReady, ExitDelay & NotActive.
Can you capitalize the Faulted zones: none to None.

Feature request.
Is it possible to scene control the Chime On/Off?
Is it possible to add/delete user codes via the plugin?

JOD.

Done.

Done.

This are available in the 2.21 version of the plugin, which is the latest version. The other requests take more time to implement and I plan on working on additional features for the Elk Alarm Panel plugin in the following days, so they won’t be implemented soon.

Florin - Works like a champ with my Vista 10SE! Thank you!!!

One observation while studying other plugins to learn out how to develop my own plugin is that this plugin is an exemplar for writing other plugins - for example, the refactoring of the lua code into an L_ lua module that is loaded during plugin initialization is simplistic and clean. Thanks Florin!

One issue to report with 2.2:
The Status (although working and updating initially) got stuck on NotReady (even after a reload) but would otherwise Arm/Disarm with no issues.

JOD.

*Edit. That was a UI4 issue (abandoned)
UI5 issue with scene setup/opening partition, email sent by @micasaverde with cc.

Can you send me the logs so I can take a look and maybe spot the problem? The Lua logs (lines starating with 50) and maybe the critical logs (lines starting with 01) are enough.

Hi @mcvflorin,
I’ve taken the plunge and purchased the A2DUSB for my Vista 20p to replace my discontinued Vista ICM module. I’ve been testing it out for a couple of days now and everything is working as advertised, thank you for your efforts on this plugin.

Since the ICM email service has been discontinued, my intentions are to use Vera as my alarm notification system. However, I am trying to take it one step further than just sending a notification that an alarm is active, I would also like to see which zone caused the alarm. This would mimic more closely the functionality of the ICM. Using luup code I have successfully set up push notifications (through automator.app) that sends me a message when an alarm occurs and appends the FaultedZones variable to the message as well. This works great when testing the code (run scene) with a door open, I get the notification and the correct zone number for the door that I have open. The problem is when I test it under real world conditions (simulate an alarm), the FaultedZones variable always reports “None” during the active alarm condition. I’ve tried forcing a poll of the panel before reading the FaultedZones variable but it still (always) reports “None”, including on the dashboard (Faulted zones: None). Am I missing something? Vera knows there is an alarm, why can’t it see which zone caused the alarm? Is there a different variable for the reporting which zone caused the alarm?

Thanks again for all your efforts!

I forgot to update the FaultedZones variable when there is an alarm. This week my schedule is full so I won’t be able to fix it until Monday. Thanks for the feedback.

Thanks @mcvflorin.

One more thing. Would it be possible to add notifications for system troubles (i.e. low batt, no ac)? Also, what about fire? Again, I’m just comparing it to the functionality I had with the ICM module.

Another one that would be nice but may not be possible is the Duress code. Is there any way to monitor the event log for a specific event code (121 in this case)?

Thanks,
kbmcguire

It’s possible to add notifications for system troubles, but monitoring the event log is not.

@mcvflorin,
I was adding a new Z-Wave device tonight that required me to disconnect the AD2USB adapter in order to get the Vera close enough to the new device for inclusion. After all was done I put the Vera back in it’s place, plugged in the AD2USB, then powered the Vera back on. Everything came up just fine, no errors. My alarm system looked normal (No Faults & “Ready”) but I soon realized that the status wasn’t updating. A closer look revealed that the serial port configuration had been completely lost and was no longer associated with my alarm. I was able to re-configure the serial port settings and everything was fine after that but I just thought it should have given me some indication like “No Comms” instead of telling me everything was ok (No Faults & “Ready”).

So, two things here:

  1. Why is Vera losing it’s serial port configuration and association?
  2. Can you display an error message when the Communications are not OK (i.e. “No Comms”)?

FYI, I was able to reproduce the problem with testing.

Thanks,
kbmcguire

  1. The serial port is a hidden device. When the device that’s connected to the USB port is unplugged, the hidden serial port device is deleted, along with all the configuration. If you plug the USB device back in, a new hidden serial port device is created, with a new ID.

  2. Yes, this would be possible.

So it wont survive a reboot? That could be a problem.

This is from one of my quick start guides that makes sure it shows up as the same device every time.

Under Linux or OSX it may be necessary to adjust the permissions of the usb device and it is also advisable to make sure that the device attaches to the same device name ever time you connect it. First determine the AD2USB serial number and vendor and product id's then configure your udev device $ udevadm info ­a ­p $(udevadm info ­q path ­n ttyUSB0) | egrep ­i "ATTRS{serial}|ATTRS{idVendor}|ATTRS{idProduct}" ­m 3 ATTRS{idVendor}=="0403" ATTRS{idProduct}=="6001" ATTRS{serial}=="A5003uIO" Record all the values in the quotes – you’ll need them in the next steps. $ sudo touch /etc/udev/rules.d/10­ad2usb.rules $ sudo chmod 644 /etc/udev/rules.d/10­ad2usb.rules $ sudo vim /etc/udev/rules.d/10­ad2usb.rules and copy this line in: BUS=="usb", SYSFS{idProduct}=="IDPRODUCT", SYSFS{idVendor}=="IDVENDOR", SYSFS{serial}=="SERIAL", NAME="ad2usb" Substitute your values from above for IDPRODUCT, IDVENDOR, and SERIAL. /dev/ad2usb will be your new mountpoint. Save and close the file. Disconnect and reconnect your ad2usb and you should now have /dev/ad2usb

If the kernel is configured for udev and runs udevd daemon then this should work just not sure if these config files are accessible.

Re
Sean M

I am new to Vera2 and have many devices working perfect. I just installed the AD2USB and it works like a dream! Thank you for all the hard work- My alarm installer was amazed. He even used it to program my system. Here is my problem I was hoping for help with:

My Vera2 cannot be in the same area as my alarm panel because of range issues. How can I connect my AD2USB to Vera from across the house? I have no attic access. I was going to try wireless USB but that will be unstable I think. If Vera could talk to my Windows based servers com port that would do it.

Any ideas?

Thanks

[quote=“Hohammer, post:75, topic:168766”]I am new to Vera2 and have many devices working perfect. I just installed the AD2USB and it works like a dream! Thank you for all the hard work- My alarm installer was amazed. He even used it to program my system. Here is my problem I was hoping for help with:

My Vera2 cannot be in the same area as my alarm panel because of range issues. How can I connect my AD2USB to Vera from across the house? I have no attic access. I was going to try wireless USB but that will be unstable I think. If Vera could talk to my Windows based servers com port that would do it.

Any ideas?

Thanks[/quote]

You can run Alarm wire from your alarm panel or the nearest keypad to your Vera2 the alarm wire can be as much as 300’ with no issues.

ser2sock.c is another option but currently the plugin afaik can only support direct usb connections. If it could support sockets then this would be another option. Connect the ad2usb to your server run ser2sock.c compiled for your OS and have it broacast your AD2USB on your local ethernet on port 10000

Re
Sean M

Vera supports “remote” serial ports.

Internally, Vera converts AD2USB to a socket based connection using “ser2net”. Then, the plugin talks to this socket. It’s trivial to get the plugin to talk to a socket on another machine, you just change the serial port configuration. If Hohammer uses a “vanilla” serial to socket program he should be able to use his windows server, and just enter the IP address/port in the serial config in Vera.

It looks like ser2sock.c is more complex than just sharing the serial port over a socket though (I’m guessing to support multiple clients), can you elaborate on how that protocol works?

[quote=“djrobx, post:77, topic:168766”]Vera supports “remote” serial ports.

Internally, Vera converts AD2USB to a socket based connection using “ser2net”. Then, the plugin talks to this socket. It’s trivial to get the plugin to talk to a socket on another machine, you just change the serial port configuration. If Hohammer uses a “vanilla” serial to socket program he should be able to use his windows server, and just enter the IP address/port in the serial config in Vera.

It looks like ser2sock.c is more complex than just sharing the serial port over a socket though (I’m guessing to support multiple clients), can you elaborate on how that protocol works?[/quote]

Very smart idea on using ser2net. If this is the case then my ser2sock.c is not necessary.

I was looking for a way to share my AD2USB amongst several systems. Not finding any other solution I decided to just write it and ser2sock is the result.

ser2sock.c is best suited for cr lf terminated serial data but I have been planning to have a switch for “raw” mode where it does not parse the stream before retransmitting it to all connections. It has a few switches for tuning its use but I would not go so far as to say it had a protocol other than that its TCP/IP socket based.

I forgot to mention in m last post regarding fixing the device to /dev/adu2sb that that was an example from OSX but its about the same on Linux.

Re
Sean M

Right. I’m wondering what changes might be required in the Vera plugin to talk to a ser2sock AD2USB client vs a “dumb” ser2net socket that just relays everything from the serial port?

I noticed that the AD2USB Mono GUI can’t talk to a ser2net socket.

I’m having trouble with the AD2USB + Vera2 integration and was wondering if anyone can provide some insight. I can’t seem to get my alarm to arm/disarm (basically no inputs) from my Vera.

I’ve gotten the files installed from code.mios.com.
I am able to see the Faults being triggered.
I am able to see the status when it is being armed/disarm on the physical keypad.

I only have 1 partition so I entered 1 in numPartitions
I have 2 physical keypads, one at keypad address 16 and another at 17. I’ve entered these in keypad address as “16,17”

Any ideas?