clear all
%reads a file at 16kHz and outputs it a 8kHz, 8 bits


letters='abcdefghijklmnopqrstuvwxyz';
name='a-16khz.wav';
% name='a-ATT-8khz.wav';

for i=1:26
    name=[letters(i) name(2:length(name))]
    [d,r] = wavread(name);
%     y = resample(d, 8, 11);
y = resample(d, 8, 11);
    

    name=[name(1:10) '-8khz.wav'];
    wavwrite(y,8000,8,name)
    name=[name(1:10) '-11khz.wav'];
    
end
