discuss-gnuradio
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Discuss-gnuradio] ATSC Magic coupling constant


From: Andrew Davis
Subject: Re: [Discuss-gnuradio] ATSC Magic coupling constant
Date: Tue, 30 Jul 2013 19:28:04 -0400

The filter doesn't seem to decrease the pass-band signal, also I've tried adding back the unneeded filter just to be sure and it doesn't change anything. I will try the off by sqrt(2), that might put me back in range. Also my NCO is the same in both cases and I believe it is normalized to 1.

The ATSC signal randomly changes between +/- 1,3,5,7 so the average power should be 4 and when using this as the reference this puts my signal were it should be and at the same level as the old code with the average power set to 7.8125 ( written in code as 2.5 * 3.125 for some reason ) yet it still must be off by just enough to mess up the slicer in the viterbi but not the equalizer as it locks on correctly ( it is very finicky ).

Thanks for the idea, I will try it tomorrow when I get back to the test machine ( which is powerful enough to be within reach of real-time decoding if I get this figured out :)
Andrew


On Tue, Jul 30, 2013 at 6:19 PM, Brian Padalino <address@hidden> wrote:
On Tue, Jul 30, 2013 at 5:55 PM, Andrew Davis <address@hidden> wrote:
Hello all,

I'm working on fixing up gr-atsc and I have been working on a little problem for a while now, there is a constant ( FPLL_BTLOOP_COUPLING_CONST ) that sets the reference for an AGC, the value is ( 2.5 * 3.125 ) and is literally defined as "Magic", so it seems to be a value that "just works". With that value the AGC filters the real input and then this is multiplied by a NCO part of a PLL. This puts the value of the +/- 5 timing sync levels at about +/- 5. The problem is when I pass samples though the AGC and then do 'complex' multiplication on them the +/- 5 values end up at about +/- 7. I'm not sure why but it seems like the values coming out of the complex multiply are not the same as the real multiply. The original code is: 

nco.sincos (&a_sin, &a_cos);  // compute cos and sin
float I = input * a_sin;
float Q = input * a_cos;

My code is:

nco.sincos (&a_sin, &a_cos); // compute cos and sin
gr_complex result = (gr_complex(input_real, input_imag) * gr_complex(a_cos, a_sin));
float I = result.real();
float Q = result.imag();

I is larger in my version and so the equalizer and slicer fail downstream. I built a coherent AGC into the sync timing loop but it still fails with large gain differences. 

My question is whether there is anyone around who worked on gr-atsc who could give me a hint as to how the "Magic coupling constant" was derived in the first place so I can build a new one so I don't have to rebuild the equilizer.

I can't help you with your MAGIC, but if you say the real signal is mixed then filtered in the original code that works, whereas it is just mixed with your code - maybe it's just off by a sqrt(2) since you're filtering off your image after the NCO happens and losing 1/2 power?

I did notice that sqrt(2)*5 = 7 - so maybe making your NCO a little less powerful might bring you to the correct power levels since I am assuming you aren't filtering in your chain since there is no image to filter out?

Brian


reply via email to

[Prev in Thread] Current Thread [Next in Thread]