diff options
author | Martin Braun <martin.braun@ettus.com> | 2017-07-12 16:32:05 -0700 |
---|---|---|
committer | Martin Braun <martin.braun@ettus.com> | 2017-12-22 15:04:00 -0800 |
commit | 7cd675833655829655176fb17c9c592aefb63c55 (patch) | |
tree | 29d757f6c551cd591b6ca3d8c82915eddc007b44 /mpm/python/usrp_mpm/dboard_manager | |
parent | e5a7be445377621ab68740487ed2e0baba5347bc (diff) | |
download | uhd-7cd675833655829655176fb17c9c592aefb63c55.tar.gz uhd-7cd675833655829655176fb17c9c592aefb63c55.tar.bz2 uhd-7cd675833655829655176fb17c9c592aefb63c55.zip |
n310/eiscat: Removed 20 MHz as a valid ref clock frequency
Diffstat (limited to 'mpm/python/usrp_mpm/dboard_manager')
-rw-r--r-- | mpm/python/usrp_mpm/dboard_manager/eiscat.py | 16 | ||||
-rw-r--r-- | mpm/python/usrp_mpm/dboard_manager/lmk_eiscat.py | 6 |
2 files changed, 13 insertions, 9 deletions
diff --git a/mpm/python/usrp_mpm/dboard_manager/eiscat.py b/mpm/python/usrp_mpm/dboard_manager/eiscat.py index b4ecd01dd..822923fbf 100644 --- a/mpm/python/usrp_mpm/dboard_manager/eiscat.py +++ b/mpm/python/usrp_mpm/dboard_manager/eiscat.py @@ -435,7 +435,7 @@ class EISCAT(DboardManagerBase): self.log = get_logger("EISCAT-{}".format(slot_idx)) self.log.trace("Initializing EISCAT daughterboard, slot index {}".format(self.slot_idx)) self.initialized = False - self.ref_clock_freq = 10e6 + self.ref_clock_freq = 10e6 # This is the only supported clock rate # Define some attributes so that PyLint stays quiet: self.radio_regs = None self.jesd_cores = None @@ -701,13 +701,13 @@ class EISCAT(DboardManagerBase): """ Call this to notify the daughterboard about a change in reference clock """ - if self.initialized and freq != self.ref_clock_freq: - self.log.warning( - "Attempting to update external reference clock frequency " - "after initialization! This will only take effect after " - "the daughterboard is re-initialized. Unsetting init flag now." + if freq != self.ref_clock_freq: + self.log.error( + "EISCAT daughterboard only supports a reference clock " \ + "frequency of {} MHz".format(self.ref_clock_freq/1e6) ) - self.initialized = False - self.ref_clock_freq = freq + raise RuntimeError("Invalid reference clock frequency: {}".format( + freq + )) diff --git a/mpm/python/usrp_mpm/dboard_manager/lmk_eiscat.py b/mpm/python/usrp_mpm/dboard_manager/lmk_eiscat.py index 3affdc3e9..4bd9594d4 100644 --- a/mpm/python/usrp_mpm/dboard_manager/lmk_eiscat.py +++ b/mpm/python/usrp_mpm/dboard_manager/lmk_eiscat.py @@ -28,7 +28,11 @@ class LMK04828EISCAT(LMK04828): def __init__(self, regs_iface, ref_clock_freq, slot=None): LMK04828.__init__(self, regs_iface, slot) self.log.trace("Using reference clock frequency {} MHz".format(ref_clock_freq/1e6)) - assert ref_clock_freq in (10e6, 20e6) + if ref_clock_freq != 10e6: + error_msg = "Invalid reference clock frequency: {} MHz. " \ + "Must be 10 MHz.".format(ref_clock_freq) + self.log.error(error_msg) + raise RuntimeError(error_msg) self.ref_clock_freq = ref_clock_freq self.init() self.config() |