-----Original Message----- From: asterisk-users-boun...@lists.digium.com [mailto:asterisk-users-boun...@lists.digium.com] On Behalf Of Gilles Sent: Friday, March 18, 2011 10:45 AM To: asterisk-users@lists.digium.com Subject: Re: [asterisk-users] [1.4] Failed callfile doesn't jumpto"failed"extension
On Fri, 18 Mar 2011 10:14:37 -0500, "Danny Nicholas" <da...@debsinc.com> wrote: >exten => start,n,Playback(manolo_camp-morning_coffee) >;exten => start,n,Hangup() >exten => start,n,Goto(${EXTEN}-${REASON}) > >;not run >;exten => failed,1,NoOp(Call ended with ${REASON}) > >;not run >;exten => s,1,NoOp(Call ended with ${REASON}) > >;empty >;exten => h,1,NoOp(Call ended with ${REASON}) > >;not run >exten => start-NOANSWER,1,NoOp(Call ended with ${REASON}) >=============== > >Is this what you had in mind? > >Thank you. > >That's the ticket. Unfortunately, it can only jump to "h", and ${REASON} is empty. Based on... www.voip-info.org/wiki/view/Asterisk+dial+plan+-+working+example ... I also tried this, but Asterisk doesn't jump to any of those extensions: ========= extensions.conf ... exten => start,n,Playback(manolo_camp-morning_coffee) ;exten => start,n,Hangup() ;exten => start,n,Goto(${EXTEN}-${REASON}) exten => start,n,Goto(s-${DIALSTATUS},1) exten => s-ANSWER,1,Hangup exten => s-CANCEL,1,Hangup exten => s-NOANSWER,1,Hangup exten => s-BUSY,1,Busy ;Only works with SIP calls exten => s-CHANUNAVAIL,1,Verbose(Not available) exten => s-CONGESTION,1,Congestion exten => _s-.,1,Congestion exten => s-,1,Congestion ========= CLI -- Executing [start@callback:5] Playback("DAHDI/1-1", "manolo_camp-morning_coffee") in new stack -- <DAHDI/1-1> Playing 'manolo_camp-morning_coffee.ulaw' (language 'fr') == Spawn extension (callback, start, 5) exited non-zero on 'DAHDI/1-1' -- Hungup 'DAHDI/1-1' [Mar 18 16:41:35] NOTICE[1200]: pbx_spool.c:349 attempt_thread: Call completed to Dahdi/1/5551234 ========= Is there no way to know how a call ended? Thank you. I believe you will achieve the desired result by replacing ${REASON} with ${HANGUP_CAUSE}. -- _____________________________________________________________________ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users