Hello. Is it possible to change the defined moh sound file within an extension? I have: exten => 18,1,Answer exten => 18,n,Wait(3) exten => 18,n,SetMusicOnHold(durchwahl) exten => 18,n,Dial(SIP/118,15,m) exten => 18,n,Hangup Now i have the situation someone calls and my phone is ringing while moh (durchwahl) is playing. When i pickup the call and press the hold button during the call moh (durchwahl) is playing as moh. Thats not what i want. Can i define another file within this extension? regards t. -- knowledgeTools? ... managing complexity. -------------------------------------------------- knowledgeTools International GmbH Wallstra?e 15 / 15 a 10179 Berlin Fon: +49 30 726 169 20 Fax: +49 30 726 169 249 thomas.stein@knowledgetools.de knowledgetools.de Sitz Berlin, AG Berlin-Charlottenburg, HRB 86378 Gesch?ftsf?hrer: Oliver Seyboldt, Reinhard Kunz -------------------------------------------------- This eMail communication (and any attachment/s) may contain confidential or privileged information and is intended only for the individual(s) or entity named above and to others who have been specifically authorized to receive it. If you are not the intended recipient, please do not read, copy, use or disclose the contents of this communication to others. Please notify the sender that you have received this e-mail in error by reply e-mail, and delete the e-mail subsequently. Thank you.
Add a r option with that extension so that way when it is called it will ring and then when you put it on hold it will play your moh. You can also set the MOH in sip.conf, but you will still get the same behavior you have now. Thomas Stein wrote:> Hello. > > Is it possible to change the defined moh sound file within an extension? > > I have: > > exten => 18,1,Answer > exten => 18,n,Wait(3) > exten => 18,n,SetMusicOnHold(durchwahl) > exten => 18,n,Dial(SIP/118,15,m) > exten => 18,n,Hangup > > Now i have the situation someone calls and my phone is ringing while moh > (durchwahl) is playing. When i pickup the call and press the hold button > during the call moh (durchwahl) is playing as moh. Thats not what i want. Can > i define another file within this extension? > > regards > t. >
"r" should never be used on the Dial line. Anthony Francis wrote:> Add a r option with that extension so that way when it is called it will > ring and then when you put it on hold it will play your moh. You can > also set the MOH in sip.conf, but you will still get the same behavior > you have now. > > Thomas Stein wrote: >> Hello. >> >> Is it possible to change the defined moh sound file within an extension? >> >> I have: >> >> exten => 18,1,Answer >> exten => 18,n,Wait(3) >> exten => 18,n,SetMusicOnHold(durchwahl) >> exten => 18,n,Dial(SIP/118,15,m) >> exten => 18,n,Hangup >> >> Now i have the situation someone calls and my phone is ringing while >> moh (durchwahl) is playing. When i pickup the call and press the hold >> button during the call moh (durchwahl) is playing as moh. Thats not >> what i want. Can i define another file within this extension? >> regards >> t. >> > > _______________________________________________ > --Bandwidth and Colocation provided by Easynews.com -- > > asterisk-users mailing list > To UNSUBSCRIBE or update options visit: > lists.digium.com/mailman/listinfo/asterisk-users >
On 6/11/07, Thomas Stein <thomas.stein@knowledgetools.de> wrote: [snip]> Now i have the situation someone calls and my phone is ringing while moh > (durchwahl) is playing. When i pickup the call and press the hold button > during the call moh (durchwahl) is playing as moh. Thats not what i want. Can > i define another file within this extension?You can try to call dial with M option, and set MOH for hold on macro. something like this: Dial(SIP/118,15,mM(call-answer)) [macro-call-answer] SetMusicOnHold(other) Regards, Atis
I think a real simple solution is to use a variable and you can change it when ever you want. So you can do exten => XXX,X,Musiconhold(${VARIABLE}) and then you can create an extension that will change the value of ${VARIABLE} something like: exten => 123,1,Answer exten => 123,2,Background(please-select-moh-to-use) exten => 1,1,Set(VARIABLE=moh1) exten => 1,1,Set(VARIABLE=moh2) exten => 1,1,Set(VARIABLE=moh3) exten => 1,1,Set(VARIABLE=moh4) ----- Original Message ----- From: "Thomas Stein" <thomas.stein@knowledgetools.de> To: <asterisk-users@lists.digium.com> Sent: Monday, June 11, 2007 4:37 PM Subject: [asterisk-users] change moh during a call? Hello. Is it possible to change the defined moh sound file within an extension? I have: exten => 18,1,Answer exten => 18,n,Wait(3) exten => 18,n,SetMusicOnHold(durchwahl) exten => 18,n,Dial(SIP/118,15,m) exten => 18,n,Hangup Now i have the situation someone calls and my phone is ringing while moh (durchwahl) is playing. When i pickup the call and press the hold button during the call moh (durchwahl) is playing as moh. Thats not what i want. Can i define another file within this extension? regards t. -- knowledgeTools? ... managing complexity. -------------------------------------------------- knowledgeTools International GmbH Wallstra?e 15 / 15 a 10179 Berlin Fon: +49 30 726 169 20 Fax: +49 30 726 169 249 thomas.stein@knowledgetools.de knowledgetools.de Sitz Berlin, AG Berlin-Charlottenburg, HRB 86378 Gesch?ftsf?hrer: Oliver Seyboldt, Reinhard Kunz -------------------------------------------------- This eMail communication (and any attachment/s) may contain confidential or privileged information and is intended only for the individual(s) or entity named above and to others who have been specifically authorized to receive it. If you are not the intended recipient, please do not read, copy, use or disclose the contents of this communication to others. Please notify the sender that you have received this e-mail in error by reply e-mail, and delete the e-mail subsequently. Thank you. _______________________________________________ --Bandwidth and Colocation provided by Easynews.com -- asterisk-users mailing list To UNSUBSCRIBE or update options visit: lists.digium.com/mailman/listinfo/asterisk-users
On Monday 11 June 2007, Thomas Stein wrote:> Hello. > > Is it possible to change the defined moh sound file within an extension? > > I have: > > exten => 18,1,Answer > exten => 18,n,Wait(3) > exten => 18,n,SetMusicOnHold(durchwahl) > exten => 18,n,Dial(SIP/118,15,m) > exten => 18,n,HangupIt's possible to change moh behaviour after the dial command. exten => 18,1,Answer exten => 18,n,Wait(3) exten => 18,n,SetMusicOnHold(durchwahl) exten => 18,n,Dial(SIP/118,15,m) exten => 18,n,SetMusicOnHold(default) This works for me. regards t. -- knowledgeTools? ... managing complexity. -------------------------------------------------- knowledgeTools International GmbH Wallstra?e 15 / 15 a 10179 Berlin Fon: +49 30 726 169 20 Fax: +49 30 726 169 249 thomas.stein@knowledgetools.de knowledgetools.de Sitz Berlin, AG Berlin-Charlottenburg, HRB 86378 Gesch?ftsf?hrer: Oliver Seyboldt, Reinhard Kunz -------------------------------------------------- This eMail communication (and any attachment/s) may contain confidential or privileged information and is intended only for the individual(s) or entity named above and to others who have been specifically authorized to receive it. If you are not the intended recipient, please do not read, copy, use or disclose the contents of this communication to others. Please notify the sender that you have received this e-mail in error by reply e-mail, and delete the e-mail subsequently. Thank you.