There are two ways....<br><br>Most phones will return a USER_BUSY release code if you bridge to a phone that's busy. If the phone does then you can continue_on_fail so that you (pre-)answer the call and play that message after the bridge. Something like:<br>
<blockquote><extension name="Local_Extension"><br> <condition field="destination_number" expression="^(1\d{3})$"><br> <action application="set" data="dialed_extension=$1"/><br>
<action application="export" data="dialed_extension=$1"/><br> <action application="set" data="call_timeout=30"/><br> <action application="set" data="hangup_after_bridge=true"/> <!-- Hangup on successful call --><br>
<action application="set" data="continue_on_fail=true"/> <!-- Don't hangup on failed call, continue to IVR prompt --><br> <action application="hash" data="insert/${domain_name}-last_dial_ext/${dialed_extension}/${uuid}"/><br>
<action application="hash" data="insert/${domain_name}-last_dial_ext/global/${uuid}"/><br> <action application="bridge" data="user/${dialed_extension}%${domain_name}"/><br>
<!-- Put the IVR prompt here, see <a href="http://wiki.freeswitch.org/wiki/Misc._Dialplan_Tools_play_and_get_digits">http://wiki.freeswitch.org/wiki/Misc._Dialplan_Tools_play_and_get_digits</a> --><br> </condition><br>
</extension><br></blockquote>The 2nd option is that you use Limit to determine if another person is already on a call to the phone. That only really works if you run the the only servers that call the phone since it requires tracking all calls to the phone. It will sometimes work better though - especially if the phone has multiple lines. <a href="http://wiki.freeswitch.org/wiki/Limit">http://wiki.freeswitch.org/wiki/Limit</a><br>
<br>-Steve<br><br><br><div class="gmail_quote">On 11 July 2011 03:25, fieldpeak <span dir="ltr"><<a href="mailto:fieldpeak@gmail.com">fieldpeak@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
Hi Gurus,<br> <br>Could anyone advise how to realize have FS to play a voice prompt e.g. 'the extension you dialed is busy now, please dial the other exsention' to replacing busy tone when the called extension is in a call...<br>
<br>the details is below,<br><br>When calling to FS, the FS will play IVR "welcome to call us, please input the extension number, for operator please press 0",<br>then the caller input the extension number, in case the extension is in a call, the caller will hear busy tone...<br>
it needs the system play "the extension you dailed is busy, please dial the other extension", currently my dial plan as following, could anyone advise how to change based on below dial plan or any other new dail plan can realize it...<br>
<br>Thanks a lot!<br><br> <extension name="Local_Extension"><br> <condition field="destination_number" expression="^(1\d{3})$"><br> <action application="set" data="dialed_extension=$1"/><br>
<action application="export" data="dialed_extension=$1"/><br> <action application="set" data="ringback=${us-ring}"/><br> <action application="set" data="transfer_ringback=$${hold_music}"/><br>
<action application="set" data="call_timeout=30"/><br> <action application="set" data="hangup_after_bridge=true"/><br> <br> <!-- to enable voice mail, set continue_on_fail=true below --><br>
<action application="set" data="continue_on_fail=false"/><br> <action application="hash" data="insert/${domain_name}-last_dial_ext/${dialed_extension}/${uuid}"/><br>
<action application="hash" data="insert/${domain_name}-last_dial_ext/global/${uuid}"/><br> <action application="bridge" data="sofia/internal/${dialed_extension}%${domain_name}"/><br>
<action application="answer"/><br> <br> <action application="sleep" data="1000"/><br> <action application="bridge" data="loopback/app=voicemail:default ${domain_name} ${dialed_extension}"/><br>
</condition><br> </extension><br> <br> <br> <extension name="IVR" ><br> <condition field="destination_number" expression="^888$"><br> <action application="answer"/><br>
<action application="sleep" data="2000"/><br> <action application="ivr" data="IVR"/><br> </condition><br> </extension><br> <br>
<!-- --><br> <menu name="IVR"<br> greet-long="C:/VSWITCH/recordings/greeting_tts.wav"<br> greet-short="C:/VSWITCH/recordings/greeting_tts.wav"<br> invalid-sound="ivr/ivr-that_was_an_invalid_entry.wav"<br>
exit-sound="voicemail/vm-goodbye.wav"<br> confirm-macro=""<br> confirm-key=""<br> tts-engine="flite"<br> tts-voice="rms"<br> confirm-attempts="3"<br>
timeout="10000"<br> inter-digit-timeout="2000"<br> max-failures="3"<br> max-timeouts="3"<br> digit-len="5"><br> <entry action="menu-exec-app" digits="/(^\*\d{3,5}$|^\d{3,5}$)/" param="transfer $1 XML default"/><br>
</menu><br> <br>Regards,<br>Charles<br>
<br>_______________________________________________<br>
Join us at ClueCon 2011, Aug 9-11, Chicago<br>
<a href="http://www.cluecon.com" target="_blank">http://www.cluecon.com</a> 877-7-4ACLUE<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><div style="visibility: hidden; left: -5000px; position: absolute; z-index: 9999; padding: 0px; margin-left: 0px; margin-top: 0px; overflow: hidden; word-wrap: break-word; color: black; font-size: 10px; text-align: left; line-height: 130%;" id="avg_ls_inline_popup">
</div>