Slow phase variation when using CMIX

I have 2 Lime SDR Mini’s V2.4. I am using them for NMR acquisition, so I want to down convert the IF down to “audio”, which I can do either using CMIX or via software. I have found however, that using CMIX results in a very slow phase variation over time which is worse at higher sampling rates. For example, if the rf sampling rate is 8 MHz, the phase varies approximately 360 degrees in approximately 15 minutes (of signal acquisition) - the phase I am talking about is the signal phase, so this could also be looked as as frequency variation. This phase variation does not appear to be random, and also does not appear to have a large dependence on the NCO frequency, although the frequencies I am using are in the low MHz range. It also behaves the same on both of the SDRs I have.

This is not a deal breaker - I do not need to use CMIX, as I can down convert in software, but I am curious as to what might be causing this? Or, maybe that is just what these devices do?

Any ideas are appreciated.

Thanks in advance

Tagging @Karolis for comment.

Are you taking into account that the mixing frequency is quantized? Given 8MHz and 15 minutes, that’s over 2^32 samples, so just a 1LSB quantization error on an NCO would be enough to put you off frequency.

LMS7002M NCO has a dithering parameter enabled by default, perhaps that is the source of what you’re seeing?

DTHBIT[3:0]: NCO bits to dither.
0000 – Dithering disabled
0001 – 1 bit dithering (default)
...

I guess I shouldn’t be surprised that this is indeed what causes it - when I set the dithering to zero in LimeSuiteGUI, the issue disappears - I also see how to set the appropriate parameter in my controlling program.
One other thing I am looking for is to change CMIX to operate in downconversion rather that up conversion. I can see how to do that in LimeSuiteGUI, but it would be really nice to set it inside the controlling program. Is this done by setting LMS7_MODE_RX?

Thank you so much for this information!

I found the parameter to set downconversion: LMS7_CMIX_SC_RXTSP, so that question can be ignored.

Thanks again for your help!

Great, note if you hover mouse over UI elements, they show what is the name and address of the parameter it’s controlling.
tooltip

Thanks for the tip!

It has been a bit since anything was posted here, but I do want to leave this note: the slow phase variation is removed ONLY if the NCO frequency differs from the sampling frequency by a power of 2. For example, if the NCO frequency is 1.8 MHz and the sampling frequency (with oversampling) is 28.8 MHz, then everything is fine. However, if the NCO frequency is 2.4 MHz with the same sampling rate, there is the same slow phase variation seen if the dither bit is not zero.
This pretty seriously limits the values that can be used for the NCO frequency if one does not want to see this effect.