FreeSWITCH is driven by a state machine and execute and hangup are opposing
states so once you change to hangup state that is the end of executing
extensions.

asterisk has 4 special extensions s h i and t  we don't support any of them
because our dialplan concept and paradigm is completely different.



There is a feature in FS called api_hangup_hook which is a variable you can
set to a desired script to execute when the call hangs up.
you should be able to find it on the wiki


On Thu, Sep 10, 2009 at 11:40 PM, Ahmed Munir <[email protected]>wrote:

> Thanks for reply, well actually I'm doing billing after call hangup. If h
> extension is interupts I'm sending to it to addcdr context which interupts
> perl script for billing purpose. As I'm listing down below asterisk
> configuration;
>
> h =>
>     {
>         NOOP("Call Completed with Carrier ${CARRIER}");
>         goto add_cdr|h|1;
>     };
>
> context add_cdr
> {
>     _X. =>
>     {
>         Hangup();
>     };
>     h =>
>     {
>         Set(CALL_END_TIME=${EPOCH});
>         //&print_variables();
>         NOOP("Call Ended: Card:${CARDNUM} Destination:${CALLEDNUM}
> Caller-ID:${CALLERID(num)}");
>         if (${DIALEXECUTED}=YES)
>         {
>             NOOP("Dial-Status:${DIALSTATUS}");
>         }else
>         {
>             NOOP("Dial was not Executed");
>         };
>         DeadAGI(/vopium/agi/billing.pl);
>         NOOP();
>     };
>
> };
>
> Kindly advice me how I pass/translate h extension in FS in this situation
> i.e. <action application="api_hangup_hook" data="addcdr 1"/> or there is
> other way around???
> ------------------------------
> *From: *Michael Collins <[email protected]>
> *Reply-To: *<[email protected]>
> *Date: *Thu, 10 Sep 2009 00:55:02 -0700
> *To: *<[email protected]>
> *Subject: *Re: [Freeswitch-users] Implementing h extension in FS
>
>
>
> On Wed, Sep 9, 2009 at 10:16 PM, Ahmed Munir <[email protected]>
> wrote:
>
> HI,
>
> I'm newbie in FS, I want to know how to implement h extension of asterisk
> to FS. As I listed down below;
>
> h =>
>     {
>         NOOP("Call Completed with Carrier ${CARRIER}");
>         goto add_cdr|h|1;
>     };
>
> My other question is, which application/function/class is use in mod_perl
> to check the channel status? i.e. busy, answer,hangup,ringing,etc.
>
>
> Kindly advice me soon.
>
> --
> Regards,
>
> Ahmed Munir
>
>
> It depends on what you are trying to accomplish, but the closest thing
> you'll find in FS to the 'h' extension is the channel variable
> api_hangup_hook which lets you launch an API at the end of the call. It
> sounds like you are working on CDR processing. Please tell us more about
> your application and we'll do our best to offer advice.
> -MC
>
> --
> Regards,
>
> Ahmed Munir
>
>
>
> _______________________________________________
> FreeSWITCH-users mailing list
> [email protected]
> 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:[email protected] <msn%[email protected]>
GTALK/JABBER/PAYPAL:[email protected]<paypal%[email protected]>
IRC: irc.freenode.net #freeswitch

FreeSWITCH Developer Conference
sip:[email protected] <sip%[email protected]>
iax:[email protected]/888
googletalk:[email protected]<googletalk%3aconf%[email protected]>
pstn:213-799-1400
_______________________________________________
FreeSWITCH-users mailing list
[email protected]
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org

Reply via email to