So I&#39;m making calls using VoiceNetwork, are you suggesting there&#39;s a problem there?  Or on the line where the call is received (I&#39;ve tried on a couple of different networks/providers)?<br><br><div class="gmail_quote">
On Tue, Mar 16, 2010 at 9:34 PM, Aloysius Lloyd <span dir="ltr">&lt;<a href="mailto:lloyd.aloysius@gmail.com">lloyd.aloysius@gmail.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
You inbound DID Provider<div><div></div><div class="h5"><br>
<br><br><div class="gmail_quote">On Tue, Mar 16, 2010 at 9:16 PM, Michael De Lorenzo <span dir="ltr">&lt;<a href="mailto:delorenzodesign@gmail.com" target="_blank">delorenzodesign@gmail.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">

What do you mean about the provider?  I&#39;m not sure I understand that part.  I&#39;m trying to call a number and have the call&#39;s recipient type the digits in.<div><div></div><div><br><br><div class="gmail_quote">
On Tue, Mar 16, 2010 at 9:07 PM, Aloysius Lloyd <span dir="ltr">&lt;<a href="mailto:lloyd.aloysius@gmail.com" target="_blank">lloyd.aloysius@gmail.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="border-left:1px solid rgb(204, 204, 204);margin:0pt 0pt 0pt 0.8ex;padding-left:1ex">here is the test script I used<div><br></div><div><div>session:answer();</div><div>digits = session:playAndGetDigits(1, 4, 1, 5000, &quot;#&quot;, &quot;enter-digits.wav&quot;, &quot;&quot;, &quot;\\d+&quot;);</div>


<div><br>
</div><div>Here is the console log</div><div><div><br></div><div>2010-03-17 01:04:50.374761 [DEBUG] switch_ivr_play_say.c:1444 done playing file</div><div><b>2010-03-17 01:04:50.874736 [DEBUG] switch_rtp.c:2417 RTP RECV DTMF 1:800</b></div>



<div><b>2010-03-17 01:04:51.104725 [DEBUG] switch_rtp.c:2417 RTP RECV DTMF 2:640</b></div><div><b>2010-03-17 01:04:51.414710 [DEBUG] switch_rtp.c:2417 RTP RECV DTMF 3:800</b></div><div><b>2010-03-17 01:04:51.774692 [DEBUG] switch_rtp.c:2417 RTP RECV DTMF 4:640</b></div>



<div>2010-03-17 01:04:51.774692 [DEBUG] switch_ivr_play_say.c:1737 Test Regex [1234][\d+]</div><div><br></div></div>
You may have some issue with the provider. Check using a local extension.</div><div><div></div><div><div><br><br><div class="gmail_quote">On Tue, Mar 16, 2010 at 8:51 PM, Michael De Lorenzo <span dir="ltr">&lt;<a href="mailto:delorenzodesign@gmail.com" target="_blank">delorenzodesign@gmail.com</a>&gt;</span> wrote:<br>



<blockquote class="gmail_quote" style="border-left:1px solid rgb(204, 204, 204);margin:0pt 0pt 0pt 0.8ex;padding-left:1ex">Ok, I updated the console log level, and there are no DTMF values being detected:<br><br>4268 -&gt; 74.51.38.156 port 15150 codec: 0 ms: 20<br>



2010-03-16 20:49:06.534030 [DEBUG] switch_rtp.c:1181 Starting timer [soft] 160 bytes per 20ms<br>
2010-03-16 20:49:06.535030 [NOTICE] sofia_glue.c:3128 Pre-Answer sofia/external/19736327407!<br>2010-03-16 20:49:13.762610 [DEBUG] sofia.c:4139 Channel sofia/external/19736327407 entering state [completing][200]<br>2010-03-16 20:49:13.762610 [DEBUG] sofia.c:4150 Remote SDP:<br>




v=0<br>o=root 21648 21649 IN IP4 74.51.38.156<br>s=session<br>c=IN IP4 74.51.38.156<br>t=0 0<br>m=audio 15150 RTP/AVP 0 101<br>a=rtpmap:0 PCMU/8000<br>a=rtpmap:101 telephone-event/8000<br>a=fmtp:101 0-16<br>a=silenceSupp:off - - - -<br>




a=ptime:20<br><br>2010-03-16 20:49:13.762610 [DEBUG] sofia.c:4139 Channel sofia/external/19736327407 entering state [ready][200]<br>2010-03-16 20:49:13.763613 [NOTICE] sofia.c:4663 Channel [sofia/external/19736327407] has been answered<br>




2010-03-16 20:49:13.763613 [DEBUG] switch_ivr_originate.c:3107 Originate Resulted in Success: [sofia/external/19736327407]<br>2010-03-16 20:49:13.763613 [DEBUG] switch_cpp.cpp:497 (sofia/external/19736327407) State Change CS_CONSUME_MEDIA -&gt; CS_SOFT_EXECUTE<br>




2010-03-16 20:49:13.763613 [DEBUG] switch_core_session.c:1018 Send signal sofia/external/19736327407 [BREAK]<br>2010-03-16 20:49:13.764618 [DEBUG] switch_ivr_play_say.c:1178 Codec Activated L16@8000hz 1 channels 20ms<br>



2010-03-16 20:49:13.764618 [DEBUG] switch_core_state_machine.c:314 (sofia/external/19736327407) Running State Change CS_SOFT_EXECUTE<br>
2010-03-16 20:49:13.764618 [DEBUG] switch_core_state_machine.c:354 (sofia/external/19736327407) State SOFT_EXECUTE<br>2010-03-16 20:49:13.764618 [DEBUG] mod_sofia.c:510 SOFIA SOFT_EXECUTE<br>2010-03-16 20:49:13.764618 [DEBUG] switch_core_state_machine.c:200 sofia/external/19736327407 Standard SOFT_EXECUTE<br>




2010-03-16 20:49:13.764618 [DEBUG] switch_core_state_machine.c:354 (sofia/external/19736327407) State SOFT_EXECUTE going to sleep<br>2010-03-16 20:49:13.794735 [DEBUG] switch_rtp.c:2055 Correct ip/port confirmed.<br>2010-03-16 20:49:25.055402 [DEBUG] switch_ivr_play_say.c:1470 done playing file<br>




2010-03-16 20:49:30.074803 [INFO] switch_cpp.cpp:1142 Digits received during call from playAndGetDigits: <br>2010-03-16 20:49:30.074803 [INFO] switch_cpp.cpp:1142 Did this check out? no<div><div></div><div><br>
<br><div class="gmail_quote">On Tue, Mar 16, 2010 at 8:37 PM, Aloysius Lloyd <span dir="ltr">&lt;<a href="mailto:lloyd.aloysius@gmail.com" target="_blank">lloyd.aloysius@gmail.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="border-left:1px solid rgb(204, 204, 204);margin:0pt 0pt 0pt 0.8ex;padding-left:1ex"><div>set the console log level to 7. Then you can see the DTMF values in console log , while you are pressing the keys.</div>




<div><br></div><div><font color="#888888">Lloyd</font><div><div></div><div><br><br><div class="gmail_quote">On Tue, Mar 16, 2010 at 8:23 PM, Michael De Lorenzo <span dir="ltr">&lt;<a href="mailto:delorenzodesign@gmail.com" target="_blank">delorenzodesign@gmail.com</a>&gt;</span> wrote:<br>





<blockquote class="gmail_quote" style="border-left:1px solid rgb(204, 204, 204);margin:0pt 0pt 0pt 0.8ex;padding-left:1ex">So I tried Michael&#39;s suggestion of:<br><br><span style="font-family:arial,sans-serif;font-size:13px;border-collapse:collapse"><font face="&#39;courier new&#39;, monospace"><div>





digits
 = session:playAndGetDigits(1, 4, 1, 5000, &quot;#&quot;, get_digits_message, &quot;&quot;, 
&quot;\\d+&quot;);<br><br></div><span style="font-family:times new roman,serif">but it still didn&#39;t detect that I had pressed any keys.  What would cause this?  Is there someplace I can check to see if anything at all is being detected?</span><br>






</font></span><br><br><div class="gmail_quote"><div><div></div><div>On Tue, Mar 16, 2010 at 5:00 PM, Michael Collins <span dir="ltr">&lt;<a href="mailto:msc@freeswitch.org" target="_blank">msc@freeswitch.org</a>&gt;</span> wrote:<br>





</div></div><blockquote class="gmail_quote" style="border-left:1px solid rgb(204, 204, 204);margin:0pt 0pt 0pt 0.8ex;padding-left:1ex"><div><div></div><div>
<br><br><div class="gmail_quote"><div>On Tue, Mar 16, 2010 at 1:21 PM, Michael De Lorenzo <span dir="ltr">&lt;<a href="mailto:delorenzodesign@gmail.com" target="_blank">delorenzodesign@gmail.com</a>&gt;</span> wrote:<br>






<blockquote class="gmail_quote" style="border-left:1px solid rgb(204, 204, 204);margin:0pt 0pt 0pt 0.8ex;padding-left:1ex">

<span style="font-family:arial,sans-serif;font-size:13px;border-collapse:collapse"><div>I&#39;m having some trouble getting consistent results with playAndGetDigits, sometimes the digits are record and other times they&#39;re not.  It seemed to have something to do with how quickly the digits were pressed, but now that no longer seems to be the case.</div>









<div><br></div><div>I&#39;m trying to have users press a confirmation code, in this case &quot;1111&quot; although I&#39;d like to make it accept &quot;1&quot; or &quot;11&quot; or &quot;111&quot; or &quot;1111&quot; if possible.</div>









<div><br></div><div>Can anyone point me in the right direction?</div><div><br></div><br><div><div><font face="&#39;courier new&#39;, monospace">    session = freeswitch.Session(&quot;{ignore_early_media=true}sofia/gateway/&quot; .. provider .. &quot;/1&quot; .. number_to_call);</font></div>









<div><font face="&#39;courier new&#39;, monospace"><br></font></div><div><font face="&#39;courier new&#39;, monospace">    while(session:ready()) do</font></div><div><font face="&#39;courier new&#39;, monospace">       session:answer();</font></div>









<div><font face="&#39;courier new&#39;, monospace">       session:setInputCallback(&quot;onInput&quot;,&quot;true&quot;);</font></div><div><font face="&#39;courier new&#39;, monospace"><br></font></div><div><font face="&#39;courier new&#39;, monospace">       --playbackMessage(check_message);</font></div>









<div><font face="&#39;courier new&#39;, monospace">       digits = session:playAndGetDigits(4, 4, 1, 5000, &quot;&quot;, get_digits_message, &quot;&quot;, &quot;[1]&quot;);</font></div></div></span></blockquote></div><div>






<br>

You are specifying a minimum of four and a maximum of four digits. Also, your regex will match any string that has a digit 1 in it, which may or may not be what you are looking for. Lastly, you haven&#39;t specified a terminator key (like &quot;#&quot;) but you are giving the user only one try and waiting 5000ms for the entry. Try something like this:<br>







<br><span style="font-family:arial,sans-serif;font-size:13px;border-collapse:collapse"><font face="&#39;courier new&#39;, monospace">digits
 = session:playAndGetDigits(1, 4, 1, 5000, &quot;#&quot;, get_digits_message, &quot;&quot;, 
&quot;\\d+&quot;);</font></span><br><br>Let us know if that works. Oh, one other thing: you might want to add an invalid message because playAndGetDigits will handle invalid input for you. <br><font color="#888888">-MC<br>






</font><br>P.S. - This topic is covered in greater detail in Chapter 7 of the upcoming FreeSWITCH book. ;) <br>
<br> </div><div><blockquote class="gmail_quote" style="border-left:1px solid rgb(204, 204, 204);margin:0pt 0pt 0pt 0.8ex;padding-left:1ex">
<span style="font-family:arial,sans-serif;font-size:13px;border-collapse:collapse"><div><div><font face="&#39;courier new&#39;, monospace">       freeswitch.consoleLog(&quot;info&quot;, digits .. &quot;\n&quot;);</font></div>









<div><font face="&#39;courier new&#39;, monospace">       freeswitch.consoleLog(&quot;info&quot;, &quot;Did this check out? &quot; .. (check_message == true and &quot;yes&quot; or &quot;no&quot; .. &quot;\n&quot;));</font></div>









<div><font face="&#39;courier new&#39;, monospace"><br></font></div><div><font face="&#39;courier new&#39;, monospace">       -- we got what we&#39;re looking for, so we can end this</font></div><div><font face="&#39;courier new&#39;, monospace">       if(check_success) then</font></div>









<div><font face="&#39;courier new&#39;, monospace">          freeswitch.consoleLog(&quot;info&quot;, &quot;A positive response was received from this check.\n&quot;);</font></div><div><font face="&#39;courier new&#39;, monospace">          break;</font></div>









<div><font face="&#39;courier new&#39;, monospace">       else</font></div><div><font face="&#39;courier new&#39;, monospace">          -- not a positive response</font></div><div><font face="&#39;courier new&#39;, monospace">          -- if we reached our max attempts, we&#39;re finished move on</font></div>









<div><font face="&#39;courier new&#39;, monospace">          if(attempts == max_attempts) then</font></div><div><font face="&#39;courier new&#39;, monospace">            freeswitch.consoleLog(&quot;info&quot;, &quot;We&#39;ve reached our maximum attempts for this number.\n&quot;);</font></div>









<div><font face="&#39;courier new&#39;, monospace">            break;</font></div><div><font face="&#39;courier new&#39;, monospace">          end</font></div><div><font face="&#39;courier new&#39;, monospace">       end</font></div>









<div><font face="&#39;courier new&#39;, monospace">    end</font><br></div></div></span><br></blockquote></div></div><br>
<br></div></div>_______________________________________________<br>
FreeSWITCH-users mailing list<br>
<a href="mailto:FreeSWITCH-users@lists.freeswitch.org" target="_blank">FreeSWITCH-users@lists.freeswitch.org</a><br>
<a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>
UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br>
<a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a><br>
<br></blockquote></div><br>
<br>_______________________________________________<br>
FreeSWITCH-users mailing list<br>
<a href="mailto:FreeSWITCH-users@lists.freeswitch.org" target="_blank">FreeSWITCH-users@lists.freeswitch.org</a><br>
<a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>
UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br>
<a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a><br>
<br></blockquote></div><br></div></div></div>
<br>_______________________________________________<br>
FreeSWITCH-users mailing list<br>
<a href="mailto:FreeSWITCH-users@lists.freeswitch.org" target="_blank">FreeSWITCH-users@lists.freeswitch.org</a><br>
<a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>
UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br>
<a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a><br>
<br></blockquote></div><br>
</div></div><br>_______________________________________________<br>
FreeSWITCH-users mailing list<br>
<a href="mailto:FreeSWITCH-users@lists.freeswitch.org" target="_blank">FreeSWITCH-users@lists.freeswitch.org</a><br>
<a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>
UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br>
<a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a><br>
<br></blockquote></div><br></div>
</div></div><br>_______________________________________________<br>
FreeSWITCH-users mailing list<br>
<a href="mailto:FreeSWITCH-users@lists.freeswitch.org" target="_blank">FreeSWITCH-users@lists.freeswitch.org</a><br>
<a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>
UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br>
<a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a><br>
<br></blockquote></div><br>
</div></div><br>_______________________________________________<br>
FreeSWITCH-users mailing list<br>
<a href="mailto:FreeSWITCH-users@lists.freeswitch.org" target="_blank">FreeSWITCH-users@lists.freeswitch.org</a><br>
<a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>
UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br>
<a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a><br>
<br></blockquote></div><br>
</div></div><br>_______________________________________________<br>
FreeSWITCH-users mailing list<br>
<a href="mailto:FreeSWITCH-users@lists.freeswitch.org">FreeSWITCH-users@lists.freeswitch.org</a><br>
<a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>
UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br>
<a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a><br>
<br></blockquote></div><br>