Technical Helpweb

Dialogic® PowerMedia™ Extended Media Server (PowerMedia XMS) - more articles

PowerMedia XMS Native MSML: Invalid audio mimetype parameters


There may be a failure to record a WAV file when using Dialogic® PowerMedia™ XMS and Native Mode MSML. If so, the application gets a "Resource unavailable" response to the record command, and xmserver logs show:

ERROR FileRecorder::init() Invalid audio mimetype parameters: "audio/wav;codec=pcm"

Reason for the issue

PowerMedia XMS in Native mode is stricter than the legacy MSML mode for the "codecs" keyword in the format attribute when doing record or play. Legacy MSML mode will accept "codec" or "codecs", while Native MSML mode accepts only "codecs".

This difference between legacy and native MSML is documented on page 69 (section 4) of the Dialogic® PowerMedia™ XMS MSML Media Server Software User's Guide: "The codecs keyword of the format attribute for media play and record must be specified in the plural exactly as written in RFC 5707. The legacy MSML accepted codec as a substitute for codecs. This is no longer the case. The Native MSML strictly follows RFC 5707."

Here is the relevant section of RFC5707:

The format attribute is defined as a string type of form "audio/;codecs=". The keyword 'audio' identifies an audio content. The codecs field identifies the audio file's codec to be used for decoding the audio content. If format attribute is not specified, the filetype MUST be determined from the URI and the codec information MUST be determined from the media resource.

For the PCM codec specifically, you also need to specify the audiosamplesize and audiosamplerate parameters.


For some formats (for example "audio/wav;codecs=alaw") it is enough to change "codec" to "codecs" in the format attribute.

For linear PCM ("audio/wav;codecs=pcm"), you also need to specify the sample size and sample rate. For example:

format="audio/wav;codecs=pcm" audiosamplesize="16" audiosamplerate="16"



Please rate the usefulness of this page:  
0 - not useful at all
1 - potentially useful
2 - quite useful
3 - very useful
4 - exactly the information I needed     

Please enter a comment about this page:

First published: 22-May-2015
Open access: Product rule: open; Page rule: Auto