[Asterisk-bsd] hangup detection

Jeff LaCoursiere jeff at jeff.net
Fri Sep 30 15:05:02 CDT 2005


Hi,

Yes, I meant to do that - I did leave out the default context that
includes both of these below.  Sorry for the confusion :)  Still learning
new things daily!  An amazing system!

I will try loop start and see how it goes.  Thanks for the tips!

j

On Fri, 30 Sep 2005, Brian Buhrow wrote:

> 	Hello Jeff.  It looks like you define two contexts here, main and
> timeout.  Is that your real intent?
> 	In terms of hangup detection, I'd try using loopstart.  That's the
> most common, in the US, I think for standard analog POTS lines.
>
> -Brian
> On Sep 30, 10:29am, Jeff LaCoursiere wrote:
> } Subject: Re: [Asterisk-bsd] hangup detection
> }
> } Hello all,
> }
> } Just for posterity I thought I would post what I ended up with... we
> } decided that rather than hangup the line, we will send the call to the
> } operator after three invalids or one timeout.  I discovered how amazingly
> } anal asterisk is about spacing in numeric expressions!  So here it is:
> }
> } ;
> } ; Southland's main welcome menu
> } ;
> } [main]
> } exten => s,1,Answer
> } exten => s,2,DigitTimeout,3
> } exten => s,3,ResponseTimeout,3
> } exten => s,4,setvar(RETRIES=0)
> } exten => s,5,BackGround(sgvi-welcome)
> }
> } [timeout]
> } exten => t,1,Playback(sgvi-tooper)
> } exten => t,2,Macro(stdexten,220,SIP/dot) ; timeout goes to operator
> } exten => i,1,setvar(RETRIES=$[${RETRIES} + 1])
> } exten => i,2,gotoif($[${RETRIES} > 2]?20)
> } exten => i,3,Playback(invalid)
> } exten => i,4,Goto(s,5)
> } exten => i,20,Playback(sgvi-tooper)
> } exten => i,21,Macro(stdexten,220,SIP/dot) ; 3 tries goes to operator
> }
> } I still think I have some kind of problem detecting hangups on the FXO
> } ports.  Could this be my choice of kewlstart signalling?  Should I play
> } with loop/ground start?  I expect what may happen now is that we will get
> } blank voicemail messages in the operator mailbox :)
> }
> } Thanks,
> }
> } Jeff LaCoursiere
> } Southland Gaming Virgin Islands
> } jeff at sgvi.net
> } jeff at jeff.net
> }
> } On Thu, 29 Sep 2005, Brian Buhrow wrote:
> }
> } > 	The application reference at www.voip-info.org for Asterisk is quite
> } > complete.  The dial plan language is fairly rich and flexible, except for
> } > the feeling that I'm programming in Applesoft BASIC with line numbers
> } > again.
> } > -Brian
> } >
> } > P.S.  In the sample I sent you, it might be avvisable to set the RETRIES
> } > variable in the initial extension, just so  you don't get any undefined
> } > values when you try to do the first addition operation in the timeout
> } > extension.
> } > -Brian
> } > On Sep 29,  6:23pm, Jeff LaCoursiere wrote:
> } > } Subject: Re: [Asterisk-bsd] hangup detection
> } > }
> } > } Thanks!  That is beautiful :)  Is there a good resource for the
> } > } programming constructs available?  Is the O'Reilly book any good?
> } > }
> } > } Cheers,
> } > }
> } > } j
> } > }
> } > } On Thu, 29 Sep 2005, Brian Buhrow wrote:
> } > }
> } > } > 	Hello Jef.  I think your work around is a good idea.  I'd try
> } > } > something like:
> } > } >
> } > } > exten = t,1,setvar(RETRIES = ${RETRIES} +1)
> } > } > exten = t,2,gotoif(${RETRIES} > 3?20)
> } > } > exten = t,3,playback(invalid)
> } > } > exten = t,4,goto(s,1) ;Or where ever you want people to wait.
> } > } > exten = t,20,hangup ;Should only get here if sent by the gotoif above.
> } > } >
> } > } >
> } > } > Hope that helps.
> } > } >
> } > } > -Brian
> } > } > On Sep 29,  3:34pm, Jeff LaCoursiere wrote:
> } > } > } Subject: [Asterisk-bsd] hangup detection
> } > } > }
> } > } > } Hello,
> } > } > }
> } > } > } Am running 1.0.8-BRIstuffed-0.2.0-RC8h on 5.4-RELEASE with a 4 port FXO
> } > } > } card from Digium (and about twelve Procomm 300, 301, 501, and 600 phones).
> } > } > } We have been playing around with it for about a month and finally put it
> } > } > } into production yesterday.  Twice in the past twenty four hours the first
> } > } > } line has become "stuck" in our main menu:
> } > } > }
> } > } > }   == CDR updated on Zap/1-1
> } > } > }     -- Executing Goto("Zap/1-1", "#|1") in new stack
> } > } > }     -- Goto (default,#,1)
> } > } > }     -- Sent into invalid extension '#' in context 'default' on Zap/1-1
> } > } > }     -- Executing Playback("Zap/1-1", "invalid") in new stack
> } > } > }     -- Playing 'invalid' (language 'en')
> } > } > }     -- Timeout on Zap/1-1
> } > } > }   == CDR updated on Zap/1-1
> } > } > }     -- Executing Goto("Zap/1-1", "#|1") in new stack
> } > } > }     -- Goto (default,#,1)
> } > } > }     -- Sent into invalid extension '#' in context 'default' on Zap/1-1
> } > } > }     -- Executing Playback("Zap/1-1", "invalid") in new stack
> } > } > }     -- Playing 'invalid' (language 'en')
> } > } > }     -- Timeout on Zap/1-1
> } > } > }   == CDR updated on Zap/1-1
> } > } > }     -- Executing Goto("Zap/1-1", "#|1") in new stack
> } > } > }     -- Goto (default,#,1)
> } > } > }     -- Sent into invalid extension '#' in context 'default' on Zap/1-1
> } > } > }     -- Executing Playback("Zap/1-1", "invalid") in new stack
> } > } > }     -- Playing 'invalid' (language 'en')
> } > } > }     -- Timeout on Zap/1-1
> } > } > }
> } > } > } This continues forever until I physically unplug the phone line from the
> } > } > } port, then plug it back in.  In the meantime the line rings busy from the
> } > } > } outside.
> } > } > }
> } > } > } I think I can work around whatever causes this by making the menu timeout
> } > } > } and hangup, perhaps after some number of unsuccessful extensions?  Can
> } > } > } someone help me with a dialplan example that would accomplish this?
> } > } > }
> } > } > } TIA!
> } > } > }
> } > } > } Jeff LaCoursiere
> } > } > } Southland Gaming Virgin Islands
> } > } > } jeff at sgvi.net
> } > } > } jeff at jeff.net
> } > } > }
> } > } > } _______________________________________________
> } > } > } Asterisk-BSD mailing list
> } > } > } Asterisk-BSD at lists.digium.com
> } > } > } http://lists.digium.com/mailman/listinfo/asterisk-bsd
> } > } > >-- End of excerpt from Jeff LaCoursiere
> } > } >
> } > } >
> } > } > _______________________________________________
> } > } > Asterisk-BSD mailing list
> } > } > Asterisk-BSD at lists.digium.com
> } > } > http://lists.digium.com/mailman/listinfo/asterisk-bsd
> } > } >
> } > } _______________________________________________
> } > } Asterisk-BSD mailing list
> } > } Asterisk-BSD at lists.digium.com
> } > } http://lists.digium.com/mailman/listinfo/asterisk-bsd
> } > >-- End of excerpt from Jeff LaCoursiere
> } >
> } >
> } > _______________________________________________
> } > Asterisk-BSD mailing list
> } > Asterisk-BSD at lists.digium.com
> } > http://lists.digium.com/mailman/listinfo/asterisk-bsd
> } >
> } _______________________________________________
> } Asterisk-BSD mailing list
> } Asterisk-BSD at lists.digium.com
> } http://lists.digium.com/mailman/listinfo/asterisk-bsd
> >-- End of excerpt from Jeff LaCoursiere
>
>
> _______________________________________________
> Asterisk-BSD mailing list
> Asterisk-BSD at lists.digium.com
> http://lists.digium.com/mailman/listinfo/asterisk-bsd
>


More information about the Asterisk-BSD mailing list