Re: [Discuss-gnuradio] pll_refout_cc - finding optimum alpha beta ??

2006-03-20 Thread Eric Blossom
On Fri, Mar 17, 2006 at 10:48:24AM -0800, Matt Ettus wrote: It just seeemd strange to me that a very large number, d_freq, which is bounds limited to between d_min_freq and d_max_freq, is inside a function trying to limit it's output to between +PI and -PI. if(100e3 M_PI)

Re: [Discuss-gnuradio] pll_refout_cc - finding optimum alpha beta ??

2006-03-20 Thread Eric Blossom
On Fri, Mar 17, 2006 at 11:06:00AM -0500, Charles Swiger wrote: On Thu, 2006-03-16 at 19:55 -0500, Robert McGwier wrote: phase is ALWAYS computed in an NCO by phase = phase + freq so this says that phase_new = (phase_old + GAIN_FOR_PHASE*measured-phase-err) + NewFrequency. SO

Re: [Discuss-gnuradio] pll_refout_cc - finding optimum alpha beta ??

2006-03-17 Thread Robert McGwier
Matt Ettus wrote: It just seeemd strange to me that a very large number, d_freq, which is bounds limited to between d_min_freq and d_max_freq, is inside a function trying to limit it's output to between +PI and -PI. if(100e3 M_PI) return(100e3-M_TWOPI) or 3.7168... error can get

Re: [Discuss-gnuradio] pll_refout_cc - finding optimum alpha beta ??

2006-03-17 Thread Charles Swiger
On Fri, 2006-03-17 at 10:16 -0800, Eric Blossom wrote: The function has the right name, mod_2pi, but the wrong implementation ;) These are commonly called bugs ;) Hence my comments above about doing the mod the right way. Roger that. Plowing right ahead with a hacked 1st order PLL filter,

Re: [Discuss-gnuradio] pll_refout_cc - finding optimum alpha beta ??

2006-03-17 Thread Charles Swiger
On Fri, 2006-03-17 at 14:46 -0500, Charles Swiger wrote: There must be a trivial way to change +7.5kHz to -7.5kHz so we can use complex mixing... Ah ha - it's invert either I or Q. c2f = gr.complex_to_float() phase1 = gr.multiply_const_ff(-1) phase2 = gr.multiply_const_ff(1) f2c =

Re: [Discuss-gnuradio] pll_refout_cc - finding optimum alpha beta ??

2006-03-17 Thread Charles Swiger
On Fri, 2006-03-17 at 15:02 -0800, [EMAIL PROTECTED] wrote: On Fri, Mar 17, 2006 at 05:32:20PM -0500, Charles Swiger wrote: On Fri, 2006-03-17 at 14:46 -0500, Charles Swiger wrote: There must be a trivial way to change +7.5kHz to -7.5kHz so we can use complex mixing... A

[Discuss-gnuradio] pll_refout_cc - finding optimum alpha beta ??

2006-03-16 Thread Charles Swiger
I'm looking for clues on the transfer function for gr.pll_refout_cc() as to how to find optimum values for alpha beta. Using experimental methods: http://webpages.charter.net/cswiger/pll/ ( script requires special versions of gr_pll_refout_cc.h,i ) Interesting how, as the input signal is

Re: [Discuss-gnuradio] pll_refout_cc - finding optimum alpha beta ??

2006-03-16 Thread Eric Blossom
On Thu, Mar 16, 2006 at 05:24:26PM -0500, Charles Swiger wrote: On Thu, 2006-03-16 at 12:35 -0800, Eric Blossom wrote: Chuck, I could have this totally wrong (the code definitely needs some comments), but it's a second order control loop. We're adjusting both the estimates of the phase

Re: [Discuss-gnuradio] pll_refout_cc - finding optimum alpha beta ??

2006-03-16 Thread Eric Blossom
On Thu, Mar 16, 2006 at 05:49:34PM -0500, Charles Swiger wrote: On Thu, 2006-03-16 at 14:39 -0800, Eric Blossom wrote: On Thu, Mar 16, 2006 at 05:24:26PM -0500, Charles Swiger wrote: On Thu, 2006-03-16 at 12:35 -0800, Eric Blossom wrote: Here's the only place they're used: