Bridging Texecom’s Alarm Signalling Protocol to MQTT

Texecom Premier Elite RKPTexecom makes a nice range of alarm systems called Premier Elite, with products suited for everything from high-end domestic up to large commercial deployments.  The range includes two IP-based communicator modules for wired (Com-IP) or wireless (Com-WiFi) operation.

Normally these communicators would be used with Texecom’s own alarm receiving service, or with a paid-for third-party monitoring service using proprietary software.  I wanted to have a way to integrate the alarm with my own monitoring infrastructure, and with some other IoT projects I’ve got going on, so I spent some time reverse engineering the protocol.

The result of this is a simple Python-based server available on Github which can receive and interpret polling requests and other messages from the alarm in either ContactID or SIA format.  Status updates are then forwarded to interested parties via secure MQTT.

The basic Texecom protocol is unfortunately not very secure at all, having no authentication features beyond the possibility of white-listing a source IP address (which my server supports).  A recent firmware update for the Premier Elite panels does add encryption support, however, which is something that I will be taking a look at in due course.

19 thoughts on “Bridging Texecom’s Alarm Signalling Protocol to MQTT

  1. David

    Hi….

    Are you able to provide any simple instructions as to how I can give your mqtt server a try on a windows box?

    Thanks in advance

  2. Mike Post author

    I don’t really use Windows I’m afraid. It may not run on Windows without modification as it is designed to run as a UNIX daemon, which would need to be converted to a service under Windows. It also requires the Paho MQTT client module for Python, and I couldn’t see a Windows installer for that. Python itself would not be a problem – you can get a windows version from python.org, but use the latest 2.7 release. To be honest you’d probably be quicker running Ubuntu in VirtualBox, or running it on a Raspberry Pi.

  3. David

    Hi

    I tried it earlier with windows python, and its looking for other libraries by the looks of it.

    I will plod on and see how far I can get, else as you say, run it in a VM.

    Thanks for the reply and project!

  4. Rune

    Hi. This is great work from your side and I’m in the middle of trying it out :). The fact that you’ve added MQTT is only brilliant!
    Unfortunately there’s some things which isn’t clear to me, and I was hoping that you could clarify them:
    1) I assume that the ‘alarm server config’ is the IP address + port of the Texecom? (Default port on my ComIP is 10001)
    2) You have default user numbered ‘1000’, I assume that’s from the userlist in Wintex? (Min are from 00 and upwards)

    I’m hoping to get this up and running so I can integrate my alarm into openHAB2 🙂

  5. Mike Post author

    Hi. Apart from the MQTT configuration you can probably leave alarmserver.conf alone. The host in the first section is the address of the listening interface, so 0.0.0.0 to listen on all interfaces. The port is what you put in the ARC config in Wintex so you can either set that to 10001 in alarmserver.conf or make it something different than the Texecom default. I notice I’ve never included an example for accounts.conf, but it is just a tab separated list of account numbers and IP addresses that the server will accept. This has nothing to do with any user numbers in Wintex – it is the Account No on the ARC configuration page. For example, if you run the server on 192.168.1.50 and set the port to 12345, with an /etc/alarmserver/accounts.conf containing one line “7777 192.168.1.60” then this will accept connections from your alarm on 192.168.1.60 with the following configuration set under “ARC 1” in Wintex Comms options:

    Pri Tel No: 192.168.1.50/12345
    Sec Tel No: Blank
    Account No: 7777
    Dial Attempts: 3
    Protocol: SIA Level 2/3
    Protocol Options: Connect Via IP, Send SIA Text
    Protocol Options 2: Use ComPort

    Hope this helps. Message me using the contact form if you are still stuck and I can send you some Wintex screenshots.

    Mike

  6. Richard Collin

    Fantastic work Mike.
    I am building a nodejs home automation system based on raspberry pi (not quite ready for primetime) and have used this to write a javascript version. It works really well, although I have not integrated MQTT or the account filtering. I am obviously happy to make the code available, if you are interested? I could implement MQTT and account filtering, but not sure there is any point, given your version works perfectly well.

    Any thoughts on reverse engineering the protocol to log into the Panel? I would like to be able to perform actions on the alarm like ‘arm’.

    Once again, thanks for the great work.

    /Richard

  7. Mike Post author

    Hi Richard,

    Email me a link to your nodejs version through the contact form and I’ll give you a mention here.

    Next thing I’d like to look at when I get time is the communicator encryption feature. After that I’d consider looking at the Wintex protocol, but it isn’t going to be any time soon I’m afraid! I’d also like to be able to get live zone data out of my system for a home automation project. Because the ComIP only supports one connection at a time I don’t think this would be possible without hooking up to a second COM port on the panel. I had in mind to use a Raspberry Pi or similar for that, rather than spending the money on a second ComIP.

    Mike

  8. David Wallis

    setting the alarm is easy, there is a protocol called the simple protocol, I’ve signed an nda and have some copy but if you Google you can find most of what you need.

    if your using a premier panel then you can enable the crestron protocol for realtime zone statuses.

    After that there is a new protocol called the connect protocol which is in v4. x firmware which I’m running a beta version of, and it’s impressive!!

    Cheers

    David

  9. Fedor

    Could anybody share the details how to use Crestron protocol to get realtime zone updates? I’ve connected Pi to Com2 set to Crestron, but now I’m lost a bit as I couldn’t find any information on protocol

  10. Stu

    Hi,

    Probably a silly question, but I am new to MQTT so still learning, but what would be the topic I should be subscribing to when running alarmrx.py, so I can then take the info and pass onto another piece of software?

    Thanks…

  11. Mike Post author

    /alarms/# will show you everything for all accounts, or /alarms/1234/event is probably the one you really want (where 1234 is whatever you set as your account number).

  12. Stu

    Thank you for the reply. Exactly what I needed. Now I’ve got this working, I now need to get mqttwarn working..

  13. Stu

    Sorry, hopefully my final question. Firstly though, I wanted to say thank you for coding this. It’s really opened up what I can now do with my texecom alarm in regards to alerts. Fantastic job.

    I’m running both alarm_server and mqttwarn successfully, and alerts are being generated exactly as I need. Only query I have though, is that when running alarm_server, I am constantly seeing ‘Polling deadline missed’ messages. The actual connection to the texecom alarm works fine, and as soon as an ‘event’ occurs at the alarm side, alarm_server receives it straight away, so the connection between alarm_server and the texecom alarm is working. Should I be concerned about these polling errors? Will alarm_server stop connecting to the texecom alarm eventually? If there are no issues with the message, can they be suppressed (is it just a case of changing the logging level to ERROR?).

    Kind regards…

  14. Mike Post author

    You need to configure the panel to poll the server, which is a separate setting to the communicator options. Once you’ve done that the warnings will go away, and you’ll get an alert if someone cuts your internet connection. If you have Wintex then look for “Radio-Pad and Com Port Options” under the Comms section. Look for “Com-IP Details” under whichever COM port your ComIP is wired to and fill in the IP address of your server under Polling/SMG IP Address, and the port number alarm_server is listening on under Name/SMG port.

  15. Stu

    Ah ok. Thanks for replying. I did have that set originally, but must have blanked it out at some point. I’ve added the IP address of the raspberry pi running alarm_server and also the port that is configured in alarmserver.conf:
    [server]
    port = 10500

    But I’m still seeing ‘Polling deadline missed’ messages (alarm_server has been restarted).

  16. Mike Post author

    Not sure then. That message definitely means that the Pi isn’t receiving the periodic polling messages from the panel. Check you’ve configured the polling IP/port against the right COM port for your ComIP. Also remember that the ComIP can only do one thing at a time, so if you’re still connected with Wintex (even if it’s idle) then it can’t poll and you’ll get timeouts. I just checked the configuration for my panel and didn’t notice anything else beyond what I’ve already mentioned.

  17. Stu

    Ok, thanks again for replying. I will have to go through all of the settings on both the pi and Wintex. It all looks like it’s setup as per your response, but I’m sure there’s some minor setting that needs changing.

    If I cannot resolve this though, is there any issue with getting the polling errors. Would it eventually stop the alarm_server from receiving from the alarm?

    Thanks….

  18. Mike Post author

    No it will be fine without it, although you might get “ATS Failed” messages on your keypads sometimes (and you can just ignore these). You could comment out the line near the end of alarmrx.py where it starts the polling thread (manager.start_polling_watchdog()) if you want to disable the checks on the server side. I guess you aren’t going to get much benefit from the polling feature anyway if you are running the server on your LAN.

    Mike

  19. Stu

    Just had a face palm moment when I realised that Poll IP every xx was set to 0!! I’ve now set this to 2 and I am seeing poll requests from the texecom. Thank you so much Mike for your help in setting this up, and sorry for all the questions.

    Kind regards

Leave a Reply

Your email address will not be published. Required fields are marked *