[Freeswitch-dev] Searching for a valid extension.

Anthony Minessale anthony.minessale at gmail.com
Mon Oct 11 13:44:47 PDT 2010


We don't have a static monolithic dialplan like asterisk, there can be
many dialplans or dynamic dialplans that reach out to external
services.

The proper way to implement overlap dialing on a per-protocol basis would be:

1) Separate your native channel from the FreeSWITCH channel so you can
create a FreeSWITCH session and attach the native channel.

2) send the call to the configured dialplan and allow that dialplan
module to work out it's own ambiguities and respond:

SWITCH_CAUSE_INVALID_NUMBER_FORMAT or cause 28

3) when you see this cause accept more digits and try again until you
get some other cause code.


This is how it's done in sip by doing an entire new call each time you
need to dial more digits.



The other way which we do in FreeTDM is to define 2 regex, one for
anything that is valid and one for anything that is invalid and
consult this regex on each digit until you know one way or another.






On Mon, Oct 11, 2010 at 3:12 PM, Geovani Ricardo Wiedenhoft
<grw.freeswitch at gmail.com> wrote:
> Hello,
>
> We are completing development of the mod_khomp endpoint for Khomp boards:
> - FXS
> - FXO
> - E1
> - GSM (boards and usb devices)
> - Passive record
> - kommuter
>
> However, we are constrained in our implementation. We needed to verify that
> a given set of digits has a valid extension or if can wait for more digits
> at some points of our code, without making the call.
>
> In our implementation for Asterisk (our Khomp channel), we use the functions
> provided by the Asterisk:
>
> ##############################
> ###############################################
> ASTERISK:
>
> /* \brief Looks for a valid matching extension */
>  - ast_canmatch_extension
>
> /* \brief Looks to see if adding anything to this extension might match
> something. (exists ^ canmatch) */
>  - ast_matchmore_extension
> #############################################################################
>
> Searching for a solution, we implemented within mod_khomp the reading and
> checking functions of digits and expressions in XML, but our implementation
> limits us to XML dialplans, which it would not be compatible if the user
> need the database or other constructions of the dialplan.
>
>
> So, I would like to know what is the possibility of similar functions to be
> implemented in the core?
>
>
>
>
>
>
> Thanks
> :)
>
>
>
>
> Geovani Ricardo Wiedenhoft
>
> _______________________________________________
> FreeSWITCH-dev mailing list
> FreeSWITCH-dev at lists.freeswitch.org
> http://lists.freeswitch.org/mailman/listinfo/freeswitch-dev
> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-dev
> http://www.freeswitch.org
>
>



-- 
Anthony Minessale II

FreeSWITCH http://www.freeswitch.org/
ClueCon http://www.cluecon.com/
Twitter: http://twitter.com/FreeSWITCH_wire

AIM: anthm
MSN:anthony_minessale at hotmail.com
GTALK/JABBER/PAYPAL:anthony.minessale at gmail.com
IRC: irc.freenode.net #freeswitch

FreeSWITCH Developer Conference
sip:888 at conference.freeswitch.org
googletalk:conf+888 at conference.freeswitch.org
pstn:+19193869900



More information about the FreeSWITCH-dev mailing list