[asterisk-users] Macro help needed!!!!

carl Lougher c_lougher at yahoo.co.uk
Thu Jul 20 03:53:21 MST 2006


Hi,
Need to get the following working:

1. User calls ext 750.
2. If no answer or busy go elsewhere.
3. If answered and press 1 accept call.
4. If answered and not pressed 1 or timed out then
send call to be redirected to the busy or no answer
option.

The issue is that the call gets accepted if any number
is pressed or a timeout. How do i throw the call back
out of the macro???

asterisk ver 1-0-9

[sip-clients]
exten => 750,1,Dial(SIP/225|60|gM(mobile))
exten => 750,2,GotoIf($[${DIALSTATUS} = BUSY]?7:3)
exten => 750,3,GotoIf($[${DIALSTATUS} = NOANSWER]?7)
exten => 750,4,Hangup()
exten => 750,7,Dial(SIP/226,15,t)

[macro-mobile]
exten => s,1,DigitTimeout(4)
exten => s,2,ResponseTimeout(5)
exten => s,3,Read(ACCEPT|press one now to accept|1) ;
exten => s,4,GotoIf($[${ACCEPT} = 1]?5:6)
exten => s,5,SetVar(MACRO_RESULT=CONTINUE)
exten => s,6,Hangup()






		
___________________________________________________________ 
All New Yahoo! Mail – Tired of Vi at gr@! come-ons? Let our SpamGuard protect you. http://uk.docs.yahoo.com/nowyoucan.html



More information about the asterisk-users mailing list