Info on elkrp to interface with Asterisk

midian

Member
Hello,

I am interested in working on a 3rd party module to interface the Elk M1 with Asterisk 1.6 such that the Elk can have a SIP extension to dial out. At the moment, I am forced to use an ATA (Analog Telephone Adapter). My original idea is to simply use a serial expander and send text strings to a daemon. However, after giving it some thought, I would rather poll system events from the M1EXP to build macros based on system alarms and state change. Does any one have any information on the M1EXP protocol? Am I correct that port 2601 communications are the way to go?

By the way, all code and binaries for this project will be openSource and publicly posted.

Thanks for any help or ideas.
 
you are looking for the Elk M1 ASCII protocol which can be downloaded from ...
Ah, it simply uses RS232! That is awesome and will work perfectly.

Look around the forums as there are already possible starting points such as this Perl script. http://www.cocoontech.com/index.php?showto...=ASCII+protocol
Thank you very much for the link. I have to use C for this module. However, perl is the swiss army knife of scripting. I will certainly put this to use in some capacity as well.

I am really glad to see other programmers/makers on this site. I will surely come back and check in more often. Also, I will post details about some of my projects in case others are interested too. Thanks again.
 
tell us more about your plans and what you want your Asteriks machine to do for you depending on the ELK inputs..... it sure sounds like an interesting project
 
tell us more about your plans and what you want your Asteriks machine to do for you depending on the ELK inputs..... it sure sounds like an interesting project

Sorry for the late reply. I subscribed to this thread to be email notified, but it did not seem to work. Any way, I completed this project with a very simple solution. Here is the summary:

Project Inspiration:
As you all know, the voice module can only perform one task at a time. I have my Elk configured to announce the zone that has been violated upon alarm so that I know what to do at 2am when I am half asleep. However, I also configured a task to dial 2 cell phones upon alarm too. This double usage of the voice module presents a problem because the audible voice announcing the alarm and what has been violated would get cut out by the phone dialing. This rendered the voice functionality nearly useless.

Fortunately, I already run Asterisk, an open source (and awesome!) VOIP (Voice over Internet Protocol) phone system. I thought there must be some easy way to "tie" asterisk and the Elk M1 together so that I could let Asterisk do the phone dialing and leave the voice module for more important things, like actually announcing what is happening during an alarm.

Project Solution:
At first I considered writing an add-in module for Asterisk that would interface with the Elk over rs232. However, I found a much simpler and easier solution. the solution in short is:

* Upon alarm, the Elk task sends an email to a dedicated email box. The email contains a preset code identifying the type of alarm, bugler, fire, etc
* A cron job (scheduled task for non Linux types), polls the dedicated box every 30 seconds
* When and email is found, the script parses for the known codes in the body of the message
* If a pre-defined code is found, the script generates a "Asterisk Call File" and drops it into the Asterisk outbound spool queue
* The Asterisk spooler processes the call file by dialing the requested phone number and playing back a pre-recorded voice message 5 times. (The message plays 5 times in case the call goes to voice mail, etc).

The end result is that I got exactly what I wanted and did not have to write anything more complicated than a simple Bash script and create a simple Asterisk macro. If there are any other Asterisk users who would be interested, I would be happy to post the complete body of code. Alternatively, if any one is curious about Asterisk, I would be happy to answer any questions. Also, here are some great informational links:

* Free PBX (Awesome web front-end for Asterisk) - http://freepbx.org/
* Asterisk software and info: http://www.asterisk.org/
* Digium TDM410, a great PC card to interface with POTS (Plain Old Telephone Service) lines. http://www.digium.com/en/products/analog/tdm410.php
 
Back
Top