Avoiding voice mail

hi new asterisk

how to avoid voice mail when doing parallel calling

my extension is like this

exten => X_.,1,Dial(sip/0091900569002@x.x.x.x&sip/0091900569003@x.x.x.x,20,gM(t))

[macro-t]
exten =>s,1,background(followme)
exten =>s,2,waitexten()

exten => #,1,NoOp()

exten => i,1,hangup()
exten => t,1,hangup()

first number immediate voice mail the call not at all coming to second number

can any one help me out

Assuming it takes finite time to call the numbers, Asterisk will start calling both. The first one to respond connected wins. As you have no voicemail in your dialplan, I can only assume that the remote system is using voicemail. In that case there is no way that Asterisk can distinguish between a voicemail answer and human answer before the call connects. You have to treat this like calling a line with an answering machine.

What you might be able to do is to interpose a local channel and have it apply an answering machine test before, itself answering, although I don’t guarantee that this can be done. If you do this, the call will not complete until the answering machine test has concluded that it has a human, and you will miss any initial reply.