If an inbound audio stream is using the G.711 mu-law codec, in what format should I record a message so G.711 mu-law is the codec used in the resultant audio files?
Also, If the above format is not .wav, what kind of performance hit should one expect when recording an incoming G.711 mu-law audio stream as a .wav file?
Thanks,
James
222
333wav format
by clagos, Tuesday 11 of July, 2006 [18:00:53 UTC]
Asterisk records wav files in 16bits, signed. Is there any way of recording in 8bits, unsigned? I hope someone can help me. Thanks
222
333Anotger example
by , Tuesday 13 of April, 2004 [13:12:24 UTC]
I use this for recording samples, it is still a bit clunky, but offers the ability to re-record if you need to, and also to record a bunch of prompts in one hit (instead of needing to go and re-name the file after each recording).
Just paste this to your extensions.conf and include the recordings context for your line. If this breaks, you can keep both parts, if you fix it, please leave a comment here, and/or let me know...
recordings exten => 500,1,Festival,Please record your message
exten => 500,2,Record,mymessage:gsm
exten => 500,3,Festival,You said
exten => 500,4,Playback,mymessage
exten => 500,5,Festival,Press 1 to continue or 2 to change your message
exten => 500,6,ResponseTimeout,3
exten => t,1,Festival,Sorry, I did not get that
exten => t,2,Goto,500|5
exten => i,1,Festival,Sorry, that is an invalid choice
exten => i,2,Goto,500|5
exten => 1,1,System,/bin/mv /var/lib/asterisk/sounds/mymessage.gsm /var/lib/asterisk/sounds/local/`date +%s`.gsm
exten => 1,2,Festival,Thank you, your recording has been saved.
exten => 1,3,Festival,Press 3 to record another file or 4 to hang up
exten => 2,1,Goto,500|1
exten => 3,1,Goto,500|1
exten => 4,1,Hangup
Hmmm, newer versions of asterisk include a variable with current unixtime, I wrote this ages ago.
My Grandstream 486 just died. So I'm in the market. Current router is Netgear MR814v2, which does NAT, WiFi, and I had the 486 hooked to it, and things worked.
Is it better to go with a single box that does everything? Or a different/better router with QoS support? Or?
Comments
333Recording a G.711 mu-law stream to avoid transcoding
If an inbound audio stream is using the G.711 mu-law codec, in what format should I record a message so G.711 mu-law is the codec used in the resultant audio files?
Also, If the above format is not .wav, what kind of performance hit should one expect when recording an incoming G.711 mu-law audio stream as a .wav file?
Thanks,
James
333wav format
333Anotger example
Just paste this to your extensions.conf and include the recordings context for your line. If this breaks, you can keep both parts, if you fix it, please leave a comment here, and/or let me know...
recordings
exten => 500,1,Festival,Please record your message
exten => 500,2,Record,mymessage:gsm
exten => 500,3,Festival,You said
exten => 500,4,Playback,mymessage
exten => 500,5,Festival,Press 1 to continue or 2 to change your message
exten => 500,6,ResponseTimeout,3
exten => t,1,Festival,Sorry, I did not get that
exten => t,2,Goto,500|5
exten => i,1,Festival,Sorry, that is an invalid choice
exten => i,2,Goto,500|5
exten => 1,1,System,/bin/mv /var/lib/asterisk/sounds/mymessage.gsm /var/lib/asterisk/sounds/local/`date +%s`.gsm
exten => 1,2,Festival,Thank you, your recording has been saved.
exten => 1,3,Festival,Press 3 to record another file or 4 to hang up
exten => 2,1,Goto,500|1
exten => 3,1,Goto,500|1
exten => 4,1,Hangup
Hmmm, newer versions of asterisk include a variable with current unixtime, I wrote this ages ago.