I am generating series of 1 and 0. then pulse shaped them with root raised cosine and after than deciding to do match filtering and recovering the bits however it turns out that I am not getting the correct bits. What I do is as follow:
- generate 0 and 1.
- pulse shape them with RRC.
- match filter using the same transmited filter
- Remove samples up to peak using
[val,pos]=max(mysignal)
- sample using mysingal(pos:overample:end)
But what I get is not correct. I simulated this using 10 bits but I get only 2. I know there is something wrong but I do not know why. My method works when I only have one bit.
I am wondering if I have more than one bit should I do this procedure for every bit.How can I approach this problem.
This is also my code assume RX2 is the pulse shaped version of my signal and os is the oversampling factor and 0.25 is the roll of factor. I am wondering how to detect all the bits like all 10 or 100?
RX1=filter(srrc(os,0.25),1,RX2);
[val,pos]=max(RX1);
RX=RX1(pos:os:end);
Bits=RX;
One=Bits>=Th;
BER=sum(One)/length(Bits);
The first one is the signal after passing through matched filter using conv command and no built in command like filter. the original bits are 0 0 1 1 1 Can anyone tell me how can I sample signal to get these bits back. what command I should use. simply downsampling will not work.
The second one is for the same bits but using filter command for 0 0 1 1 1 can anyone please tell me how to obtain correct bits back from any of these figures.
No comments:
Post a Comment