Scattered stuff from Silas during Dissertation
This commit is contained in:
@@ -3,29 +3,10 @@ M = 4;
|
||||
randkey = 2;
|
||||
fsym = 112e9;
|
||||
|
||||
%%%%% PRBS Generation in correct shape for Modulation Format %%%%%%
|
||||
O = 18; %order of prbs
|
||||
N = 2^(O-1); %length of prbs
|
||||
[~,seed] = prbs(O,1); %initialize first seed of prbs
|
||||
bitpattern=[];
|
||||
|
||||
if useprbs
|
||||
for i = 1:log2(M)
|
||||
[bitpattern(:,i),seed] = prbs(O,N,seed);
|
||||
end
|
||||
else
|
||||
s = RandStream('twister','Seed',randkey);
|
||||
for i = 1:log2(M)
|
||||
bitpattern(:,i) = randi(s,[0 1], N, 1);
|
||||
end
|
||||
end
|
||||
|
||||
if M == 6
|
||||
bitpattern = reshape(bitpattern,[],1);
|
||||
bitpattern = bitpattern(1:end-mod(length(bitpattern),5));
|
||||
end
|
||||
|
||||
Tx_bits = Informationsignal(bitpattern);
|
||||
Tx_bits = Signalgenerator( ...
|
||||
"form", signalform.prms, ...
|
||||
"M", M, ...
|
||||
"order", 15).process();
|
||||
|
||||
Digi_Mod = PAMmapper(M,0);
|
||||
Symbols_tx = Digi_Mod.map(Tx_bits);
|
||||
@@ -52,7 +33,7 @@ else
|
||||
|
||||
Symbols.spectrum("fignum",129,"displayname",['coeff:',num2str(coeff)]);
|
||||
|
||||
Symbols = MLSE("DIR",coeff,"duobinary_output",0,"trellis_states",Digi_Mod.levels,"M",M).process(Symbols);
|
||||
Symbols = MLSE("DIR",coeff,"duobinary_output",0,"trellis_states",Digi_Mod.levels,"M",M).process(Symbols,Symbols_tx);
|
||||
|
||||
Rx_bits = PAMmapper(M,0).demap(Symbols);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user