[USRP-users] Re: Curious energy spikes from my X310

2025-05-24 Thread Nikos Balkanas
I got the chance to look into uhd's guts. My driver for the X300, x300_radio_control.cpp, uses get_tree() to set/get all its properties. This tree is maintained in RFNOC. I don't use it. I use Vivado. The path given for get_rx_lo_names db_path("rx", channel) didn't have any / "los" key in it. I gue

[USRP-users] Re: Curious energy spikes from my X310

2025-05-24 Thread Nikos Balkanas
Hi, Problem fixed:) It was easier than I thought. No patches needed:) The answer was in host/lib/types/tune.cpp always: tune_request_t::tune_request_t(double target_freq, double lo_off) .target_freq(target_freq) , rf_freq_policy(POLICY_MANUAL) , rf_freq(target_freq + lo_off) , dsp_freq_policy(PO

[USRP-users] Re: Curious energy spikes from my X310

2025-05-23 Thread Nikos Balkanas
Hi Marcus, I am aware of those. I wouldn't be doing all these if they were available to me:( You can check C API availability in usrp.h:) BR Nikos On Sat, May 24, 2025 at 12:33 AM Marcus D. Leech wrote: > On 2025-05-23 13:41, Nikos Balkanas wrote: > > Hi Rob, > > I've done all these, but they

[USRP-users] Re: Curious energy spikes from my X310

2025-05-23 Thread Marcus D. Leech
On 2025-05-23 13:41, Nikos Balkanas wrote: Hi Rob, I've done all these, but they do not affect LO offset. C API exports only these low level LO commands (in usrp.h) So, either I work it out with what I have, or I expand the C API to include the higher level C++ constructors. My luck. Both issues

[USRP-users] Re: Curious energy spikes from my X310

2025-05-23 Thread Rob Kossler via USRP-users
Hi Nikos, As I mentioned, I haven't tried the 'c' API. But, it sure looks to me like the 'c' API already supports what you need with the function 'uhd_set_rx_frequency' and the structure 'uhd_tune_request_t' which are both part of the 'c' API and are demonstrated (without LO offset) in the 'c' exa

[USRP-users] Re: Curious energy spikes from my X310

2025-05-23 Thread Nikos Balkanas
Hi Rob, I've done all these, but they do not affect LO offset. C API exports only these low level LO commands (in usrp.h) So, either I work it out with what I have, or I expand the C API to include the higher level C++ constructors. My luck. Both issues have to do with the C API:) Sampling rate is

[USRP-users] Re: Curious energy spikes from my X310

2025-05-23 Thread Rob Kossler via USRP-users
I forgot to mention, the function you were looking at 'uhd_usrp_set_rx_lo_freq' is not the function you need. This is a low-level function that is rarely needed. You will want to stay with the function 'uhd_usrp_set_rx_freq' which will send the appropriate command to the radio to set the LO and to

[USRP-users] Re: Curious energy spikes from my X310

2025-05-23 Thread Rob Kossler via USRP-users
Hi Nikos, Although I have not used the 'c' API, it appears it can do the same thing as the c++ API with regard to tune request. The 'c' structure uhd_tune_reqest_t includes a field called 'dsp_freq'. It s

[USRP-users] Re: Curious energy spikes from my X310

2025-05-23 Thread Nikos Balkanas
Ty Rob for the link and the suggestions, We agree completely. I need to offset my LO. You are probably not aware that I am using the C API. I cannot use the C++ constructors for tune_request unless they are exported as C API. I can just use the tune_request_t struct, which has no lo_off member. So

[USRP-users] Re: Curious energy spikes from my X310

2025-05-23 Thread Marcus D. Leech
On 2025-05-23 09:49, Rob Kossler wrote: Hi Nikos, Your RF card has 120 MHz bandwidth.  The strong tone you see will always be at the center.  But, if your application can tolerate using an instantaneous bandwidth < 60 MHz, you can use offset tuning as Marcus mentioned.  To do this you simply n

[USRP-users] Re: Curious energy spikes from my X310

2025-05-23 Thread Rob Kossler via USRP-users
Hi Nikos, Your RF card has 120 MHz bandwidth. The strong tone you see will always be at the center. But, if your application can tolerate using an instantaneous bandwidth < 60 MHz, you can use offset tuning as Marcus mentioned. To do this you simply need to create a tune request with your desire

[USRP-users] Re: Curious energy spikes from my X310

2025-05-23 Thread Nikos Balkanas
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 ((

[USRP-users] Re: Curious energy spikes from my X310

2025-05-22 Thread Nikos Balkanas
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 u

[USRP-users] Re: Curious energy spikes from my X310

2025-05-22 Thread Marcus D. Leech
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 t

[USRP-users] Re: Curious energy spikes from my X310

2025-05-22 Thread Nikos Balkanas
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? On Fri, May 23, 2025 at 3:19 AM