Openzap extension can't use outside lines.
I obviously need to set a <variable name="toll_allow" value="domestic,international,local"/> somewhere but I can't figure out what file to put it in. The examples all show it in the directory/default/xxxx.xml files but those appear to be sip only. In any event creating files in that directory for my extension did nothing to help the problem. The only places I have the extension mentioned is in the openzap.conf file and dialplan/default/00_incoming-1.xml. Adding a <variables ... element to the latter does nothing. How do I set that variable? Or where? Thanks, Jim.
Variables set in the directory/default/xxxx.xml files apply to users who make authenticated calls through FS. Generally those will be SIP phones. Let's back up a step. What problem are you trying to solve, i.e., why is it that you need to set the toll_allow variable? What endpoint is making an openzap call? -MC On Sat, Apr 3, 2010 at 12:17 PM, Jim <jim@k4gvo.com> wrote:
I obviously need to set a <variable name="toll_allow" value="domestic,international,local"/> somewhere but I can't figure out what file to put it in. The examples all show it in the directory/default/xxxx.xml files but those appear to be sip only. In any event creating files in that directory for my extension did nothing to help the problem.
The only places I have the extension mentioned is in the openzap.conf file and dialplan/default/00_incoming-1.xml. Adding a <variables ... element to the latter does nothing.
How do I set that variable? Or where?
Thanks, Jim.
_______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
Michael Collins wrote:
Variables set in the directory/default/xxxx.xml files apply to users who make authenticated calls through FS. Generally those will be SIP phones.
Let's back up a step. What problem are you trying to solve, i.e., why is it that you need to set the toll_allow variable? What endpoint is making an openzap call?
-MC Hi, Michael,
I have multiple sip phone that are working fine. When I dial a 10 digit number they connect with my sip provider and place the call. The openzap configured phone gets dial tone and can call other extensions, however when I dial a 10 digit number it gives me a busy. In the log I see it appears to be failing on the toll_allow test: Dialplan: OpenZAP/1:1/7707190068 parsing [default->local_call] continue=false Dialplan: OpenZAP/1:1/7707190068 Regex (FAIL) [local_call] ${toll_allow}() =~ /local/ break=on-false Dialplan: OpenZAP/1:1/7707190068 parsing [default->domestic_call] continue=false Dialplan: OpenZAP/1:1/7707190068 Regex (FAIL) [domestic_call] ${toll_allow}() =~ /domestic/ break=on-false Dialplan: OpenZAP/1:1/7707190068 parsing [default->international.example.com] continue=false Dialplan: OpenZAP/1:1/7707190068 Regex (FAIL) [international.example.com] ${toll_allow}() =~ /international/ break=on-false This is the area when it should be placing the call, I belive. When placing a call from a sip phone I see: Dialplan: sofia/internal/1003@192.168.2.51 parsing [default->local_call] continue=false Dialplan: sofia/internal/1003@192.168.2.51 Regex (PASS) [local_call] ${toll_allow}(domestic,international,local) =~ /local/ break=on-false Dialplan: sofia/internal/1003@192.168.2.51 Regex (PASS) [local_call] destination_number(7707190068) =~ /^(\d{10})$/ break=on-false Dialplan: sofia/internal/1003@192.168.2.51 Action set(effective_caller_id_number=${outbound_caller_id_number}) Dialplan: sofia/internal/1003@192.168.2.51 Action set(effective_caller_id_name=${outbound_caller_id_name}) Dialplan: sofia/internal/1003@192.168.2.51 Action set(continue_on_fail=true) Dialplan: sofia/internal/1003@192.168.2.51 Action bridge(sofia/gateway/${default_gateway}/7707190068) I simply want this extension to be able to dial out. The configuration is 99% default. Thanks, Jim.
On Sat, Apr 3, 2010 at 12:17 PM, Jim <jim@k4gvo.com <mailto:jim@k4gvo.com>> wrote:
I obviously need to set a <variable name="toll_allow" value="domestic,international,local"/> somewhere but I can't figure out what file to put it in. The examples all show it in the directory/default/xxxx.xml files but those appear to be sip only. In any event creating files in that directory for my extension did nothing to help the problem.
The only places I have the extension mentioned is in the openzap.conf file and dialplan/default/00_incoming-1.xml. Adding a <variables ... element to the latter does nothing.
How do I set that variable? Or where?
Thanks, Jim.
_______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org <mailto:FreeSWITCH-users@lists.freeswitch.org> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
------------------------------------------------------------------------
_______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
I looked in mod_openzap.c and I didn't see any references to channel variables. However, you have context and dialplan options. I suggest that you create a dialplan context just for your FXS port(s). Try this. Create conf/dialplan/fxs-ports.xml: <include> <context name="fxs-ports"> <extension name="outbound"> <condition field="destination_number" expression="^(.*)$"> <action application="set" data="toll_allow=local,domestic,international"/> <action application="transfer" data="$1 XML default"/> </condition> </extension> </context> </include> Then in your openzap.conf.xml change the context for the analog span(s) with the FXS ports: <param name="context" value="default"/> Restart FS after making these changes and then give it a shot. You should see the call from the analog phone going into context "fxs-ports" and then get transferred over to the default context where it will act like your SIP phones because we manually set the ${toll_allow} chan var. -MC On Sun, Apr 4, 2010 at 4:48 AM, Jim <jim@k4gvo.com> wrote:
Michael Collins wrote:
Variables set in the directory/default/xxxx.xml files apply to users who make authenticated calls through FS. Generally those will be SIP phones.
Let's back up a step. What problem are you trying to solve, i.e., why is it that you need to set the toll_allow variable? What endpoint is making an openzap call?
-MC Hi, Michael,
I have multiple sip phone that are working fine. When I dial a 10 digit number they connect with my sip provider and place the call. The openzap configured phone gets dial tone and can call other extensions, however when I dial a 10 digit number it gives me a busy. In the log I see it appears to be failing on the toll_allow test:
Dialplan: OpenZAP/1:1/7707190068 parsing [default->local_call] continue=false Dialplan: OpenZAP/1:1/7707190068 Regex (FAIL) [local_call] ${toll_allow}() =~ /local/ break=on-false Dialplan: OpenZAP/1:1/7707190068 parsing [default->domestic_call] continue=false Dialplan: OpenZAP/1:1/7707190068 Regex (FAIL) [domestic_call] ${toll_allow}() =~ /domestic/ break=on-false Dialplan: OpenZAP/1:1/7707190068 parsing [default->international.example.com] continue=false Dialplan: OpenZAP/1:1/7707190068 Regex (FAIL) [international.example.com] ${toll_allow}() =~ /international/ break=on-false
This is the area when it should be placing the call, I belive. When placing a call from a sip phone I see:
Dialplan: sofia/internal/1003@192.168.2.51 parsing [default->local_call] continue=false Dialplan: sofia/internal/1003@192.168.2.51 Regex (PASS) [local_call] ${toll_allow}(domestic,international,local) =~ /local/ break=on-false Dialplan: sofia/internal/1003@192.168.2.51 Regex (PASS) [local_call] destination_number(7707190068) =~ /^(\d{10})$/ break=on-false Dialplan: sofia/internal/1003@192.168.2.51 Action set(effective_caller_id_number=${outbound_caller_id_number}) Dialplan: sofia/internal/1003@192.168.2.51 Action set(effective_caller_id_name=${outbound_caller_id_name}) Dialplan: sofia/internal/1003@192.168.2.51 Action set(continue_on_fail=true) Dialplan: sofia/internal/1003@192.168.2.51 Action bridge(sofia/gateway/${default_gateway}/7707190068)
I simply want this extension to be able to dial out. The configuration is 99% default.
Thanks, Jim.
On Sat, Apr 3, 2010 at 12:17 PM, Jim <jim@k4gvo.com <mailto:jim@k4gvo.com>> wrote:
I obviously need to set a <variable name="toll_allow" value="domestic,international,local"/> somewhere but I can't figure out what file to put it in. The examples all show it in the directory/default/xxxx.xml files but those appear to be sip only. In any event creating files in that directory for my extension did nothing to help the problem.
The only places I have the extension mentioned is in the
openzap.conf
file and dialplan/default/00_incoming-1.xml. Adding a <variables ... element to the latter does nothing.
How do I set that variable? Or where?
Thanks, Jim.
_______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org <mailto:FreeSWITCH-users@lists.freeswitch.org> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:
http://lists.freeswitch.org/mailman/options/freeswitch-users
------------------------------------------------------------------------
_______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
_______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
I never gets around to reading that file. It looks like it parses conf/dialplan/default.xml, conf/dialplan/default/*.xml and then stops. It seems to be matching something in the 99999_enum.xml file and never getting any other file. I read up on enum but I don't really know what it's supposed to do. This is the last bit of parsing he does: Dialplan: OpenZAP/1:1/7707190068 parsing [default->international.example.com] continue=false Dialplan: OpenZAP/1:1/7707190068 Regex (FAIL) [international.example.com] ${toll_allow}() =~ /international/ break=on-false Dialplan: OpenZAP/1:1/7707190068 parsing [default->enum] continue=false Dialplan: OpenZAP/1:1/7707190068 Regex (PASS) [enum] ${module_exists(mod_enum)}(true) =~ /true/ break=on-false Dialplan: OpenZAP/1:1/7707190068 Regex (PASS) [enum] destination_number(7707190068) =~ /^(.*)$/ break=on-false Dialplan: OpenZAP/1:1/7707190068 Action transfer(7707190068 enum) Thanks, Jim. Michael Collins wrote:
I looked in mod_openzap.c and I didn't see any references to channel variables. However, you have context and dialplan options. I suggest that you create a dialplan context just for your FXS port(s). Try this. Create conf/dialplan/fxs-ports.xml:
<include> <context name="fxs-ports"> <extension name="outbound"> <condition field="destination_number" expression="^(.*)$"> <action application="set" data="toll_allow=local,domestic,international"/> <action application="transfer" data="$1 XML default"/> </condition> </extension> </context> </include>
Then in your openzap.conf.xml change the context for the analog span(s) with the FXS ports: <param name="context" value="default"/>
Restart FS after making these changes and then give it a shot. You should see the call from the analog phone going into context "fxs-ports" and then get transferred over to the default context where it will act like your SIP phones because we manually set the ${toll_allow} chan var.
-MC
On Sun, Apr 4, 2010 at 4:48 AM, Jim <jim@k4gvo.com <mailto:jim@k4gvo.com>> wrote:
Michael Collins wrote: > Variables set in the directory/default/xxxx.xml files apply to users > who make authenticated calls through FS. Generally those will be SIP > phones. > > Let's back up a step. What problem are you trying to solve, i.e., why > is it that you need to set the toll_allow variable? What endpoint is > making an openzap call? > > -MC Hi, Michael,
I have multiple sip phone that are working fine. When I dial a 10 digit number they connect with my sip provider and place the call. The openzap configured phone gets dial tone and can call other extensions, however when I dial a 10 digit number it gives me a busy. In the log I see it appears to be failing on the toll_allow test:
Dialplan: OpenZAP/1:1/7707190068 parsing [default->local_call] continue=false Dialplan: OpenZAP/1:1/7707190068 Regex (FAIL) [local_call] ${toll_allow}() =~ /local/ break=on-false Dialplan: OpenZAP/1:1/7707190068 parsing [default->domestic_call] continue=false Dialplan: OpenZAP/1:1/7707190068 Regex (FAIL) [domestic_call] ${toll_allow}() =~ /domestic/ break=on-false Dialplan: OpenZAP/1:1/7707190068 parsing [default->international.example.com <http://international.example.com>] continue=false Dialplan: OpenZAP/1:1/7707190068 Regex (FAIL) [international.example.com <http://international.example.com>] ${toll_allow}() =~ /international/ break=on-false
This is the area when it should be placing the call, I belive. When placing a call from a sip phone I see:
Dialplan: sofia/internal/1003@192.168.2.51 <mailto:1003@192.168.2.51> parsing [default->local_call] continue=false Dialplan: sofia/internal/1003@192.168.2.51 <mailto:1003@192.168.2.51> Regex (PASS) [local_call] ${toll_allow}(domestic,international,local) =~ /local/ break=on-false Dialplan: sofia/internal/1003@192.168.2.51 <mailto:1003@192.168.2.51> Regex (PASS) [local_call] destination_number(7707190068) =~ /^(\d{10})$/ break=on-false Dialplan: sofia/internal/1003@192.168.2.51 <mailto:1003@192.168.2.51> Action set(effective_caller_id_number=${outbound_caller_id_number}) Dialplan: sofia/internal/1003@192.168.2.51 <mailto:1003@192.168.2.51> Action set(effective_caller_id_name=${outbound_caller_id_name}) Dialplan: sofia/internal/1003@192.168.2.51 <mailto:1003@192.168.2.51> Action set(continue_on_fail=true) Dialplan: sofia/internal/1003@192.168.2.51 <mailto:1003@192.168.2.51> Action bridge(sofia/gateway/${default_gateway}/7707190068)
I simply want this extension to be able to dial out. The configuration is 99% default.
Thanks, Jim. > > On Sat, Apr 3, 2010 at 12:17 PM, Jim <jim@k4gvo.com <mailto:jim@k4gvo.com> > <mailto:jim@k4gvo.com <mailto:jim@k4gvo.com>>> wrote: > > I obviously need to set a <variable name="toll_allow" > value="domestic,international,local"/> somewhere but I can't > figure out > what file to put it in. The examples all show it in the > directory/default/xxxx.xml files but those appear to be sip only. In > any event creating files in that directory for my extension did > nothing > to help the problem. > > The only places I have the extension mentioned is in the openzap.conf > file and dialplan/default/00_incoming-1.xml. Adding a <variables ... > element to the latter does nothing. > > How do I set that variable? Or where? > > Thanks, > Jim. > > _______________________________________________ > FreeSWITCH-users mailing list > FreeSWITCH-users@lists.freeswitch.org <mailto:FreeSWITCH-users@lists.freeswitch.org> > <mailto:FreeSWITCH-users@lists.freeswitch.org <mailto:FreeSWITCH-users@lists.freeswitch.org>> > http://lists.freeswitch.org/mailman/listinfo/freeswitch-users > UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users > http://www.freeswitch.org > > > ------------------------------------------------------------------------ > > _______________________________________________ > FreeSWITCH-users mailing list > FreeSWITCH-users@lists.freeswitch.org <mailto:FreeSWITCH-users@lists.freeswitch.org> > http://lists.freeswitch.org/mailman/listinfo/freeswitch-users > UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users > http://www.freeswitch.org >
_______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org <mailto:FreeSWITCH-users@lists.freeswitch.org> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
------------------------------------------------------------------------
_______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
participants (2)
-
Jim
-
Michael Collins