Hi all

I may be sticking my neck out here but I feel I may have notice some issues
in the source code of the wsprd lib in WSJT-X:

1) In wsprd_utils.c around line 131 I found this code:

        dlong=(ngrid/180)*2 - 180 + 2;
        if( dlong < -180 )
            dlong=dlong+360;
        if( dlong > 180 )
            dlong=dlong + 360;

Should the last line be dlong=dlong - 360; ?

2) In wisprd.c around line 1010 I found this code:

    // Smooth with 7-point window and limit spectrum to +/-150 Hz
    int window[7] = { 1, 1, 1, 1, 1, 1, 1 };
    float smspec[411];
    for( i = 0; i < 411; i++ )
    {
      smspec[i] = 0.0;
      for( j= -3; j <= 3; j++ )
      {
        k = 256 - 205 + i + j; //FIXME 256-205??
        smspec[i] = smspec[i] + window[j + 3] * psavg[k];
      }
    }

It seems to me that window[] has no effect in the last line since all elements
are 1 ?

3) In wsprd.c around line 1044 I found this code:

    for( j = 0; j < 411; j++ )
    {
      smspec[j] = smspec[j] / noise_level - 1.0;
      if( smspec[j] < min_snr) smspec[j] = 0.1 * min_snr;
      continue;
    }

I am just not sure what the last statement 'continue' does in the for loop.
Got a feeling (my own past experience) it came from FORTRAN source code
ported to C ?

One last request for help - in the rtlsdr_wsprd program, a CIC decimator is
used to reduce sampling rate from 2.4MHz to 375Hz. When porting some 
this code to an application I am working on, I have to modify the CIC code
for the sampling rate of 48kHz, much lower.

I do not know what changes will be needed, especially the z coefficients of
the FIR filter. Any hints on what I should change and how to calculate new
z coefficients?

My thanks in advance.

--
Best Regards
Neoklis - Ham Radio Call:5B4AZ
http://www.5b4az.org/
https://www.qsl.net/5b4az/index.html


_______________________________________________
wsjt-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/wsjt-devel

Reply via email to