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 <bpadal...@gmail.com> wrote:

> On Tue, Jul 30, 2013 at 5:55 PM, Andrew Davis <glneolistm...@gmail.com>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
>
_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
https://lists.gnu.org/mailman/listinfo/discuss-gnuradio

Reply via email to