On 10/12/07, <b class="gmail_sendername">Yair Hakak</b> &lt;<a href="mailto:yair@hakak.com">yair@hakak.com</a>&gt; wrote:<div><span class="gmail_quote"></span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div>&nbsp;you&#39;ll have to excuse the ignorance (i&#39;m a software guy, not a telcom guy..) </div>
<div>&nbsp;Is there any way to know if a channel has been answered by an automatic system (like voicemail) rather than a human being?</div>
<div>&nbsp;Specifically, I want to use a .call to make a call on a channel and only do something if a person answers, not a machine of any kind. Is this even possible, or is an answered channel an answered channel?</div></blockquote>
<div><br>Asterisk 1.4 has the AMD() application that uses several thresholds (which you can vary) to determine if the other end is a human or machine:<br><br>&nbsp; -= Info about application &#39;AMD&#39; =-<br><br>[Synopsis]<br>
Attempts to detect answering machines<br><br>[Description]<br>&nbsp; AMD([initialSilence][|greeting][|afterGreetingSilence][|totalAnalysisTime]<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; [|minimumWordLength][|betweenWordsSilence][|maximumNumberOfWords]<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; [|silenceThreshold])
<br>&nbsp; This application attempts to detect answering machines at the beginning<br>&nbsp; of outbound calls.&nbsp; Simply call this application after the call<br>&nbsp; has been answered (outbound only, of course).<br>&nbsp; When loaded, AMD reads 
amd.conf and uses the parameters specified as<br>&nbsp; default values. Those default values get overwritten when calling AMD<br>&nbsp; with parameters.<br>- &#39;initialSilence&#39; is the maximum silence duration before the greeting. If
<br>&nbsp;&nbsp; exceeded then MACHINE.<br>- &#39;greeting&#39; is the maximum length of a greeting. If exceeded then MACHINE.<br>- &#39;afterGreetingSilence&#39; is the silence after detecting a greeting.<br>&nbsp;&nbsp; If exceeded then HUMAN.
<br>- &#39;totalAnalysisTime&#39; is the maximum time allowed for the algorithm to decide<br>&nbsp;&nbsp; on a HUMAN or MACHINE.<br>- &#39;minimumWordLength&#39;is the minimum duration of Voice to considered as a word.<br>- &#39;betweenWordsSilence&#39; is the minimum duration of silence after a word to
<br>&nbsp;&nbsp; consider the audio that follows as a new word.<br>- &#39;maximumNumberOfWords&#39;is the maximum number of words in the greeting.<br>&nbsp;&nbsp; If exceeded then MACHINE.<br>- &#39;silenceThreshold&#39; is the silence threshold.
<br>This application sets the following channel variable upon completion:<br>&nbsp;&nbsp;&nbsp; AMDSTATUS - This is the status of the answering machine detection.<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Possible values are:<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; MACHINE | HUMAN | NOTSURE | HANGUP
<br>&nbsp;&nbsp;&nbsp; AMDCAUSE - Indicates the cause that led to the conclusion.<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Possible values are:<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; TOOLONG-&lt;%d total_time&gt;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; INITIALSILENCE-&lt;%d silenceDuration&gt;-&lt;%d initialSilence&gt;
<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; HUMAN-&lt;%d silenceDuration&gt;-&lt;%d afterGreetingSilence&gt;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; MAXWORDS-&lt;%d wordsCount&gt;-&lt;%d maximumNumberOfWords&gt;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; LONGGREETING-&lt;%d voiceDuration&gt;-&lt;%d greeting&gt;
<br></div></div><br>-- <br>j.