LimeSDR-Mini v2.4 - external clock

I have version v2.4 but on the page is only version v2.2
https://limesdr-mini.myriadrf.org/

I want to use an external clock with LimeSDR Mini

On the website it is written “(remove R63 and solder R66)”, but on my version 2.4 there is IC20 in place of R63 and R66.
So the question is, how can you use an external clock in version 2.4?

https://limesdr-mini.myriadrf.org/documentation/board-description#clock-distribution

1 Like

Hi,

on LimeSDR-Mini v2.4 board version external clock source can be selected trough onboard switch (IC20).
To control onboard switch modify FPGA register:
Address - 0x00CF[0]
0 - VCTCXO (default),
1 - REFCLK IN J8

1 Like

@ricardas can this be achieved via LMS API during setup? Seems like the sort of thing which should be, instead of having to directly modify FPGA registers.

1 Like

Great, thank you for the information.

The question is: can this be controlled in a simpler way?
Or where can I find instructions on how to edit such a registry and then restore it to default settings?

Or is it possible to control it from the “device_args” level as in the example below from your website.

https://librecellular.org/user/configuration#lte-band-3

Hi , can I ask for an update, any news? :slight_smile:

Hello, to avoid redundant posts in the forum, could you please provide a list of changes for board version v2.4 compared to v2.2?
Alternatively, is there an updated git repository for v2.4 at GitHub - myriadrf/LimeSDR-Mini-v2: LimeSDR Mini v2 Hardware Design?
Thank you very much. Jakub

I’m bumping this thread because I also want to know how this works in v2.4

@VytautasB
Is this the same as LMS SPI/Board SPI register 0x00cf (which can be read/written via the SPI module in LimeSuitGUI?
If not, then is there a way to set that register without rebuilding/reprogramming the FPGA firmware?
…and finally: Is there a way to set the default reference to external, rather than internal, without rebuilding FPGA firmware?

Hi @Ian,

Yes I was talking about Board SPI registers 0x00CF you can modify it trough LimeSuiteGUI.

No there is no way to change default register value without recompiling FPGA gateware.

Regards,
Vytautas

Thanks for getting back to me!

I could create a udev rule that would execute a command like limesuiteNG’s limeSPI command.
This way, udev/systemd would enable the external reference prior to any use of the SDR.

However, when I try to execute limeSPI, it tells me that --read and --write aren’t valid: “Flag could not be matched: read”. So it looks like the documentation needs to be tweaked to show limeSPI’s correct syntax.

.

EDIT: I figured out the correct limeSPI command syntax by reading the C+ code :smiley:

So here’s how to use udev to always enable the external reference by default, for the LimeSDR Mini v2.4 (October 2024):

  1. edit /etc/udev/rules.d/65-limesuiteng-usb.rules.
  2. find the line that says:
    ACTION=="add", SUBSYSTEM=="usb", ATTR{idVendor}=="0403", ATTR{idProduct}=="601f", MODE=="666"
  3. At the end of that line, add:
    , RUN+="/usr/local/bin/limeSPI --device '0403:601f' --chip FPGA write -s 00cf0001"
  4. save, exit, and run sudo /etc/init.d/udev restart
  5. unplug+replug the usb for the sdr
  6. check that udev actually did what we told it to:
    limeSPI --device "0403:601f" --chip FPGA read -s 00cf
  7. …and it should print out: 00cf0001, and limeGUI should also report 0001 for this register :partying_face: :tada:

To ‘permanently’ switch back to the internal reference, you can comment out the , RUN+=.... portion that we added (you’ll also need to restart udev as above, and unplug and replug your device). To ‘temporarily’ switch back to internal, just execute /usr/local/bin/limeSPI --device '0403:601f' --chip FPGA write -s 00cf0000.

I hope this information helps someone in the future. And thanks for your time!

1 Like