<br><br><div class="gmail_quote">On Mon, Oct 12, 2009 at 4:01 AM, homqua <span dir="ltr"><<a href="mailto:ngay01042005@gmail.com">ngay01042005@gmail.com</a>></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;">
<br>
Hi,<br>
I have implemented the solution for tone detection in wiki, and also answer<br>
the channel before detecting the tone:<br>
<condition field="destination_number" expression="^(055138419992)$"><br>
<action application="answer"/><br>
<action application="tone_detect" data="fax 1100 r +15000 transfer fax<br>
XML default"/><br>
<br>
<br>
<extension name="fax"><br>
<condition field="destination_number" expression="^fax$"><br>
<action application="answer" /><br>
<action application="sleep" data="1000"/><br>
<action application="rxfax"<br>
data="/usr/local/freeswitch/storage/fax/${caller_id_number}-${strftime(%Y-%m-%d-%H-%M-%S)}.tiff"/><br>
<action application="set" data="fax_mode=recv"/><br>
<action application="hangup"/><br>
</condition><br>
</extension><br>
<br>
<br>
But FS cannot recognize the tone, and therefore cannot move to fax<br>
extension. Below are the error in FS:<br>
<br>
2009-10-12 10:57:16.702287 [NOTICE] switch_channel.c:602 New Channel<br>
sofia/external/anonymous@anonymous.invalid<br>
[c431f0a3-9231-4724-ba39-9e4ef7edfca2]<br>
2009-10-12 10:57:16.703413 [INFO] mod_dialplan_xml.c:315 Processing<br>
Anonymous->055138419992 in context public<br>
2009-10-12 10:57:16.719288 [NOTICE] switch_ivr.c:1349 Transfer<br>
sofia/external/anonymous@anonymous.invalid to XML[055138419992@default]<br>
2009-10-12 10:57:16.719288 [INFO] mod_dialplan_xml.c:315 Processing<br>
Anonymous->055138419992 in context default<br>
2009-10-12 10:57:16.722289 [NOTICE] mod_dptools.c:649 Channel<br>
[sofia/external/anonymous@anonymous.invalid] has been answered<br>
2009-10-12 10:57:16.722289 [NOTICE] mod_dptools.c:1324 Enabling tone<br>
detection 'fax' '1100'<br>
2009-10-12 10:57:16.723302 [NOTICE] switch_core_state_machine.c:179 Hangup<br>
sofia/external/anonymous@anonymous.invalid [CS_EXECUTE] [NORMAL_CLEARING]<br>
2009-10-12 10:57:16.740285 [NOTICE] switch_core_session.c:1086 Session 1<br>
(sofia/external/anonymous@anonymous.invalid) Ended<br>
2009-10-12 10:57:16.740285 [NOTICE] switch_core_session.c:1088 Close Channel<br>
sofia/external/anonymous@anonymous.invalid [CS_DESTROY]<br>
<br>
And the trace for SIP messages: <a href="http://pastebin.com/m4e47e7d9" target="_blank">http://pastebin.com/m4e47e7d9</a><br>
<br>
If anyone has any idea, tell me please.<br>
Thanks.<br></blockquote><div><br>I think the trouble here is that you don't have anything else in the dialplan after the tone_detect. The tone_detect app is non-block, which means that it doesn't sit there and wait for a tone. If you want the dialplan to sit and wait then do a sleep app after your tone_detect. The other question I would have is this: what happens if the incoming call is not a fax? What do you want to do then?<br>
<br>-MC<br><br></div></div>