[asterisk-dev] Dial() Staggering

Olle E Johansson olle at voop.com
Tue Jul 10 14:02:35 CDT 2007


10 jul 2007 kl. 20.43 skrev Michiel van Baak:

> On 11:06, Tue 10 Jul 07, Nicholas Blasgen wrote:
>> I'd like to modify the Dial() command to impliment a new flag.  I  
>> would like
>> a suggestion on how best to do this.  I'm a decent programmer but  
>> at the
>> same time I hate messing with source and dealing with recompiling  
>> the entire
>> package.  I'd prefer to do this as a module if possible.
>> What I'm doing:
>>
>> Dial() already supports dialing multiple lines at once and  
>> connecting the
>> first answered line to the user.  I want that exact same  
>> functionality but
>> would like to be able to space out (or stagger) the dialing of  
>> each line.
>> An example might be I want to dial 5 phone numbers with a wait  
>> time of 30
>> seconds.  But I want it to try the first number for 2 seconds before
>> starting on the next number.  Then at that point it would be  
>> ringing 2
>> numbers (with 2 seconds between when each was dialed).
>>
>> The purpose of this modification would be to give the main number  
>> more time
>> to answer before bothering the other workers with a call that  
>> there are
>> better people to handle.  I'm not trying to dial 1 person, wait 20  
>> seconds,
>> then dial another person.  The user would need to hang on the  
>> phone too long
>> for that.  And at the same time I don't want it calling everyone  
>> at the
>> company at the same moment.
>
> You can do this in the dialplan:
> exten => bla,1,Dial(SIP/1,2)
> exten => bla,n,Dial(SIP/1&SIP/2,2)
> exten => bla,n,Dial(SIP/1&SIP/2&SIP/3,2)
> ...

...or by using the local channel and starting the second extension after
2 seconds without cancelling the first call. As already stated, it's
doable today.

/O :-)



More information about the asterisk-dev mailing list