Writing PCM recorded data into a .wav file (java android)
I'm using AudioRecord to record 16 bit PCM data in android. After recording the data and saving it to a file, I read it back to save it as .wav file. The problem is that the WAV files are recognized by media players but play nothing but pure noise. My best guess at the moment is that my wav file headers are incorrect but I have been unable to see what exactly the problem is. (I think this because I can play the raw PCM data that I recorded in Audacity) Here's my code for reading the raw PCM file and saving it as a .wav: private void properWAV(File fileToConvert, float newRecordingID){ try {