DSPRelated.com
Forums

Pulse Shaping using RRC filter

Started by Bob February 15, 2008
Hi again,

I am working on a QPSK modulator and demodulator. Without pulse-
shaping everything was fine and I was able to demodulate the
transmitted data  However the spec says I have to use pulse shaping so
I need someone to have a look at the screenshots and indicate whether
they look correct or not.

This first attachment shows the I and Q data streams, passing them
through a root raised cosine filter. Now does the output of the RRC
filters look correct. I am not sure. Should the pulses out of the RRC
be smoother?

http://i248.photobucket.com/albums/gg170/stenasc/RRc_pulses.jpg


This next link is what I am getting at the demodulator. The top three
traces are the I channel data
1...The actual data being sent from the modulator
2...The received I channel data after being mixed with the recovered
carrier (Note the inversion..is this correct)
3...The output from the RRC filter on the receiver I-channel
(Again...does not look to be correct)

and similarly the bottom three are for the Q-channel

http://i248.photobucket.com/albums/gg170/stenasc/RX_Data.jpg

I have spent a lot of time at this and I'm getting nowhere. If the
receiver RRC outputs are garbage, then I can't recover the clock. At
the moment, the PLL is looking at the RRC outputs and saying,,,What is
this...I can't lock to that !! ! any help out there folks.

Regards
Bob
On Fri, 15 Feb 2008 17:01:23 -0800, Bob wrote:

> Hi again, > > I am working on a QPSK modulator and demodulator. Without pulse- shaping > everything was fine and I was able to demodulate the transmitted data > However the spec says I have to use pulse shaping so I need someone to > have a look at the screenshots and indicate whether they look correct or > not. > > This first attachment shows the I and Q data streams, passing them > through a root raised cosine filter. Now does the output of the RRC > filters look correct. I am not sure. Should the pulses out of the RRC be > smoother? > > http://i248.photobucket.com/albums/gg170/stenasc/RRc_pulses.jpg
It should be smoother. I see ringing at at least two frequencies (one is about three times faster than your bit rate, the other appears to be a hair longer than a bit). A root-raised cosine should not ring at all -- if there's no ringing in the prototype, the response to a square wave shouldn't ring either.
> This next link is what I am getting at the demodulator. The top three > traces are the I channel data > 1...The actual data being sent from the modulator 2...The received I > channel data after being mixed with the recovered carrier (Note the > inversion..is this correct) 3...The output from the RRC filter on the > receiver I-channel (Again...does not look to be correct) > > and similarly the bottom three are for the Q-channel > > http://i248.photobucket.com/albums/gg170/stenasc/RX_Data.jpg > > I have spent a lot of time at this and I'm getting nowhere. If the > receiver RRC outputs are garbage, then I can't recover the clock. At the > moment, the PLL is looking at the RRC outputs and saying,,,What is > this...I can't lock to that !! ! any help out there folks. > > Regards > Bob
The demodulated traces look right, but the 'lpf' filtered versions don't. They are smoothed much too much, and they don't appear to have been run through either a RRC filter (at least not one of the correct length) nor do they appear to have run through a linear filter that would have turned your q_data into your q_filter_out trace in your first link. I suspect that your RRC filter code is mangling your data. I very much doubt that it is implementing a linear filter and it certainly isn't implementing an RRC, certainly not one of the right length. At the moment I don't know what to suggest you look for in your filter beyond overflow, bit reversals (do you have that one bus specified as [0..8] instead of [8..0]?), or other plain ol' bugs. -- Tim Wescott Control systems and communications consulting http://www.wescottdesign.com Need to learn how to apply control theory in your embedded system? "Applied Control Theory for Embedded Systems" by Tim Wescott Elsevier/Newnes, http://www.wescottdesign.com/actfes/actfes.html
On Feb 15, 8:01 pm, Bob <sten...@yahoo.com> wrote:
> Hi again, > > I am working on a QPSK modulator and demodulator. Without pulse- > shaping everything was fine and I was able to demodulate the > transmitted data However the spec says I have to use pulse shaping so > I need someone to have a look at the screenshots and indicate whether > they look correct or not. > > This first attachment shows the I and Q data streams, passing them > through a root raised cosine filter. Now does the output of the RRC > filters look correct. I am not sure. Should the pulses out of the RRC > be smoother? > > http://i248.photobucket.com/albums/gg170/stenasc/RRc_pulses.jpg > > This next link is what I am getting at the demodulator. The top three > traces are the I channel data > 1...The actual data being sent from the modulator > 2...The received I channel data after being mixed with the recovered > carrier (Note the inversion..is this correct) > 3...The output from the RRC filter on the receiver I-channel > (Again...does not look to be correct) > > and similarly the bottom three are for the Q-channel > > http://i248.photobucket.com/albums/gg170/stenasc/RX_Data.jpg > > I have spent a lot of time at this and I'm getting nowhere. If the > receiver RRC outputs are garbage, then I can't recover the clock. At > the moment, the PLL is looking at the RRC outputs and saying,,,What is > this...I can't lock to that !! ! any help out there folks. > > Regards > Bob
As was pointed out, this could be a bug in the filter implementation or the taps themselves. Is your RRC designed to be driven by rectangular inputs? The standard textbook RRC impulse response formula obviously needs to be driven with impulses. John
On Feb 16, 7:55&#4294967295;am, John <sampson...@gmail.com> wrote:
> On Feb 15, 8:01 pm, Bob <sten...@yahoo.com> wrote: > > > > > > > Hi again, > > > I am working on a QPSK modulator and demodulator. Without pulse- > > shaping everything was fine and I was able to demodulate the > > transmitted data &#4294967295;However the spec says I have to use pulse shaping so > > I need someone to have a look at the screenshots and indicate whether > > they look correct or not. > > > This first attachment shows the I and Q data streams, passing them > > through a root raised cosine filter. Now does the output of the RRC > > filters look correct. I am not sure. Should the pulses out of the RRC > > be smoother? > > >http://i248.photobucket.com/albums/gg170/stenasc/RRc_pulses.jpg > > > This next link is what I am getting at the demodulator. The top three > > traces are the I channel data > > 1...The actual data being sent from the modulator > > 2...The received I channel data after being mixed with the recovered > > carrier (Note the inversion..is this correct) > > 3...The output from the RRC filter on the receiver I-channel > > (Again...does not look to be correct) > > > and similarly the bottom three are for the Q-channel > > >http://i248.photobucket.com/albums/gg170/stenasc/RX_Data.jpg > > > I have spent a lot of time at this and I'm getting nowhere. If the > > receiver RRC outputs are garbage, then I can't recover the clock. At > > the moment, the PLL is looking at the RRC outputs and saying,,,What is > > this...I can't lock to that !! ! any help out there folks. > > > Regards > > Bob > > As was pointed out, this could be a bug in the filter implementation > or the taps themselves. Is your RRC designed to be driven by > rectangular inputs? The standard textbook RRC impulse response formula > obviously needs to be driven with impulses. > > John- Hide quoted text - > > - Show quoted text -
I agree with John, you can use sinx/x correction in the filter design if you are going to drive it with rectangualr inputs instead of impulses. I disagree with the comment about ringing, a RRC will ring at near the sybol rate. The amount of ring will depend upon the ALPHA factor. The point of Nyquist filtering is that the ringing is such that the value of the ringing passes through zero at the symbol times to elimintate ISI. To the OP, what is the ALPHA factor in your system? Mark
[... snip  ]

>I agree with John, you can use sinx/x correction in the filter design
i>f you are going to drive it with rectangualr inputs instead of
> impulses.
Mark, can you point to reference or elaborate more on using the sinx/x correction when using retangular inputs? I've always seen sinx/x correction before a DAC. Can this be done with other pulse shapes? Thanks.
On Sat, 16 Feb 2008 15:23:37 -0500, "mx" <nospam@yahoo.com> wrote:

> >[... snip ] > >>I agree with John, you can use sinx/x correction in the filter design >i>f you are going to drive it with rectangualr inputs instead of >> impulses. > >Mark, can you point to reference or elaborate more on using the sinx/x >correction when using retangular inputs? I've always seen sinx/x >correction before a DAC. Can this be done with other pulse shapes? > >Thanks.
It's the same thing. The zero-order hold of the DAC creates the rectangular output shape, which is the same as using rectangular pulses (which can be thought of as impulses passed through a zero-order hold). Correcting the sinx/x response of the zero-order hold for the DAC is the same process as correcting the rectangular pulse shape of the input to a digital filter. Eric Jacobsen Minister of Algorithms Abineau Communications http://www.ericjacobsen.org
On 16 Feb, 19:07, Mark <makol...@yahoo.com> wrote:
> On Feb 16, 7:55&#4294967295;am, John <sampson...@gmail.com> wrote: > > > > > > > On Feb 15, 8:01 pm, Bob <sten...@yahoo.com> wrote: > > > > Hi again, > > > > I am working on a QPSK modulator and demodulator. Without pulse- > > > shaping everything was fine and I was able to demodulate the > > > transmitted data &#4294967295;However the spec says I have to use pulse shaping so > > > I need someone to have a look at the screenshots and indicate whether > > > they look correct or not. > > > > This first attachment shows the I and Q data streams, passing them > > > through a root raised cosine filter. Now does the output of the RRC > > > filters look correct. I am not sure. Should the pulses out of the RRC > > > be smoother? > > > >http://i248.photobucket.com/albums/gg170/stenasc/RRc_pulses.jpg > > > > This next link is what I am getting at the demodulator. The top three > > > traces are the I channel data > > > 1...The actual data being sent from the modulator > > > 2...The received I channel data after being mixed with the recovered > > > carrier (Note the inversion..is this correct) > > > 3...The output from the RRC filter on the receiver I-channel > > > (Again...does not look to be correct) > > > > and similarly the bottom three are for the Q-channel > > > >http://i248.photobucket.com/albums/gg170/stenasc/RX_Data.jpg > > > > I have spent a lot of time at this and I'm getting nowhere. If the > > > receiver RRC outputs are garbage, then I can't recover the clock. At > > > the moment, the PLL is looking at the RRC outputs and saying,,,What is > > > this...I can't lock to that !! ! any help out there folks. > > > > Regards > > > Bob > > > As was pointed out, this could be a bug in the filter implementation > > or the taps themselves. Is your RRC designed to be driven by > > rectangular inputs? The standard textbook RRC impulse response formula > > obviously needs to be driven with impulses. > > > John- Hide quoted text - > > > - Show quoted text - > > I agree with John, you can use sinx/x correction in the filter design > if you are going to drive it with rectangualr inputs instead of > impulses. > > I disagree with the comment about ringing, a RRC will ring at near the > sybol rate. &#4294967295;The amount of ring will depend upon the ALPHA factor. > The point of Nyquist filtering is that the ringing is such that the > value of the ringing passes through &#4294967295;zero at the symbol times to > elimintate ISI. > > To the OP, what is the ALPHA factor in your system? > > Mark- Hide quoted text - > > - Show quoted text -
Hi Mark, The alpha or roll-off factor is 0.25 With this in mind, are the RRC output from the modulator as expected? Bob
"Eric Jacobsen" <eric.jacobsen@ieee.org> wrote in message 
news:6oker3tnudsaoripv750b6bianef7m5onq@4ax.com...
> On Sat, 16 Feb 2008 15:23:37 -0500, "mx" <nospam@yahoo.com> wrote: > >> >>[... snip ] >> >>>I agree with John, you can use sinx/x correction in the filter design >>i>f you are going to drive it with rectangualr inputs instead of >>> impulses. >> >>Mark, can you point to reference or elaborate more on using the sinx/x >>correction when using retangular inputs? I've always seen sinx/x >>correction before a DAC. Can this be done with other pulse shapes? >> >>Thanks. > > It's the same thing. The zero-order hold of the DAC creates the > rectangular output shape, which is the same as using rectangular > pulses (which can be thought of as impulses passed through a > zero-order hold). Correcting the sinx/x response of the zero-order > hold for the DAC is the same process as correcting the rectangular > pulse shape of the input to a digital filter.
Eric, Thanks for the info. I've never really thought about in that way since I've always seen the filter get upsampled data rather then rectangular pulses. Is there any advantage to filtering the rectangular data vs upsampled data?
On Sun, 17 Feb 2008 01:42:16 -0500, "mx" <nospam@yahoo.com> wrote:

> >"Eric Jacobsen" <eric.jacobsen@ieee.org> wrote in message >news:6oker3tnudsaoripv750b6bianef7m5onq@4ax.com... >> On Sat, 16 Feb 2008 15:23:37 -0500, "mx" <nospam@yahoo.com> wrote: >> >>> >>>[... snip ] >>> >>>>I agree with John, you can use sinx/x correction in the filter design >>>i>f you are going to drive it with rectangualr inputs instead of >>>> impulses. >>> >>>Mark, can you point to reference or elaborate more on using the sinx/x >>>correction when using retangular inputs? I've always seen sinx/x >>>correction before a DAC. Can this be done with other pulse shapes? >>> >>>Thanks. >> >> It's the same thing. The zero-order hold of the DAC creates the >> rectangular output shape, which is the same as using rectangular >> pulses (which can be thought of as impulses passed through a >> zero-order hold). Correcting the sinx/x response of the zero-order >> hold for the DAC is the same process as correcting the rectangular >> pulse shape of the input to a digital filter. > >Eric, > >Thanks for the info. I've never really thought about in that way since I've >always seen the filter get upsampled data rather then rectangular pulses. >Is there any advantage to filtering the rectangular data vs upsampled data?
I think the differences are really implementation dependent. There can be advantages to using rectangular pulses (repetition) in the architecture, e.g., at clock boundaries if you can't or don't want to use pulse synchronization. For the most part, though, in my experience upsampling with filters is often easier and a bit more flexible. Depending on the system, though, the differences are probably not large. Eric Jacobsen Minister of Algorithms Abineau Communications http://www.ericjacobsen.org
On Feb 16, 5:32 pm, Bob <sten...@yahoo.com> wrote:
> On 16 Feb, 19:07, Mark <makol...@yahoo.com> wrote: > > > > > On Feb 16, 7:55 am, John <sampson...@gmail.com> wrote: > > > > On Feb 15, 8:01 pm, Bob <sten...@yahoo.com> wrote: > > > > > Hi again, > > > > > I am working on a QPSK modulator and demodulator. Without pulse- > > > > shaping everything was fine and I was able to demodulate the > > > > transmitted data However the spec says I have to use pulse shaping so > > > > I need someone to have a look at the screenshots and indicate whether > > > > they look correct or not. > > > > > This first attachment shows the I and Q data streams, passing them > > > > through a root raised cosine filter. Now does the output of the RRC > > > > filters look correct. I am not sure. Should the pulses out of the RRC > > > > be smoother? > > > > >http://i248.photobucket.com/albums/gg170/stenasc/RRc_pulses.jpg > > > > > This next link is what I am getting at the demodulator. The top three > > > > traces are the I channel data > > > > 1...The actual data being sent from the modulator > > > > 2...The received I channel data after being mixed with the recovered > > > > carrier (Note the inversion..is this correct) > > > > 3...The output from the RRC filter on the receiver I-channel > > > > (Again...does not look to be correct) > > > > > and similarly the bottom three are for the Q-channel > > > > >http://i248.photobucket.com/albums/gg170/stenasc/RX_Data.jpg > > > > > I have spent a lot of time at this and I'm getting nowhere. If the > > > > receiver RRC outputs are garbage, then I can't recover the clock. At > > > > the moment, the PLL is looking at the RRC outputs and saying,,,What is > > > > this...I can't lock to that !! ! any help out there folks. > > > > > Regards > > > > Bob > > > > As was pointed out, this could be a bug in the filter implementation > > > or the taps themselves. Is your RRC designed to be driven by > > > rectangular inputs? The standard textbook RRC impulse response formula > > > obviously needs to be driven with impulses. > > > > John- Hide quoted text - > > > > - Show quoted text - > > > I agree with John, you can use sinx/x correction in the filter design > > if you are going to drive it with rectangualr inputs instead of > > impulses. > > > I disagree with the comment about ringing, a RRC will ring at near the > > sybol rate. The amount of ring will depend upon the ALPHA factor. > > The point of Nyquist filtering is that the ringing is such that the > > value of the ringing passes through zero at the symbol times to > > elimintate ISI. > > > To the OP, what is the ALPHA factor in your system? > > > Mark- Hide quoted text - > > > - Show quoted text - > > Hi Mark, > > The alpha or roll-off factor is 0.25 With this in mind, are the RRC > output from the modulator as expected? > > Bob
Yes and No. Yes, if you have indeed put them through a RRC filter, No if you would like to bandlimit and recover the data easily. Questions for you i think, what is the time span of the RRC filter in relation to the symbol duration? If you can't answer that, then can you post the coefficients or at least the code/formula to generate your RRC filter coefficients? Once you get the RRC fixed, i think your problems will go away, but at the moment, it doesn't look right. col