LimeSDR with external reference - [solved]

Hi all!

Is anyone using a LimeSDR with external reference clock?
I would like to use my Lime with the external LBE-1420 GPSDO with a v1.9.3 station, but
I could not find a parameter in the interface for switching reference to extern,
but maybe there is a workaround for passing settings to the Lime directly?

73 de Stefan/OE6ISP

I don’t have one, but at least it looks like it is supported in the code.

Maybe try device setting clock_source=external, I’m not sure if it goes in the SATNOGS_DEV_ARGS or SATNOGS_OTHER_SETTINGS as it differs between the sdr and soapy implementations.

Some does support this directly in the SATNOGS_SOAPY_RX_DEVICE like appending to the device name, like device=lime,clock_source=external

1 Like

Hi, I have a LimeSDR MINI 2.0. I needed to de-solder a 0 Ohm resistor and install it a different spot to get the external clock input to be used. It expected 40MHz, So I just set the LeoBodnar GPSDO to 40MHz.

I found that the onboard oscillator of the Lime is not bad, but a GPSDO improves it a lot of course!

1 Like

My attempts to switch to extern ref in soapysdr were not successful, but I found a workaround. When I set ref to extern in sdrconsole and then plug the lime to the pi4 without powering off, according to the onboard-leds it keeps the extern-setting. Even though the log shows ref-clock would be 30.72Mhz it appears to actually run on the external 10MHz. This needs to be verified now using an exact reference.

What is the output from SoapySDRUtil --probe="driver=lime" ?

######################################################

Soapy SDR – the SDR abstraction library

######################################################

Probe device driver=lime
[INFO] Make connection: ‘LimeSDR-USB [USB 2.0] 90726074D061D’
[INFO] Reference clock 30.72 MHz
[INFO] Device name: LimeSDR-USB
[INFO] Reference: 30.72 MHz
[INFO] LMS7002M register cache: Disabled


– Device identification

driver=FX3
hardware=LimeSDR-USB
boardSerialNumber=0x90726074d061d
firmwareVersion=4
gatewareVersion=2.23
hardwareVersion=4
protocolVersion=1


– Peripheral summary

Channels: 2 Rx, 2 Tx
Timestamps: YES
Sensors: clock_locked, lms7_temp
Registers: BBIC, RFIC0
Other Settings:
* SAVE_CONFIG - Save LMS settings to file
[key=SAVE_CONFIG, type=string]
* LOAD_CONFIG - Load LMS settings from file
[key=LOAD_CONFIG, type=string]
* OVERSAMPLING - oversampling ratio (0 - auto)
[key=OVERSAMPLING, type=int, options=(0, 1, 2, 4, 8, 16, 32)]
GPIOs: MAIN


– RX Channel 0

Full-duplex: YES
Supports AGC: NO
Stream formats: CF32, CS12, CS16
Native format: CS16 [full-scale=32767]
Stream args:
* Buffer Length - The buffer transfer size over the link.
[key=bufferLength, units=samples, default=0, type=int]
* Link Format - The format of the samples over the link.
[key=linkFormat, default=CS16, type=string, options=(CS16, CS12)]
* Skip Calibration - Skip automatic activation calibration.
[key=skipCal, default=false, type=bool]
* align phase - Attempt to align phase of Rx channels.
[key=alignPhase, default=false, type=bool]
Antennas: NONE, LNAH, LNAL, LNAW, LB1, LB2
Corrections: DC removal, DC offset, IQ balance
Full gain range: [-12, 61] dB
TIA gain range: [0, 12] dB
LNA gain range: [0, 30] dB
PGA gain range: [-12, 19] dB
Full freq range: [0, 3800] MHz
RF freq range: [30, 3800] MHz
BB freq range: [-10, 10] MHz
Tune args:
* LO Offset - Tune the LO with an offset and compensate with the baseband CORDIC.
[key=OFFSET, units=Hz, default=0.0, type=float, range=[-1e+07, 1e+07]]
* BB - Specify a specific value for this component or IGNORE to skip tuning it.
[key=BB, units=Hz, default=DEFAULT, type=float, range=[-1e+07, 1e+07], options=(DEFAULT, IGNORE)]
Sample rates: [0.1, 61.44] MSps
Filter bandwidths: [1.4001, 130] MHz
Sensors: lo_locked
Other Settings:
* TSP_CONST - Digital DC test signal level in LMS7002M TSP chain.
[key=TSP_CONST, default=16383, type=int, range=[0, 32767]]
* CALIBRATE - DC/IQ calibration bandwidth
[key=CALIBRATE, type=float, range=[2.5e+06, 1.2e+08]]
* ENABLE_GFIR_LPF - LPF bandwidth (must be set after sample rate)
[key=ENABLE_GFIR_LPF, type=float]
* TSG_NCO - Enable NCO test signal
[key=TSG_NCO, default=4, type=int, options=(-1, 4, 8)]


– RX Channel 1

Full-duplex: YES
Supports AGC: NO
Stream formats: CF32, CS12, CS16
Native format: CS16 [full-scale=32767]
Stream args:
* Buffer Length - The buffer transfer size over the link.
[key=bufferLength, units=samples, default=0, type=int]
* Link Format - The format of the samples over the link.
[key=linkFormat, default=CS16, type=string, options=(CS16, CS12)]
* Skip Calibration - Skip automatic activation calibration.
[key=skipCal, default=false, type=bool]
* align phase - Attempt to align phase of Rx channels.
[key=alignPhase, default=false, type=bool]
Antennas: NONE, LNAH, LNAL, LNAW, LB1, LB2
Corrections: DC removal, DC offset, IQ balance
Full gain range: [-12, 61] dB
TIA gain range: [0, 12] dB
LNA gain range: [0, 30] dB
PGA gain range: [-12, 19] dB
Full freq range: [0, 3800] MHz
RF freq range: [30, 3800] MHz
BB freq range: [-10, 10] MHz
Tune args:
* LO Offset - Tune the LO with an offset and compensate with the baseband CORDIC.
[key=OFFSET, units=Hz, default=0.0, type=float, range=[-1e+07, 1e+07]]
* BB - Specify a specific value for this component or IGNORE to skip tuning it.
[key=BB, units=Hz, default=DEFAULT, type=float, range=[-1e+07, 1e+07], options=(DEFAULT, IGNORE)]
Sample rates: [0.1, 61.44] MSps
Filter bandwidths: [1.4001, 130] MHz
Sensors: lo_locked
Other Settings:
* TSP_CONST - Digital DC test signal level in LMS7002M TSP chain.
[key=TSP_CONST, default=16383, type=int, range=[0, 32767]]
* CALIBRATE - DC/IQ calibration bandwidth
[key=CALIBRATE, type=float, range=[2.5e+06, 1.2e+08]]
* ENABLE_GFIR_LPF - LPF bandwidth (must be set after sample rate)
[key=ENABLE_GFIR_LPF, type=float]
* TSG_NCO - Enable NCO test signal
[key=TSG_NCO, default=4, type=int, options=(-1, 4, 8)]


– TX Channel 0

Full-duplex: YES
Supports AGC: NO
Stream formats: CF32, CS12, CS16
Native format: CS16 [full-scale=32767]
Stream args:
* Buffer Length - The buffer transfer size over the link.
[key=bufferLength, units=samples, default=0, type=int]
* Link Format - The format of the samples over the link.
[key=linkFormat, default=CS16, type=string, options=(CS16, CS12)]
* Skip Calibration - Skip automatic activation calibration.
[key=skipCal, default=false, type=bool]
* align phase - Attempt to align phase of Rx channels.
[key=alignPhase, default=false, type=bool]
Antennas: NONE, BAND1, BAND2
Corrections: DC offset, IQ balance
Full gain range: [-12, 64] dB
PAD gain range: [0, 52] dB
IAMP gain range: [-12, 12] dB
Full freq range: [0, 3800] MHz
RF freq range: [30, 3800] MHz
BB freq range: [-10, 10] MHz
Tune args:
* LO Offset - Tune the LO with an offset and compensate with the baseband CORDIC.
[key=OFFSET, units=Hz, default=0.0, type=float, range=[-1e+07, 1e+07]]
* BB - Specify a specific value for this component or IGNORE to skip tuning it.
[key=BB, units=Hz, default=DEFAULT, type=float, range=[-1e+07, 1e+07], options=(DEFAULT, IGNORE)]
Sample rates: [0.1, 61.44] MSps
Filter bandwidths: [5, 40], [50, 130] MHz
Sensors: lo_locked
Other Settings:
* TSP_CONST - Digital DC test signal level in LMS7002M TSP chain.
[key=TSP_CONST, default=16383, type=int, range=[0, 32767]]
* CALIBRATE - DC/IQ calibration bandwidth
[key=CALIBRATE, type=float, range=[2.5e+06, 1.2e+08]]
* ENABLE_GFIR_LPF - LPF bandwidth (must be set after sample rate)
[key=ENABLE_GFIR_LPF, type=float]
* TSG_NCO - Enable NCO test signal
[key=TSG_NCO, default=4, type=int, options=(-1, 4, 8)]


– TX Channel 1

Full-duplex: YES
Supports AGC: NO
Stream formats: CF32, CS12, CS16
Native format: CS16 [full-scale=32767]
Stream args:
* Buffer Length - The buffer transfer size over the link.
[key=bufferLength, units=samples, default=0, type=int]
* Link Format - The format of the samples over the link.
[key=linkFormat, default=CS16, type=string, options=(CS16, CS12)]
* Skip Calibration - Skip automatic activation calibration.
[key=skipCal, default=false, type=bool]
* align phase - Attempt to align phase of Rx channels.
[key=alignPhase, default=false, type=bool]
Antennas: NONE, BAND1, BAND2
Corrections: DC offset, IQ balance
Full gain range: [-12, 64] dB
PAD gain range: [0, 52] dB
IAMP gain range: [-12, 12] dB
Full freq range: [0, 3800] MHz
RF freq range: [30, 3800] MHz
BB freq range: [-10, 10] MHz
Tune args:
* LO Offset - Tune the LO with an offset and compensate with the baseband CORDIC.
[key=OFFSET, units=Hz, default=0.0, type=float, range=[-1e+07, 1e+07]]
* BB - Specify a specific value for this component or IGNORE to skip tuning it.
[key=BB, units=Hz, default=DEFAULT, type=float, range=[-1e+07, 1e+07], options=(DEFAULT, IGNORE)]
Sample rates: [0.1, 61.44] MSps
Filter bandwidths: [5, 40], [50, 130] MHz
Sensors: lo_locked
Other Settings:
* TSP_CONST - Digital DC test signal level in LMS7002M TSP chain.
[key=TSP_CONST, default=16383, type=int, range=[0, 32767]]
* CALIBRATE - DC/IQ calibration bandwidth
[key=CALIBRATE, type=float, range=[2.5e+06, 1.2e+08]]
* ENABLE_GFIR_LPF - LPF bandwidth (must be set after sample rate)
[key=ENABLE_GFIR_LPF, type=float]
* TSG_NCO - Enable NCO test signal
[key=TSG_NCO, default=4, type=int, options=(-1, 4, 8)]

Allright, I think I have spotted the issue.
SoapyLMS7 version 22.09.1 does not have the setClockSource(), it was introduced in version 23.10.0.

ii  soapysdr0.8-module-lms7:arm64      22.09.1+dfsg-1+b2 arm64        Lime Microsystems LMS7 device support for SoapySDR
ii  liblimesuite22.09-1:arm64 22.09.1+dfsg-1+b2 arm64        library to access LMS7 transceiver based hardware
2 Likes

After some time I finally found a very simple solution. The external reference can be activated once by a single LimeUtil-command during system startup:

LimeUtil --refclk --fref=10e6

The external reference is now active until reset or loss of power.
73, Stefan

2 Likes

Hi, I got an equal problem. I have one LBE 1421, set each output to 10Mhz, connected each to one Limesdr-USB. How do you verify that the refclk is working correct?

Seems to me like its going on and off all the time.

Hi, I’m using the LBE-1420. On the LimeSDR USB is a LED showing the external ref status. When external ref is active, the led is green, when internal ref, led is off. red led means it is on external ref, but no signal. The led is the upper right, when you look at the board in this orientation. Once the external ref is on it stays on here as long the board is powered.