91av视频/亚洲h视频/操亚洲美女/外国一级黄色毛片 - 国产三级三级三级三级

  • 大小: 75KB
    文件類型: .zip
    金幣: 2
    下載: 1 次
    發布日期: 2021-05-23
  • 語言: Matlab
  • 標簽: Matlab??GUI??

資源簡介

擴頻通信的Matlab仿真程序。 使用了GUI界面設計。 可使用三種偽隨機碼(m序列,gold碼,walsh序列),可選擇直接擴頻或跳頻方式來實現。

資源截圖

代碼片段和文件信息

%直接擴頻處理
function?rec_seq=direct_spread(rand_x1pn_sequences_n)
figure(3);
clf;
gt=rand_x1.*pn_sequence;?%直接擴頻
subplot(211);
plot(gt);
axis([0?250?-2?2]);
title(‘擴頻后的碼序列‘);
grid?on;

seq_length_1=length(gt);
n_sample_1=0:(seq_length_1-1);
f_1=n_sample_1*2*pi/seq_length_1;
subplot(212);
plot(f_1-piabs(fftshift(fft(gt))));
%axis([-100?100?0?2000]);
title(‘擴頻后的碼序列頻譜圖‘);
grid?on;

sampling_2=20;
gt1=signal_sampling(gtsampling_2);%采樣

seq_length=length(gt1);
%BPSK調制
fs=5e5;??
f0=1e5;????
AI=1;
cI=zeros(1seq_length);
for?i=1:seq_length
????cI(i)=AI*cos(2*pi*f0*(i-1)/fs);
end
x_bpsk=gt1.*cI;

figure(4);
subplot(211);
plot(x_bpsk);
axis([400?600?-2?2]);
title(‘BPSK調制后的波形‘);
grid?on;

%加噪模塊
x_bpsk1=awgn(x_bpsks_n);%信噪比SNR為s_ndb
subplot(212);
plot(x_bpsk1);
axis([400?600?-2.5?2.5]);
title(‘加噪后已調波的波形‘);
grid?on;

%解調模塊
figure(5);
clf;
s=x_bpsk1.*cI*2;
subplot(211);
plot(s);
axis([400?600?-3?3]);
title(‘經解調后的波形‘);
grid?on;

%低通濾波
wn=0.5/pi;??%截止頻率wn=fn/(fs/2),這里fn為擴頻碼的帶寬5M
b=fir1(12wn);
x_recovery=filter(b1s);
subplot(212);
plot(x_recovery);
axis([400?600?-3?3]);
title(‘經濾波后的波形‘);
grid?on;

x_recovery_1=x_recovery(round(sampling_2/2):sampling_2:end);%抽樣
%相關解擴
jk_code=x_recovery_1.*pn_sequence;
rec_seq=jk_code;


%頻譜圖
figure(6);
clf;
n_sample=0:(seq_length-1);
f=n_sample*2*pi/seq_length;
subplot(221);
plot(f-piabs(fftshift(fft(x_bpsk))));
%axis([-2.5?2.5?0?1000]);
title(‘bpsk已調波的頻譜圖‘);
grid?on;

subplot(222);
plot(f-piabs(fftshift(fft(x_bpsk1))));
%axis([-2.5?2.5?0?1000]);
title(‘加噪已調波的頻譜圖‘);
grid?on;

subplot(223);
plot(f-piabs(fftshift(fft(s))));
%axis([-2.5?2.5?0?1000]);
title(‘解調后的頻譜圖‘);
grid?on;

subplot(224);
plot(f-piabs(fftshift(fft(x_recovery))));
%axis([-100?100?0?2000]);
title(‘濾波后信號的頻譜圖‘);
grid?on;

figure(7);
clf;
subplot(211);
plot(jk_code);
axis([0?seq_length_1*1.1?-2?2]);
title(‘解擴后的波形‘);
grid?on;

subplot(212);
plot(f_1-piabs(fftshift(fft(jk_code))));
%axis([-100?100?0?2000]);
title(‘解擴后波形的頻譜圖‘);
grid?on;
end

?屬性????????????大小?????日期????時間???名稱
-----------?---------??----------?-----??----
?????目錄???????????0??2019-07-16?16:32??擴頻通信的Matlab代碼\
?????文件????????2245??2019-05-26?14:28??擴頻通信的Matlab代碼\direct_spread.m
?????文件????????1543??2019-05-26?13:46??擴頻通信的Matlab代碼\freq_hopping.m
?????文件????????1757??2019-05-26?10:44??擴頻通信的Matlab代碼\my_seq.m
?????文件???????69785??2019-05-26?13:57??擴頻通信的Matlab代碼\my_work.fig
?????文件????????8238??2019-05-26?13:57??擴頻通信的Matlab代碼\my_work.m
?????文件?????????101??2019-07-16?16:34??擴頻通信的Matlab代碼\readme.txt
?????文件?????????330??2019-05-26?12:11??擴頻通信的Matlab代碼\rec_signal_jud.m
?????文件?????????424??2019-05-23?12:26??擴頻通信的Matlab代碼\select_freq.m
?????文件?????????272??2019-05-26?09:22??擴頻通信的Matlab代碼\signal_sampling.m

評論

共有 條評論