Curious to know if anyone's created something similar to the following, if so and you'd care to share an AGI or dialplan, much appreciated. I will be eventually write a script to answer the nTH call. (if I can't find it (why reinvent wheels). Looking to do some testing sending anywhere between 50-200 calls to a machine. I'd like a Snom/Polycom/whatever to pick up after the nTh call where nTh is whatever I set it to. exten => _X.,1,{at_N_amount_of_rings} exten => _X.,2,Dial(SIP/${EXTEN}@somwhere,45) So as a script it would be something like: if call != 25th ; then go elsewhere ; fi (make sense?) Where every 25th call or so would go through, the others would go wherever, not important. -- =+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+ J. Oquendo SGFA, SGFE, C|EH, CNDA, CHFI, OSCP "It takes 20 years to build a reputation and five minutes to ruin it. If you think about that, you'll do things differently." - Warren Buffett 227C 5D35 7DCB 0893 95AA 4771 1DCE 1FD1 5CCD 6B5E http://pgp.mit.edu:11371/pks/lookup?op=get&search=0x5CCD6B5E
On Tue, Jul 7, 2009 at 9:05 AM, J. Oquendo<sil at infiltrated.net> wrote:> > Curious to know if anyone's created something similar to the following, > if so and you'd care to share an AGI or dialplan, much appreciated. > > I will be eventually write a script to answer the nTH call. (if I can't > find it (why reinvent wheels). > > Looking to do some testing sending anywhere between 50-200 calls to a > machine. I'd like a Snom/Polycom/whatever to pick up after the nTh call > where nTh is whatever I set it to. > > exten => _X.,1,{at_N_amount_of_rings} > exten => _X.,2,Dial(SIP/${EXTEN}@somwhere,45) > > So as a script it would be something like: if call != 25th ; then go > elsewhere ; fi (make sense?) Where every 25th call or so would go > through, the others would go wherever, not important. > > -- > > =+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+ > J. Oquendo > SGFA, SGFE, C|EH, CNDA, CHFI, OSCP > > "It takes 20 years to build a reputation and five minutes to > ruin it. If you think about that, you'll do things > differently." - Warren Buffett > > 227C 5D35 7DCB 0893 95AA ?4771 1DCE 1FD1 5CCD 6B5E > http://pgp.mit.edu:11371/pks/lookup?op=get&search=0x5CCD6B5E > >To be clear you have defined N two different ways. 1. Amount of rings 2. A certain specific in a string of calls. Which is it? -- Thanks, Steve Totaro +18887771888 (Toll Free) +12409381212 (Cell) +12024369784 (Skype)
Here is a crack at it [globals] CALLCOUNT=0 MAXCOUNT=25 [default] - exten => s,1,answer() - exten => s,n,Set(GLOBAL(CALLCOUNT)=${CALLCOUNT}+1) - exten => s,n,Gotoif($["${CALLCOUNT}" = "${MAXCOUNT}"]?callout) - exten => s,n,Dial(SIP/100,20,m) - exten => s,n,Hangup - exten => s,n(callout),Set(GLOBAL(CALLCOUNT)=0) - exten => s,n,Dial(SIP/200,20,m) - exten => s,n,Hangup -----Original Message----- From: asterisk-users-bounces at lists.digium.com [mailto:asterisk-users-bounces at lists.digium.com] On Behalf Of J. Oquendo Sent: Tuesday, July 07, 2009 8:06 AM To: Asterisk Users Mailing List - Non-Commercial Discussion Subject: [asterisk-users] Answering the nTh call ... Curious to know if anyone's created something similar to the following, if so and you'd care to share an AGI or dialplan, much appreciated. I will be eventually write a script to answer the nTH call. (if I can't find it (why reinvent wheels). Looking to do some testing sending anywhere between 50-200 calls to a machine. I'd like a Snom/Polycom/whatever to pick up after the nTh call where nTh is whatever I set it to. exten => _X.,1,{at_N_amount_of_rings} exten => _X.,2,Dial(SIP/${EXTEN}@somwhere,45) So as a script it would be something like: if call != 25th ; then go elsewhere ; fi (make sense?) Where every 25th call or so would go through, the others would go wherever, not important. -- =+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+ J. Oquendo SGFA, SGFE, C|EH, CNDA, CHFI, OSCP "It takes 20 years to build a reputation and five minutes to ruin it. If you think about that, you'll do things differently." - Warren Buffett 227C 5D35 7DCB 0893 95AA 4771 1DCE 1FD1 5CCD 6B5E http://pgp.mit.edu:11371/pks/lookup?op=get&search=0x5CCD6B5E _______________________________________________ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
You can take a look at -> app_contest allows you to easily run a 'radio station contest line' where you can specify a certain caller number and they will be connected, but all other callers will be rejected with some message http://www.freeswitch.org/asterisk_stuff/app_contest.c it was made for 1.2 but you could probably port it to 1.4 Jimmy> -----Original Message----- > From: sil at infiltrated.net > Sent: Tue, 07 Jul 2009 09:05:48 -0400 > To: asterisk-users at lists.digium.com > Subject: [asterisk-users] Answering the nTh call ... > > > Curious to know if anyone's created something similar to the following, > if so and you'd care to share an AGI or dialplan, much appreciated. > > I will be eventually write a script to answer the nTH call. (if I can't > find it (why reinvent wheels). > > Looking to do some testing sending anywhere between 50-200 calls to a > machine. I'd like a Snom/Polycom/whatever to pick up after the nTh call > where nTh is whatever I set it to. > > exten => _X.,1,{at_N_amount_of_rings} > exten => _X.,2,Dial(SIP/${EXTEN}@somwhere,45) > > So as a script it would be something like: if call != 25th ; then go > elsewhere ; fi (make sense?) Where every 25th call or so would go > through, the others would go wherever, not important. > > -- > > =+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+ > J. Oquendo > SGFA, SGFE, C|EH, CNDA, CHFI, OSCP > > "It takes 20 years to build a reputation and five minutes to > ruin it. If you think about that, you'll do things > differently." - Warren Buffett > > 227C 5D35 7DCB 0893 95AA 4771 1DCE 1FD1 5CCD 6B5E > http://pgp.mit.edu:11371/pks/lookup?op=get&search=0x5CCD6B5E > > > _______________________________________________ > -- Bandwidth and Colocation Provided by http://www.api-digital.com -- > > asterisk-users mailing list > To UNSUBSCRIBE or update options visit: > http://lists.digium.com/mailman/listinfo/asterisk-users