[asterisk-users] syntax

Steve Edwards asterisk.org at sedwards.com
Sun Feb 7 19:24:13 CST 2010


Un-top-posting...

> [mailto:asterisk-users-bounces at lists.digium.com] On Behalf Of Thomas 
> Perron
>
> I am trying to understand .call files.
>
> The logs seems to indicate issues with the audio file that I am trying 
> to have played when the call is connected. Any thoughts?  Some sample 
> files and logs to console are shown.
>
> zipppppp-code.call
> Channel:  SIP/callwithus/12023519259
> Application: Playback
> Data: zipppppp-code.gsm
>
> [root at localhost tmp]# touch zipppppp-code.call
> [root at localhost tmp]# vi zipppppp-code.call
> [root at localhost tmp]# mv zipppppp-code.call /var/spool/asterisk/outgoing/

On Sun, 7 Feb 2010, Tom Moore wrote:

> Your sound file needs to be in the asterisk sounds directory. Another 
> thing is that you may not have to put the file extension in the name if 
> the file is in the proper place as well.

0) You will get better results (and generate a better "resource" for the 
next guy) if you choose a more meaningful subject than "syntax." Googling 
for "syntax" returns results for "about 34,000,000" entries while 
"asterisk call file syntax" only returns results for "about 300,000" 
entries -- most of which will be somewhat relevant.

1) Unless your file is named "zipppppp-code.gsm.gsm" you should not be 
specifying the file type.

2) The value specified with "data:" should be the file path excluding the 
file type -- the same as playback() expects in the dialplan. If the path 
does not start with a "/" (an absolute file path) it is "relative" to the 
value of "${astvarlibdir}/sounds/" where astvarlibdir is set in 
asterisk.conf. Personally, I like to keep my cruft out of Asterisk's 
directories and organize them by project or client. For example, I would 
store zipppppp-code.gsm in /var/lib/asterisk/sounds/war-dialer/ so it 
could be specified in the call file as war-dialer/zipppppp-code.

3) Why do you touch the call file before editing it?

-- 
Thanks in advance,
-------------------------------------------------------------------------
Steve Edwards       sedwards at sedwards.com      Voice: +1-760-468-3867 PST
Newline                                              Fax: +1-760-731-3000



More information about the asterisk-users mailing list