generate pure tones in matlab
April 30th, 2007 by Lawrence David
save the following code to an m-file and run in matlab to generate some pure tones in wav format.
% pure tones
clear
freqs = 500;
duration = 100;for i = 1:length(freqs)
sampleFreq = 44100;
dt = 1/sampleFreq;t = [0:dt:duration];
s=sin(2*pi*freqs(i)*t);
sound(s,sampleFreq);
% wavName = sprintf(‘tone%d.wav’,freqs(i));
% wavwrite(s,sampleFreq,16,wavName);end
Can u help in generating ctcss tones??
please
[...] geeks: here’s the code used to generate these [...]