Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

qpsk project..pls help me

Status
Not open for further replies.

farhan13

Newbie level 5
Joined
Feb 3, 2010
Messages
8
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Activity points
1,324
hi..
i have a problem regarding qpsk project..
input for i & q are:

i=0.5sin(2pi10t)+sin(2pi20t)
q=0.7sin(2pi15t)+0.3sin(2pi25t)

sampling freq=500
carrier freq=21000

how do i simulate this using matlab?do u have any code example?

below are the diagram for my project

 

pls help me..anybody..i haven't found a way to do matlab coding
 

clc;
clear all;close all;
disp('M-Array PSK Modulation')
%create a random digital message
M=input ('M= '); %alphabet size
x=randint(input('Number of binary bit stream = '),1,M);
%%

nsample=40; %oversampling rate.
%%

%%
%use M-PSK modulation to produce y
y=modulate(modem.pskmod(M),x);
L=length(y)
%%
%follow with rectangular pulse shaping.
ypulse=rectpulse(y,nsample);

%%
% Power Spectral Density plot
pwelch(ypulse)
%%
%%transmit signal through an AWGN Channel
ynoisy=awgn(ypulse,input('SNR in dB = '),'measured');

%%
%Create scattet plot from noisy data
scatterplot(ynoisy),grid;
%%
%Downsample at the reciever.
ydownsample=intdump(ynoisy,nsample);
%%
%Demodulate ynoisy to recover the message.
z=demodulate(modem.pskdemod(M),ydownsample);
figure;
subplot(2,1,1);
stem(x(1:10),'filled'),grid;
subplot(2,1,2);
stem(z(1:10),'filled'),grid;
%%
%Check symbole erroe rate.
[num ty]=symerr(x,z)
 

sorry..still don't understand..
how do i put both input for i & q in the code?

btw, i need qpsk output
 

i=0.5sin(2pi10t)+sin(2pi20t)
q=0.7sin(2pi15t)+0.3sin(2pi25t)

sampling freq=500
carrier freq=21000

how do i change both i&q input to digital?pls help..
 

If you for e.g. Mod contains QPSK modulated symbols, this is how you can transmit it on I and Q components

real(Mod)*I + j* imag(Mod)*Q
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top