How To Convert MP3 Files To WAV In Linux
Sometimes we need to convert mp3 files into wav files and there are many different tools out there that do the same job, but which one to use? This short tutorial will teach you how to use the mpg321 commandline utility to convert your mp3 file into a wav file. Can you give us more information about the mpg321 tool?
Who likes to play songs from terminal? I do! mpg321 is used to play mp3 files from the commandline. It is licensed under under the GNU General Public License version 2 and comes many features such as IPv6 support, HTTP proxy support with basic authentication mechanism etc. You can read all the mpg321 features in the following list:
– mpg321 now supports multiprocessing buffering.Check ‘-b’ option.
– Added ‘-3′ or ‘–restart’ option in man file.
– Added ALSA volume control when using output buffer.
– Added Mute/unmute into Basic Keys functionality.
– Added AudioScrobbler (last.fm) reporting and FFT support in remote mode play.
– Added HTTP proxy support with basic authentication mechanism.
– Added IPv6 support.
– Added xterm title settiing.
– mpg321 utilises the new channel mapping features provided by the libao version.
– mpg321 no longer segfaults on mp3s with an incomplete set of id3 tags.
– Fix the -k option, which was broken in 0.2.9.
– mpg321 now tries all other output devices if its default device can’t be opened. If esd is using your sound card, mpg321 will now fall back on esd for output.
I think it is time to install the tool and give it a try. If you are using Ubuntu or Debian, just run the following commands to install the mpg321 tool.
sudo apt-get update sudo apt-get install mpg321
Are you a CentOS /RHEL/Fedora Linux user? Then use the following command to install mpg321 in your system.
yum install mpg321
Now that the command-line mp3 player is installed on your machine, suppose you want to convert your test.mp3 file which is stored in your home directory, into a wav file. Do you have any idea how to do that? If not, then just keep reading this tutorial, because it is very simple. Open new terminal, navigate to the directory where you have stored your mp3 file and run the following command.
mpg321 -w output.wav test.mp3
The -w option is the short of –wav, which tells the tool to use the specified wav file for output. In my case, the specified wav file is output.wav, which will be the output of the mpg321 command.
This is a very simple tip, but very useful! Do you find my simple tip useful? If so, don’t forget to share this tutorial with your family and friends.