I am using Asterisk 1.4 compiled from source for SuSe Linux Enterprise 10.
I configured the Asterisk to play a wav file for certain set of calls. It downloads a wave file from another server and plays it. If the wav contains ulaw, gsm, etc., it plays without any problem. It couldn’t handle a wav file containing pcm format in 8 bit samples. Asterisk rejects with an error saying “Can only handle 16bits per sample”.
I can always use format conversion program such as sox but I am trying to find out whether Asterisk could handle it. ie, for any given call, the wav file is downloaded from another server with which I don’t have any control. So, in order to avoid delay in converting the file format using external program such as sox, I am trying to tweak Asterisk.
I renamed the file with extension “.pcm” to make Asterisk to understand but format_pcm module doesn’t extract pcm content from RIFF format, before playing it.
What is the best way to enable Asterisk to recognize a wav file containing 16 bit samples of pcm format.
I am fairly comfortable in changing the Asterisk code base. So I am open to every possible suggestions.