O'Reilly logo

VoIP Hacks by Theodore Wallingford

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Hack #24. Create Telephony Sounds with SoX

Use the Swiss Army knife of sound-conversion utilities for your VoIP setup.

Though dozens of utilities are available for converting and tweaking audio files, the cross-platform open source audio tool called SoX really stands out. If you've got a Linux or BSD PC, chances are pretty good that you've got SoX installed. Windows and Mac users will have to download a compatible version of SoX from http://sox.sourceforge.net/. And since SoX is a command-line utility, you'll need to be at least a mediocre typist to get through this hack and the next two hacks. You'll also need to know how to get to a command line on your particular platform. On Windows, this means running the MS-DOS prompt. On the Mac, it's the Terminal. Linux and BSD users need only to fire up xterm. This hack will show you the ins and outs of using SoX to convert audio files from one format to another, add audio effects, and telephonize your audio through downsampling.

File Format Conversion

File format conversion is perhaps SoX's biggest strength. You can use SoX to convert from one format to another (WAV, AIFF, etc.) and from one encoding to another (uLaw, MP3, etc.). It even supports some fossilized sound formats like 8SVX and .voc. All of this format support is helpful if you want to use a file that you have only in some oddball format that your telephony software can't use.

In most telephony applications, like voicemail and interactive voice response (IVR), where recorded voice ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required