Recording NLS-format cassettes

Geoff Shang geoff at hitsandpieces.net
Mon Apr 17 06:11:30 UTC 2006


Hi,

sox is your friend.  It can be used to do pretty much all of this.

When I've done this, I've recorded the audio in at 44.1kHz 16-bit stereo, 
then resampled down to 22.05kHz to halve the speed.  If your device has 
some aliasing when playing 22.05kHz material, you could always use sox to 
resample back up to 44.1kHz, but use the resample effect or something else 
more complex, not the simple rate conversion as it will leave these 
aliasing effects in place.

But I'm getting ahead of myself.

First, the side-splitting.  there's a few ways you can do this:

1.  Use the avg or pick effects in sox.  The version of sox you have will 
determine which of these effects actually works for you.  I've had problems 
with both in various versions of sox, so have an experiment, but one of 
them should work.

2.  Alternatively, if you use ALSA, I know that arecord used at least to 
have a feature where you could record the left in one channel and the right 
in the other.  hmmmm ok the help doesn't mention it, but it's the -I 
option.  Though it appears to only record in raw data, not as a wav file. 
Still, sox could fix that if you wanted.

Having done that, you can use the reverse effect on the backwards files:

sox side3.wav side3forward.wav reverse
sox side4.wav side4forward.wav reverse

For trimming, I usually use soundgrab to edit manually, but you may be able 
to get Sox's trim effect to work for you.

To halve the speed, you use one of the resampling methods.  In my 
experience, the quick and dirty rate effect is good enough for halving the 
rate from 44.1kHz to 22.05kHz, but you should test it for yourself:

sox -r 22050 side1.wav side1slower.wav rate

or\
sox -r 22050 side2.wav side2slower.wav resample

There's about 4 different resample effects, check out the sox manpage for 
the lowdown on all of them.

I usually also normalise so that I can set my levels at a safe level and 
can have the files as loud as they can be without distorting.  Best to do 
this as your last step so that other effects don't cause the audio to 
distort.

Example:

sox side1slower.wav -e stat -v
sox -v <output of previous comand> side1slower.wav side1louder.wav

1.0 is as loud as it can go, so if it's at 1.0 already, there's no point 
and it may have in fact distorted somewhere.

Got no thoughts about detecting tones etc, I'd be interested to know if 
anyone else has any.

For actually slicing up files, I've not used it, but qwavcut from the 
Quelcomm tools may help if you can get something to detect these tones. 
They're useful programmes to have anyway, I use qwavinfo and qwavjoin 
regularly.  qwavsilence may also help you: 
http://www.etse.urv.es/~dmanye/quelcom/quelcom.html

Hope this all helps.

Geoff.


-- 
Geoff Shang <geoff at hitsandpieces.net>
Phone: +61-418-96-5590
MSN: geoff at acbradio.org

Make sure your E-mail can be read by everyone!
http://www.betips.net/etc/evilmail.html

Please avoid sending me Word or PowerPoint attachments.
See http://www.gnu.org/philosophy/no-word-attachments.html




More information about the Blinux-list mailing list