[Freeswitch-users] DIalplan logic

Anthony Minessale anthony.minessale at gmail.com
Mon Nov 9 16:29:24 PST 2009


You set both hangup_after_bridge and continue_on_fail after you already
called bridge.
Try setting it *before*

Seems to be a running theme here that things will be parsed in a linear
fashion that you may want to take note of.


On Mon, Nov 9, 2009 at 6:18 PM, Dave Stevenson <stevendt at primrosebank.net>wrote:

>  Well,
>
> I thought it was fixed - it is more or less working, with one more
> stumbling block.
>
> I have just posted a dump to the pastebin - from Dave (stevendt)
>
> The voice mail works - but too well.
>
> If the call is answered by a someone at this end - everything is fine until
> the user hangs up, then the remote party gets the voicemail messages.#
>
> Is there something else wrong with the dialplan logic below ?
>
> regards
> Dave
>
>
>
> ----- Original Message -----
> *From:* Dave Stevenson <stevendt at primrosebank.net>
> *To:* freeswitch-users at lists.freeswitch.org
> *Sent:* Monday, November 09, 2009 11:52 PM
> *Subject:* Re: [Freeswitch-users] DIalplan logic
>
> Michael,
>
> thanks a lot - it's fixed......
>
>
> you spotted exactly what the problem was !
>
>       <condition field="destination_number" expression="^(100)$">
>
> <action application="voicemail" data="default ${domain_name}
> ${dialed_extension}"/>
>
>
> regards
> Dave
>
>
>
>
> ----- Original Message -----
> *From:* Michael Collins <msc at freeswitch.org>
> *To:* freeswitch-users at lists.freeswitch.org
> *Sent:* Monday, November 09, 2009 11:26 PM
> *Subject:* Re: [Freeswitch-users] DIalplan logic
>
> See comment inline
>
> On Mon, Nov 9, 2009 at 2:56 PM, Dave Stevenson <stevendt at primrosebank.net>wrote:
>
>>  Hi Guys,
>>
>> OK, with the RegEx help that you gave me, I have separated out the
>> processing of extension 100 from 101 to 399 as I wanted.
>>
>> I have created a group (100) which contains a number of phones - 101 to
>> 105 at the moment.
>>
>> When the PSTN line rings, I want all the extensions in the group to ring -
>> that's the easy bit (I think - it's a copy of extension 2000 code)
>>
>>    <extension name="group_dial_primrose">
>>       <condition field="destination_number" expression="^100$">
>>             <action application="bridge" data="${group_call(
>> primrose@${domain_name})}"/ <primrose@$%7Bdomain_name%7D%29%7D%22/>>
>>      </condition>
>>     </extension>
>> That's fine and the nominated phones all ring.
>>
>> I'm struggling to get it to do what I want when some doesn't pick up
>> though.
>>
>> All extensions ring as required, but their own dialplan entries (copies of
>> the 1001 to 1005 code in the default dialplan) don't answer the call. That's
>> fine, as you would not want every extension's voice mail to kick in.
>>
>> What I want to happen is for extension 100's voice mail to kick in after a
>> time delay.
>>
>> So, get the dialed exetension number so that I can point at the right
>> mailbox
>>
>> <action application="set" data="dialed_extension=$1"/>
>> set the timeout for the call
>>
>>  <action application="set" data="call_timeout=20"/>
>> Added these lines - but don't know why - they are in the default extension
>> code ?????
>>
>>  <action application="set" data="hangup_after_bridge=true"/>
>>  <action application="set" data="continue_on_fail=true"/>
>>  <action application="answer"/>
>> then go to voice mail on 100
>>
>>  <action application="sleep" data="1000"/>
>>  <action application="voicemail" data="default
>> ${domain_name}{dialed_extension}"/>
>>
>> giving
>>
>>  <extension name="group_dial_primrose">
>>
>
> The following line needs to have 100 in parens like this: "^(100)$" because
> that's how you get $1 to be populated.
>
>>        <condition field="destination_number" expression="^100$">
>>  <action application="set" data="dialed_extension=$1"/>
>>  <action application="set" data="call_timeout=20"/>
>>  <action application="bridge" data="${group_call(
>> primrose@${domain_name})}"/ <primrose@$%7Bdomain_name%7D%29%7D%22/>>
>>  <action application="set" data="hangup_after_bridge=true"/>
>>  <action application="set" data="continue_on_fail=true"/>
>>  <action application="answer"/>
>>  <action application="sleep" data="1000"/>
>>
>
> I think this might be a typo? Shouldn't this next line be ... data="default
> ${domain_name} ${dialed_extension}"
>
>>   <action application="voicemail" data="default
>> ${domain_name}{dialed_extension}"/>
>>
>>       </condition>
>>     </extension>
>> The voicemail kicks in, and prompts are correct (although the extension
>> name is not spoken) but the wav file is saved in the 1001 directory not 100
>> and neither extension 100 or 1001 think that have any voice mail messages.
>>
>> Can someone help please ?
>>
>> Where am i going wrong ?
>>
>>
>
> Make those changes, reloadxml, and then try again. Be sure to capture a
> debug log if it doesn't work and put that log in pastebin.freeswitch.org.
> -MC
>
>  ------------------------------
>
> _______________________________________________
> FreeSWITCH-users mailing list
> FreeSWITCH-users at 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 at 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 at lists.freeswitch.org
> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
> 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 <MSN%3Aanthony_minessale at hotmail.com>
GTALK/JABBER/PAYPAL:anthony.minessale at gmail.com<PAYPAL%3Aanthony.minessale at gmail.com>
IRC: irc.freenode.net #freeswitch

FreeSWITCH Developer Conference
sip:888 at conference.freeswitch.org <sip%3A888 at conference.freeswitch.org>
iax:guest at conference.freeswitch.org/888
googletalk:conf+888 at conference.freeswitch.org<googletalk%3Aconf%2B888 at conference.freeswitch.org>
pstn:213-799-1400
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20091109/5a7a0b28/attachment-0002.html 


More information about the FreeSWITCH-users mailing list