DSPRelated.com
Forums

Qpsk Demodulator

Started by Eshwar varma March 12, 2015
On Tuesday, March 17, 2015 at 2:00:06 AM UTC+5:30, Evgeny Filatov wrote:
> On 16.03.2015 22:59, Evgeny Filatov wrote: > > On 16.03.2015 8:33, Eshwar varma wrote: > >> On Sunday, March 15, 2015 at 12:04:10 AM UTC+5:30, Tim Wescott wrote: > >>> On Fri, 13 Mar 2015 21:57:28 -0400, Randy Yates wrote: > >>> > >>>> Tim Wescott <seemywebsite@myfooter.really> writes: > >>>>> [...] > >>>>> The typical thing to do in a case like this is to divide and conquer. > >>>> > >>>> +1 +1 +1 +1 +1 +1 +1 ... > >>> > >>> Take the log, subtract, and conquer? > >>> > >>> -- > >>> www.wescottdesign.com > >> iam checking each block thoroughly , while iam checking coarse > >> frequency offset estimation i found the below problem . > >> Iam demodulating base band signal, the input signal will have > >> 2 samples per symbol ,In coarse frequency offset estimation (fft) ,to > >> estimate frequency i applied fft to the signal , as we have to remove > >> phase nonlinearities before fft i used mth power data modulation > >> removal technique ,so if i rise the signal to the 4th power(qpsk) with > >> only two samples per symbol i may get aliasing effect, so fft might > >> not estimate the correct. > >> > >> is there any other data modulation removal techniques. > >> > >> > > > > Yes. A good book is "Synchronization Techniques for Digital Receivers" > > by Mengali and D'Andrea. > > > > Basically, there are two different problems: one is to remove large > > frequency offsets on the order of ~100% of the symbol rate, the other is > > to remove small frequency offsets not exceeding ~10% of the symbol rate. > > > > If frequency offsets you deal with don't exceed 10% of the symbol rate, > > FFT-based method is fine. Typically the FFT-based method is discussed > > for the case of 1 sample per symbol, and in that case it's limited to > > +/- ~10% of the symbol rate. Since you have 2 samples per symbol you > > should get extended acquisition range (perhaps up to ~20% of the symbol > > rate, but I dunno), but at the penalty of worse minimum SNR required for > > the operation of your receiver. > > > > Evgeny. > > > > Actually as I started thinking about it, there's another problem with > using FFT-based method for 2 samples per symbol. It is intersymbol > interference, which is typically avoided when 1 sample per symbol is > used. Generally speaking, when using 2 samples per symbol for FFT, you > are in uncharted waters. Nobody knows what happens there. Technically > speaking you are even not guaranteed to get correct frequency estimates > with good SNR -- because of the intersymbol interference. > > The idea of the method is that you get 1 sample per symbol at the > maximum of the matched filter output (which implies you've already got > symbol synchronization by that point). To correctly use the method you > should do timing recovery before frequency offset estimation. > > Evgeny.
Thanks Evgeny for helping me in understanding the problem . For symbol timining recovery i used the method proposed by gardener . where it takes 2 samples per symbol and at output it gives only one samples per symbol , 1. so shall i place the CFO estimator ( fft based) after the symbol timing recovery? 2. And let say input signal has one sample per symbol and has symbol synchronization before applying to CFo estimator (fft) .As i said i raised input signal to the power four i.e i get a signal at 4F before applying FFT. So with only one sample per symbol and raising it to 4f will there be any aliasing affect?
On Tuesday, March 17, 2015 at 2:00:06 AM UTC+5:30, Evgeny Filatov wrote:
> On 16.03.2015 22:59, Evgeny Filatov wrote: > > On 16.03.2015 8:33, Eshwar varma wrote: > >> On Sunday, March 15, 2015 at 12:04:10 AM UTC+5:30, Tim Wescott wrote: > >>> On Fri, 13 Mar 2015 21:57:28 -0400, Randy Yates wrote: > >>> > >>>> Tim Wescott <seemywebsite@myfooter.really> writes: > >>>>> [...] > >>>>> The typical thing to do in a case like this is to divide and conquer. > >>>> > >>>> +1 +1 +1 +1 +1 +1 +1 ... > >>> > >>> Take the log, subtract, and conquer? > >>> > >>> -- > >>> www.wescottdesign.com > >> iam checking each block thoroughly , while iam checking coarse > >> frequency offset estimation i found the below problem . > >> Iam demodulating base band signal, the input signal will have > >> 2 samples per symbol ,In coarse frequency offset estimation (fft) ,to > >> estimate frequency i applied fft to the signal , as we have to remove > >> phase nonlinearities before fft i used mth power data modulation > >> removal technique ,so if i rise the signal to the 4th power(qpsk) with > >> only two samples per symbol i may get aliasing effect, so fft might > >> not estimate the correct. > >> > >> is there any other data modulation removal techniques. > >> > >> > > > > Yes. A good book is "Synchronization Techniques for Digital Receivers" > > by Mengali and D'Andrea. > > > > Basically, there are two different problems: one is to remove large > > frequency offsets on the order of ~100% of the symbol rate, the other is > > to remove small frequency offsets not exceeding ~10% of the symbol rate. > > > > If frequency offsets you deal with don't exceed 10% of the symbol rate, > > FFT-based method is fine. Typically the FFT-based method is discussed > > for the case of 1 sample per symbol, and in that case it's limited to > > +/- ~10% of the symbol rate. Since you have 2 samples per symbol you > > should get extended acquisition range (perhaps up to ~20% of the symbol > > rate, but I dunno), but at the penalty of worse minimum SNR required for > > the operation of your receiver. > > > > Evgeny. > > > > Actually as I started thinking about it, there's another problem with > using FFT-based method for 2 samples per symbol. It is intersymbol > interference, which is typically avoided when 1 sample per symbol is > used. Generally speaking, when using 2 samples per symbol for FFT, you > are in uncharted waters. Nobody knows what happens there. Technically > speaking you are even not guaranteed to get correct frequency estimates > with good SNR -- because of the intersymbol interference. > > The idea of the method is that you get 1 sample per symbol at the > maximum of the matched filter output (which implies you've already got > symbol synchronization by that point). To correctly use the method you > should do timing recovery before frequency offset estimation. > > Evgeny.
Thanks Evgeny for helping me in understanding the problem . For symbol timining recovery i used the method proposed by gardener . where it takes 2 samples per symbol and at output it gives only one sample per symbol , 1. so shall i place the CFO estimator ( fft based) after the symbol timing recovery? 2. And let say input signal has one sample per symbol and has symbol synchronization before applying to CFo estimator (fft) .As i said i raised input signal to the power four i.e i get a signal at 4F before applying FFT. So with only one sample per symbol and raising it to 4f will there be any aliasing affect?
On 17.03.2015 10:01, Eshwar varma wrote:
> On Tuesday, March 17, 2015 at 2:00:06 AM UTC+5:30, Evgeny Filatov wrote: >> On 16.03.2015 22:59, Evgeny Filatov wrote: >>> On 16.03.2015 8:33, Eshwar varma wrote: >>>> On Sunday, March 15, 2015 at 12:04:10 AM UTC+5:30, Tim Wescott wrote: >>>>> On Fri, 13 Mar 2015 21:57:28 -0400, Randy Yates wrote: >>>>> >>>>>> Tim Wescott <seemywebsite@myfooter.really> writes: >>>>>>> [...] >>>>>>> The typical thing to do in a case like this is to divide and conquer. >>>>>> >>>>>> +1 +1 +1 +1 +1 +1 +1 ... >>>>> >>>>> Take the log, subtract, and conquer? >>>>> >>>>> -- >>>>> www.wescottdesign.com >>>> iam checking each block thoroughly , while iam checking coarse >>>> frequency offset estimation i found the below problem . >>>> Iam demodulating base band signal, the input signal will have >>>> 2 samples per symbol ,In coarse frequency offset estimation (fft) ,to >>>> estimate frequency i applied fft to the signal , as we have to remove >>>> phase nonlinearities before fft i used mth power data modulation >>>> removal technique ,so if i rise the signal to the 4th power(qpsk) with >>>> only two samples per symbol i may get aliasing effect, so fft might >>>> not estimate the correct. >>>> >>>> is there any other data modulation removal techniques. >>>> >>>> >>> >>> Yes. A good book is "Synchronization Techniques for Digital Receivers" >>> by Mengali and D'Andrea. >>> >>> Basically, there are two different problems: one is to remove large >>> frequency offsets on the order of ~100% of the symbol rate, the other is >>> to remove small frequency offsets not exceeding ~10% of the symbol rate. >>> >>> If frequency offsets you deal with don't exceed 10% of the symbol rate, >>> FFT-based method is fine. Typically the FFT-based method is discussed >>> for the case of 1 sample per symbol, and in that case it's limited to >>> +/- ~10% of the symbol rate. Since you have 2 samples per symbol you >>> should get extended acquisition range (perhaps up to ~20% of the symbol >>> rate, but I dunno), but at the penalty of worse minimum SNR required for >>> the operation of your receiver. >>> >>> Evgeny. >>> >> >> Actually as I started thinking about it, there's another problem with >> using FFT-based method for 2 samples per symbol. It is intersymbol >> interference, which is typically avoided when 1 sample per symbol is >> used. Generally speaking, when using 2 samples per symbol for FFT, you >> are in uncharted waters. Nobody knows what happens there. Technically >> speaking you are even not guaranteed to get correct frequency estimates >> with good SNR -- because of the intersymbol interference. >> >> The idea of the method is that you get 1 sample per symbol at the >> maximum of the matched filter output (which implies you've already got >> symbol synchronization by that point). To correctly use the method you >> should do timing recovery before frequency offset estimation. >> >> Evgeny. > > Thanks Evengy for helping me in understanding the problem . > > For symbol timining recovery i used the method proposed by gardener . where it takes 2 samples per symbol and at output it gives only one samples per symbol , > 1. so shall i place the CFO estimator ( fft based) after the symbol timing recovery? > 2. And let say input signal has one sample per symbol and has symbol synchronization before applying to CFo estimator (fft) .As i said i raised input signal to the power four i.e i get a signal at 4F before applying FFT. > So with only one sample per symbol and raising it to 4f will there be any aliasing affect? >
Eshwar, you are welcome. 1. Yes. To quote the "Synchronization Techniques", page 80: "Actually, good clock recovery is possible even with frequency errors as large as 20% of the symbol rate". The idea is that if you have frequency error larger than ~0.1 of the symbol rate you need to compensate for it first, then proceed with symbol synchronization and correcting small residual frequency errors. 2. Yes, there will be aliasing effect. That's why the FFT-based method is hard-limited to +- 0.5 / 4 = 0.125 of the symbol rate for QPSK modulation. If you have, say, frequency offset of 0.15 of the symbol rate you will get the wrong result (namely, 0.25-0.15 = 0.10 of the symbol rate). There are other methods to estimate frequency offsets on the order of the symbol rate. With two samples per symbol you won't have a lot of freedom there, depending on the roll-off factor if the received signal has root-raised cosine shape. With the roll-off factor of e.g. 0.3 you could compensate for frequency offsets up to 1 - (1+0.3)/2 = 0.35 of the symbol rate, which is certainly an improvement. While selecting one of the methods for estimating large frequency offsets, you need to choose between (1) feedback and (2) feedforward methods. I really recommend you to read Chapter 3 of the "Synchronization Techniques". Optionally, a couple of good articles. For feedback methods: Karam, Jeanclaude, Sari, "A Reduced-Complexity Frequency Detector Derived from the Maximum-Likelihood Principle" (1995). For feedforward methods: Arias-de-Reyna, Acha-Catalina "Non-Data-Aided and Non-Timing-Directed Feedforward Frequency Acquisition for Linear Digital Modulations" (2005). Hope it helps. Evgeny.
On Thursday, March 12, 2015 at 4:59:41 PM UTC+5:30, Eshwar varma wrote:
> I implemented a qpsk demodulator on NI fpga . When i run the code iam getting correct constellation one out of 4 succesive runs remaining times constellation is rotating as shown in fig url: https://decibel.ni.com/content/servlet/JiveServlet/showImage/105-32337-135325/Constellation.jpg . > > q1. what are the possible causes for constellation rotation?
sorry Tim , evgeny , Eric It took nearly 5 days to change the code as suggested by you . Bad news is constellation rotation problem is there . As Evgeny said i placed Cfo estimator (FFT Based) after the Timing sync . I uploaded the results in 4shared LINK:http://www.4shared.com/folder/ZxDoY_DI/_online.html Most of the times constellation is showing some fixed points as you seen in screen shots.
On Tue, 24 Mar 2015 05:55:29 -0700, Eshwar varma wrote:

> On Thursday, March 12, 2015 at 4:59:41 PM UTC+5:30, Eshwar varma wrote: >> I implemented a qpsk demodulator on NI fpga . When i run the code iam >> getting correct constellation one out of 4 succesive runs remaining >> times constellation is rotating as shown in fig url: >> https://decibel.ni.com/content/servlet/JiveServlet/
showImage/105-32337-135325/Constellation.jpg
>> . >> >> q1. what are the possible causes for constellation rotation? > > sorry Tim , evgeny , Eric It took nearly 5 days to change the code as > suggested by you . Bad news is constellation rotation problem is there . > > As Evgeny said i placed Cfo estimator (FFT Based) after the Timing sync > . > > I uploaded the results in 4shared > LINK:http://www.4shared.com/folder/ZxDoY_DI/_online.html > > Most of the times constellation is showing some fixed points as you seen > in screen shots.
I'm not sure what I'm supposed to be seeing. The clip titled VID_20150320_152851.mp4 seems to show a constellation that's rotating madly and then locking where it should. If I were doing this, and meeting with such a lack of progress as you seem to be, I would break things down more. I'd start by generating a known signal with a known carrier frequency, and see if I could phase lock to that using the fine lock only. Assuming that the fine lock algorithm uses an integrating loop filter, I'd investigate how wide of a frequency range the fine lock algorithm could handle (it depends on the integrator gain, which is subject to SNR vs. lock range tradeoffs). Once I was happy with the fine lock loop, then I'd move on to the coarse lock -- but here again, I'd start with one or more synthesized signal(s) of known frequency, and see what results I got. Sometimes you just get snarled up in these problems, and what should be a day hike turns into saga involving cliffs and rapids and bears and all that fun stuff. It's just part of engineering. -- Tim Wescott Wescott Design Services http://www.wescottdesign.com
On 24.03.2015 15:55, Eshwar varma wrote:
> On Thursday, March 12, 2015 at 4:59:41 PM UTC+5:30, Eshwar varma wrote: >> I implemented a qpsk demodulator on NI fpga . When i run the code iam getting correct constellation one out of 4 succesive runs remaining times constellation is rotating as shown in fig url: https://decibel.ni.com/content/servlet/JiveServlet/showImage/105-32337-135325/Constellation.jpg . >> >> q1. what are the possible causes for constellation rotation? > > sorry Tim , evgeny , Eric It took nearly 5 days to change the code as suggested by you . Bad news is constellation rotation problem is there . > > As Evgeny said i placed Cfo estimator (FFT Based) after the Timing sync . > > I uploaded the results in 4shared LINK:http://www.4shared.com/folder/ZxDoY_DI/_online.html > > Most of the times constellation is showing some fixed points as you seen in screen shots. >
Eshwar, Tim gave you a lot of good advice. Actually, with QPSK demodulation phaselock is often the "weak link". What you are seeing _might_ be a false lock. That is PLL locking to a frequency other than the true carrier frequency. Usually false lock is avoided when the acquisition range of your PLL is larger than the initial frequency error. There you face a dilemma, since wideband loop filter is preferable for the acquisition, while narrowband loop filter is better for tracking. Once you are confident with the work of your PLL, you might consider the following enhancement. A way to avoid false locks when working with a narrowband loop filter is to use an FLL-assisted PLL. A clever trick is to replace the phase detector with a phase-frequency detector, which detects _both_ phase and frequency errors. The technique is described in the 1988 article "New Phase and Frequency Detectors for Carrier Recovery in PSK and QAM Systems" by Sari and Moridi. I think there's some inherent humor in that schematics suggested 27 years ago still have a "new" look. Evgeny.
On Tue, 24 Mar 2015 05:55:29 -0700 (PDT), Eshwar varma
<eshwar93.india@gmail.com> wrote:

>On Thursday, March 12, 2015 at 4:59:41 PM UTC+5:30, Eshwar varma wrote: >> I implemented a qpsk demodulator on NI fpga . When i run the code iam get= >ting correct constellation one out of 4 succesive runs remaining times con= >stellation is rotating as shown in fig url: https://decibel.ni.com/content/= >servlet/JiveServlet/showImage/105-32337-135325/Constellation.jpg . >>=20 >> q1. what are the possible causes for constellation rotation? > >sorry Tim , evgeny , Eric It took nearly 5 days to change the code as sugge= >sted by you . Bad news is constellation rotation problem is there . > >As Evgeny said i placed Cfo estimator (FFT Based) after the Timing sync .= >=20 > >I uploaded the results in 4shared LINK:http://www.4shared.com/folder/ZxDoY= >_DI/_online.html > >Most of the times constellation is showing some fixed points as you seen in= > screen shots. >
I can't see the file you linked. I get a "The file you requested is not valid.", and then the fake Adobe Flash upgrade malware pop-up. I think Tim and Evgeny both gave good input. My only other input would be to look at the signal in the time domain and see what it's doing. Whether it is properly acquiring the signal and then unlocking, or pushing away and false locking, or whatever, is often discernible by looking at the captured trace of the signal in the time domain. And looking at some other things at the same time, like what's in the PLL loop integrator (which is proportional to the frequency offset the loop is trying to compensate), can also be helpful. Eric Jacobsen Anchor Hill Communications http://www.anchorhill.com --- This email has been checked for viruses by Avast antivirus software. http://www.avast.com