Another good transition tool to play with may be mod_dialplan_asterisk which is in tree.<br><br>Once loaded in modules.conf.xml it can be used in your sofia profile by adding "asterisk" as the dialplan parameter.<br>
You can also transfer calls to it by specifying it as the dialplan param in the transfer or execute_extension apps.<br><br>it's not entirely like the real asterisk dialplan but it is at least a close familiarity.<br>You cannot include contexts in each other in ours because we do all our dialplan logic before the call.<br>
<br>It's structured in the same way so you can create context default <br><br>[default]<br>; and you can use comments the same way<br>; here is a demo that is close to the extensions.conf in tree that installs by default<br>
<br>------------------<br>[default]<br><br>; Things you're used to....<br>exten => music,n,Dial(SIP/<a href="mailto:1234@conference.freeswitch.org">1234@conference.freeswitch.org</a>|120)<br><br>; similar pattern matching and caller-id match.<br>
exten => _1XXXXX,n,set(cool=${EXTEN})<br>exten => _1XXXXX,n,set(myvar=true)<br>exten => _1XXXXX,n,Goto(default|music)<br>exten => 2137991400/1000,n,Goto(default|music)<br><br>; we also embellished things a bit and added some of our own goodies<br>
; Some new magic you can do.... if you start the exten string with a ~ it implies PCRE regex<br>; *NOTE* the ,n, is there for familiarity purposes we do not parse it anyway nor will we honor line numbers.<br><br>exten => ~^(18(0{2}|8{2}|7{2}|6{2})\d{7})$,n,enum($1)<br>
exten => ~^(18(0{2}|8{2}|7{2}|6{2})\d{7})$,n,bridge(${enum_auto_route})<br><br>; instead of exten, put anyting about the call you would rather match on.<br>; either the names of a field in caller_profile or a string of variables to expand.<br>
caller_id_number => 2137991400,n,Goto(default|music)<br>${sip_from_user} => bill,n,Goto(default|music)<br><br><br>Anyway you will find the XML dialplan more flexible but this may serve as a stepping stone for beginners.<br>
<br><br><br><br><div class="gmail_quote">On Fri, May 30, 2008 at 7:07 PM, Michael Collins <<a href="mailto:mcollins@fcnetwork.com">mcollins@fcnetwork.com</a>> 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 link="blue" vlink="purple" lang="EN-US">
<div>
<p><font face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial;">FYI,</span></font></p>
<p><font face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial;"> </span></font></p>
<p><font face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial;">I create a new wiki page:</span></font></p>
<p><font face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial;"><a href="http://wiki.freeswitch.org/wiki/Rosetta_stone" target="_blank">http://wiki.freeswitch.org/wiki/Rosetta_stone</a></span></font></p>
<p><font face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial;"> </span></font></p>
<p><font face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial;">I thought maybe those who know about Asterisk and FreeSWITCH
both could start dropping stuff in there. I think that people coming from
Asterisk might have an easier time if they had some sort of frame of reference.
Note that I put a disclaimer at the top – there isn't really a
one-to-one Ast-to-FS translation for most of the stuff, but if you said to an
experienced Asterisk user that "conf/dialplan/default.xml" is
analogous to "/etc/asterisk/extensions.conf" then he/she would at
least have a starting point. I'm hoping to add more stuff like the fact
that there aren't really "priorities" in FS but that you can
use scripting langs, ivr menus, etc. to mimic a lot of that kind of
functionality.</span></font></p>
<p><font face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial;"> </span></font></p>
<p><font face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial;">Anyway, your thoughts and suggestions are welcomed. I will
do my best to add stuff as I am able…</span></font></p>
<p><font face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial;"> </span></font></p><font color="#888888">
<p><font face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial;">-MC</span></font></p>
</font></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><br clear="all"><br>-- <br>Anthony Minessale II<br><br>FreeSWITCH <a href="http://www.freeswitch.org/">http://www.freeswitch.org/</a><br>ClueCon <a href="http://www.cluecon.com/">http://www.cluecon.com/</a><br>
<br>AIM: anthm<br><a href="mailto:MSN%3Aanthony_minessale@hotmail.com">MSN:anthony_minessale@hotmail.com</a><br>GTALK/JABBER/<a href="mailto:PAYPAL%3Aanthony.minessale@gmail.com">PAYPAL:anthony.minessale@gmail.com</a><br>
IRC: <a href="http://irc.freenode.net">irc.freenode.net</a> #freeswitch<br><br>FreeSWITCH Developer Conference<br><a href="mailto:sip%3A888@conference.freeswitch.org">sip:888@conference.freeswitch.org</a><br><a href="http://iax:guest@conference.freeswitch.org/888">iax:guest@conference.freeswitch.org/888</a><br>
<a href="mailto:googletalk%3Aconf%2B888@conference.freeswitch.org">googletalk:conf+888@conference.freeswitch.org</a><br>pstn:213-799-1400