[asterisk-users] How to get BEEP BEEP BEEP when underline sends 486 Busy Here.

John Kiniston johnkiniston at gmail.com
Fri Dec 12 22:02:16 CST 2014


You don't actually do it in your Dial command, You do it after your dial
command.

Your Dial will return a DIALSTATUS variable, Check it and then process your
busy.

Here's some sample code I just banged out real quick for you. Untested but
it should do the job.

[sub-dialout]
exten => s,1,NoOP()
exten
=>s,n,,Set(ARRAY(Trunk,Number,RingTo,DialOptn)=${ARG1},${ARG2},${ARG3},${ARG4})
exten => s,n(Dial),Dial(${Trunk}/${Number},${RingTo},${DialOptn})
exten => s,n,NoOp(DIALSTATUS is ${DIALSTATUS} HANGUPCAUSE is ${HANGUPCAUSE})
exten => s,n,Goto(${DIALSTATUS})
exten => s,n(NOANSWER),NoOP()
exten => s,n,Return${DIALSTATUS})
exten => s,n(BUSY),NoOP()
exten => s,n,Playtones(busy)
exten => s,n,Busy(8)
exten => s,n,Return(${DIALSTATUS})
exten => s,n(CHANUNAVAIL),NoOP()
exten => s,n,Playtones(congestion)
exten => s,n,Congestion(8)
exten => s,n,Return(${DIALSTATUS})
exten => s,n(CONGESTION),NoOP()
exten => s,n,Playtones(congestion)
exten => s,n,Congestion(8)
exten => s,n,Return(${DIALSTATUS})



On Fri, Dec 12, 2014 at 7:04 PM, symack <symack at gmail.com> wrote:
>
> Hello There,
>
> I would like to play a busy tone (ie BEEP BEEP BEEP) when the underline
> carrier sends back 486 Busy Here. Looking at Dial parameters (
> http://www.voip-info.org/wiki/view/Asterisk+cmd+Dial), it mentioned
> something about the r
> parameter as not being very professional or something like that...
> Then there was:
>
> U(x): Executes, via gosub, routine x on the called channel. This is
> similar to
> M above, but a gosub rather than a macro. The subroutine can set
> ${GOSUB_RESULT}__ to the following:
>
> ABORT: Hang up both legs
> CONGESTION: Signal congestion to the caller
> BUSY: Signal busy to the caller
> CONTINUE: Hangup the called party but continue execution at the next
> priority in the dialplan for the caller
> GOTO: Transfer the execution to context^exten^pri
>
> I could not grasp how to include this in my Dial command. Your help is
> greatly appreciated.
>
> Nick from Toronto.
>
> --
> _____________________________________________________________________
> -- Bandwidth and Colocation Provided by http://www.api-digital.com --
> New to Asterisk? Join us for a live introductory webinar every Thurs:
>                http://www.asterisk.org/hello
>
> asterisk-users mailing list
> To UNSUBSCRIBE or update options visit:
>    http://lists.digium.com/mailman/listinfo/asterisk-users
>


-- 
A human being should be able to change a diaper, plan an invasion, butcher
a hog, conn a ship, design a building, write a sonnet, balance accounts,
build a wall, set a bone, comfort the dying, take orders, give orders,
cooperate, act alone, solve equations, analyze a new problem, pitch manure,
program a computer, cook a tasty meal, fight efficiently, die gallantly.
Specialization is for insects.
---Heinlein
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-users/attachments/20141212/4fd63a00/attachment.html>


More information about the asterisk-users mailing list