I have implemented the following calls for uhd_usrp_set_rx_lo_freq: uhd_string_vector_handle names; uhd_string_vector_make(&names); if ((err = uhd_usrp_get_rx_lo_names(dev[channel], channel, &names))) warn(log, "Failed to get lo names (%d). %s.\n", 0, FL, LN, FN, err, uhdError(err)); if ((err = uhd_string_vector_size(names, &len))) warn(log, "Failed to get lo names size (%d). %s.\n",0,FL,LN,FN,err, uhdError(err)); if (!len) { error(log, "No lo names found on channel %d.\n", 0, FL, LN, FN, channel); uhd_string_vector_free(&names); return(FAIL); } uhd_string_vector_free(&names);
The problem is that names always returns 0. This is not right for my SBX-120, or any daughterboard with a tuner:( This is what i can get from the API. There are no LO examples. I have seen lo_enable() in c++, but nothing exported to C. What am I missing? TIA Nikos On Fri, May 23, 2025 at 8:12 AM Nikos Balkanas <nbalka...@gmail.com> wrote: > Thx Marcus, > > For your fast and informative answers. Sorry it took me a while to reply, > but I'm still trying to get: > tune_request(freq, lo_off) > to work in C. > My X310 has 2 SBX-120 boards. Using uhd 4.6.0 in Ubuntu 24.04. > True about the tuner. Much cheaper and easier to implement it in analog. > I am using your FPGA image. Haven't touched it myself, yet. > So, the spike is pretty narrow to interfere with my signals, but still > messes my power calculations:( > I already implemented the integer frequency tuner and working on the low > oscillator offset. > If you have any pointers about it, feel free to advise. > LO is not part of the request_tuner_t struct. It is set independently. > Is this the same LO in uhd_usrp_set_rx_lo_freq? > If this is the case I can modify it externally:) > > BR > Nikos > > On Fri, May 23, 2025 at 4:40 AM Marcus D. Leech <patchvonbr...@gmail.com> > wrote: > >> On 2025-05-22 21:31, Nikos Balkanas wrote: >> >> The spike is very clean to come from outside. >> Must be from my X310. My tuner must be adding a signal to the >> center frequency. The small artifact at 2 Ghz is probably the tuner not >> equilibrating fully. >> I recently updated my FPGA image. Is that where the tuner lives? >> >> You haven't mentioned in this thread which daughtercard you're using. >> RF front-ends that use complex-baseband >> downconversion suffer from something called "DC-offset", which produces >> a spike at 0Hz in the complex spectrum. >> The radio block in the standard FPGAs has methods for reducing this, >> unless you turn it off. This is a very very >> *normal* thing for complex-baseband receiver chains. >> >> If the algorithms are engaged and working, then there'll still be a >> central spike, but *considerably* reduced, and I find that >> said spike is usually swamped by external signals, even in radio >> astronomy. >> >> The other method that people use is to use "offset tuning". Where the >> tuner is tuned to a different RF frequency, and the >> DDC brings your signal of interest down to 0Hz. >> >> https://files.ettus.com/manual/page_general.html#general_tuning >> >> The "tuner" is an analog collection of components, including an LO >> generator, and mixers. While it is *controlled* through >> the FPGA, it is an analog subsystem. >> >> >> >> On Fri, May 23, 2025 at 3:19 AM Nikos Balkanas <nbalka...@gmail.com> >> wrote: >> >>> Hello, >>> >>> Whenever I look at my spectrum I always see an energy spike at the >>> center frequency. >>> In the first image you can see a spike at 2, but not at 2.001 Ghz. In >>> the next image, >>> at 2.001 Ghz you can see the energy spike at the center frequency, but >>> also a small >>> spike at 2 Ghz. >>> I have verified these results by both fosphor (OpenCL fft) and fftw3f. >>> Besides, if it were >>> an fft artifact, why is the spike at 2 Ghz still visible after a few >>> mins? These spikes >>> seem to be transient, but real. In that part of the spectrum, you there >>> is no traffic. Could it be harmonics from my power supply? Problems with >>> my X-310? My transmitter >>> doing funny things (I have 2 boards and not enabling my transmitter >>> anywhere)? >>> Naming of images is freq_sr.jpg. All are in Mhz. >>> >>> TIA >>> Nikos >>> >> >> _______________________________________________ >> USRP-users mailing list -- usrp-users@lists.ettus.com >> To unsubscribe send an email to usrp-users-le...@lists.ettus.com >> >> >> _______________________________________________ >> USRP-users mailing list -- usrp-users@lists.ettus.com >> To unsubscribe send an email to usrp-users-le...@lists.ettus.com >> >
_______________________________________________ USRP-users mailing list -- usrp-users@lists.ettus.com To unsubscribe send an email to usrp-users-le...@lists.ettus.com