File Exchange

image thumbnail

Direct Sequence Spread Spectrum (DSSS) for BPSK, QPSK and 16QAM modulations

version 2.0.0.0 (8.29 KB) by Behind The Sciences
BPSK, QPSK and 16QAM DSSS Tx and Rx with multipath channel

19 Downloads

Updated 02 Jul 2017

View Version History

View License

There are 3 functions containing the BPSK, QPSK and 16QAM transmitter, channel (multipath Rayleigh and exponentially decaying plus AWGN) and a script which calls the 3 functions and plots BER and PER results. For more information, please, have a look to this post: https://sites.google.com/site/solutionsbehindthesciences/towards-5g/bpskqpskand16qamdssstxandrxwithmultipathchannel
Also feel free to comment or ask :) Thanks!

Cite As

Behind The Sciences (2021). Direct Sequence Spread Spectrum (DSSS) for BPSK, QPSK and 16QAM modulations (https://www.mathworks.com/matlabcentral/fileexchange/55810-direct-sequence-spread-spectrum-dsss-for-bpsk-qpsk-and-16qam-modulations), MATLAB Central File Exchange. Retrieved .

Comments and Ratings (5)

Behind The Sciences

Thanks, Vadim, but commenting those "ends" seems to make the function wrong.

Also, there were a mistake in the main function, in the plot, so the constellation with zero PER is actually QPSK because the errors are calculating using this formula:

errors1=sum(xor(sign(real(decodeBit)),sign(si)));
errors2=sum(xor(sign(imag(decodeBit)),sign(sq)));
errors = erros1+errors2; % couting the number of errors

And errors1 and errors2 are zero. There is a new version uploaded with the plot corrected.

Thanks for the comments!

vadim onuchin

I find error in BPSK m-file.
2 "end" must come through to end file:
....
vark=var0*exp(-k*sampTime/delaySprd);
end
stanDevChan=sqrt(vark/2); %factor root 2 so half power in real and imag.
h=stanDevChan.*(randn(1,numPaths)+1i*randn(1,numPaths));
end
% end
% end
...

please I try to plot bit error for Bpsk ,I get zero ,Can you cheack the function its work or not?

Tahir Ibitoye

For the Bpsk, it's giving zero except for the last plot and please can I get the plot for the bit error rate

flower bel

MATLAB Release Compatibility
Created with R2017a
Compatible with any release
Platform Compatibility
Windows macOS Linux

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!