Diable beep tone base on trunk

Dear all,

I am successfully running a freepbx server from long time. My system beep on every dial out call for both parties. Now I wanted to disable that beep tone on a specific trunk. So I thought it would be an easy task with [macro-dialout-trunk-predial-hook]. What I did was, entering the below macro content to select a specific trunk.

[macro-dialout-trunk-predial-hook]
exten => s,1,NoOp(Trunk ${OUT_${DIAL_TRUNK}} selected)
exten => s,n,Gotoif($["${OUT_${DIAL_TRUNK}}" != “SIP/Teliax”]?skip)
exten => s,n,NoOp(Setting DIAL_TRUNK_OPTIONS to Ww)
exten => s,n,Set(DIAL_TRUNK_OPTIONS=“Ww”)
exten => s,n(skip),MacroExit()

I thought This macro is the last execution before dial the trunk. But i was wrong. After this system again go to [macro-dialout-trunk] and apply beep tone again.

-- Executing [[email protected]:14] Set("SIP/4310-000031f1", "custom=SIP/Teliax-backup") in new stack
-- Executing [[email protected]:15] ExecIf("SIP/4310-000031f1", "0?Set(DIAL_TRUNK_OPTIONS=M(setmusic^default)tTkKc)") in new stack
-- Executing [[email protected]:16] Macro("SIP/4310-000031f1", "dialout-trunk-predial-hook,") in new stack
-- Executing [[email protected]:1] NoOp("SIP/4310-000031f1", "Trunk SIP/Teliax-backup selected") in new stack
-- Executing [[email protected]:2] GotoIf("SIP/4310-000031f1", "0?skip") in new stack
-- Executing [[email protected]:3] NoOp("SIP/4310-000031f1", "Setting DIAL_TRUNK_OPTIONS to Ww") in new stack
-- Executing [[email protected]:4] Set("SIP/4310-000031f1", "DIAL_TRUNK_OPTIONS="Ww"") in new stack
-- Executing [[email protected]:5] MacroExit("SIP/4310-000031f1", "") in new stack
-- Executing [[email protected]:17] GotoIf("SIP/4310-000031f1", "0?bypass,1") in new stack
-- Executing [[email protected]:18] GotoIf("SIP/4310-000031f1", "0?customtrunk") in new stack
-- Executing [[email protected]:19] Set("SIP/4310-000031f1", "Count=10") in new stack
-- Executing [[email protected]:20] Set("SIP/4310-000031f1", "BEEP=5") in new stack
-- Executing [[email protected]:21] GotoIf("SIP/4310-000031f1", "0?godial:playbeep") in new stack
-- Goto (macro-dialout-trunk,s,22)
-- Executing [[email protected]:22] Set("SIP/4310-000031f1", "_DIAL_TRUNK_OPTIONS="Ww"L(36000000:36000000:30000)") in new stack
-- Executing [[email protected]:23] Set("SIP/4310-000031f1", "LIMIT_WARNING_FILE=custom/recordingtone2") in new stack
-- Executing [[email protected]:24] Set("SIP/4310-000031f1", "LIMIT_PLAYAUDIO_CALLER=no") in new stack
-- Executing [[email protected]:25] Set("SIP/4310-000031f1", "LIMIT_PLAYAUDIO_CALLEE=yes") in new stack
-- Executing [[email protected]:26] Dial("SIP/4310-000031f1", "SIP/Teliax-backup/13108013666,300,"Ww"L(36000000:36000000:30000)") in new stack

== Using SIP RTP TOS bits 184
== Using SIP RTP CoS mark 5
– Called SIP/Teliax-backup/13108013666

Any one have a clue how can i do this job in a right way.

Thank you.

No comments ? :frowning:

Only one,

http://www.freepbx.org/forum/general-help/read-before-posting