Olá,<br><br>Poderia ser feito utilizando callfiles.<br><br>Ex:<br><br>exten => _762XX,1,system(echo "Channel: SIP/${EXTEN:1}" > /var/spool/asterisk/tmp/redial/${CALLERID(num)}.call)<br>exten => _762XX,n,system(echo "Context: default" >> /var/spool/asterisk/tmp/redial/${CALLERID(num)}.call)<br>
exten => _762XX,n,system(echo "Extension: ${CALLERID(num)}" >> /var/spool/asterisk/tmp/redial/${CALLERID(num)}.call)<br>exten => _762XX,n,system(echo "Callerid: ${EXTEN:1}" >> /var/spool/asterisk/tmp/redial/${CALLERID(num)}.call)<br>
exten => _762XX,n,system(echo "MaxRetries: 30" >> /var/spool/asterisk/tmp/redial/${CALLERID(num)}.call)<br>exten => _762XX,n,system(echo "RetryTime: 30" >> /var/spool/asterisk/tmp/redial/${CALLERID(num)}.call)<br>
exten => _762XX,n,system(echo "WaitTime: 10" >> /var/spool/asterisk/tmp/redial/${CALLERID(num)}.call)<br>exten => _762XX,n,Playback(beep)<br>exten => _762XX,n,TrySystem(mv /var/spool/asterisk/tmp/redial/${CALLERID(num)}.call /var/spool/asterisk/outgoing)<br>
exten => _762XX,n,Hangup<br><br>exten => *911,1,system(rm -rf /var/spool/asterisk/outgoing/${CALLERID(num)}.call*)<br>exten => *911,n,Playback(beep)<br>exten => *911,n,Hangup<br><br>Funciona assim:<br><br>o ramal 6265 liga pro ramal 6267 e o mesmo está ocupado, entao 6265 disca 76267 e aguarda, o asterisk vai tentar ligar pra 6267 por 30 vezes até conseguir estabelecer uma chamada.<br>
<br>Caso 6265 desista de fazer a chamada ele disca *911.<br><br>[]´s<br><br>Victor Yure<br><br><br><br>