0

matlab如何进行频率解调

我已经做了频率调制,但我不能做频率解调这是matlab代码

clear all 
close all 
recorder = audiorecorder(44100,16,1);
recordblocking(recorder,2);
xtmessage = getaudiodata(recorder);

time=(1/44100)*length(xtmessage);
t=linspace(0,time,length(xtmessage));

xt=xtmessage/max(abs(xtmessage)); %normalization
Ac=2; %amplitude
fc=10000; %carrier frequency
Df= 6000; % frequency deviation

variant = 0;
for n=1:88200;
    variant = variant + xt(n);
    xct(n) = Ac*cos(2*pi*fc*n/44100 + 2*pi*Df*variant/88200);
end

Xft = fft(xct);
Xft = fftshift(Xft);
plot(abs(Xft))
4

1 回答 1

0

您可以使用 fmmod() 和 fmdemod()。是 fmdemod 函数的文档链接

于 2014-02-20T08:55:13.237 回答