diff options
author | Lane Kolbly <lane.kolbly@ni.com> | 2021-06-22 15:21:29 -0500 |
---|---|---|
committer | Aaron Rossetto <aaron.rossetto@ni.com> | 2021-06-23 13:15:47 -0500 |
commit | 8adbc72f0d3c9e15d6bbf41c27f3f192e3df305f (patch) | |
tree | 26cff889ced6fb5295b79858ec6696de720d7a85 /mpm/python/usrp_mpm/periph_manager/x4xx.py | |
parent | b50144a0bee95dae14059e7cd4d7bb27d139786b (diff) | |
download | uhd-8adbc72f0d3c9e15d6bbf41c27f3f192e3df305f.tar.gz uhd-8adbc72f0d3c9e15d6bbf41c27f3f192e3df305f.tar.bz2 uhd-8adbc72f0d3c9e15d6bbf41c27f3f192e3df305f.zip |
mpm: Move cal freeze defaults to x4xx
This fixes an issue where the slot 0 ADC blocks would erroneously
report that they were unfrozen.
Additionally, adds logic to restore a saved cal freeze state on
sync source change.
Diffstat (limited to 'mpm/python/usrp_mpm/periph_manager/x4xx.py')
-rw-r--r-- | mpm/python/usrp_mpm/periph_manager/x4xx.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/mpm/python/usrp_mpm/periph_manager/x4xx.py b/mpm/python/usrp_mpm/periph_manager/x4xx.py index 70a087d14..d46c9098e 100644 --- a/mpm/python/usrp_mpm/periph_manager/x4xx.py +++ b/mpm/python/usrp_mpm/periph_manager/x4xx.py @@ -317,6 +317,10 @@ class x4xx(ZynqComponents, PeriphManagerBase): except Exception as ex: self.log.warning("Failed to initialize device on boot: %s", str(ex)) + # Freeze the RFDC calibration by default + self.rfdc.set_cal_frozen(1, 1, "both") + self.rfdc.set_cal_frozen(1, 0, "both") + # The parent class versions of these functions require access to self, but # these versions don't. # pylint: disable=no-self-use @@ -880,6 +884,8 @@ class x4xx(ZynqComponents, PeriphManagerBase): # was changed, to ensure the device transmission/acquisition continues at # the requested frequency. self.rfdc.rfdc_restore_nco_freq() + # Do the same for the calibration freeze state + self.rfdc.rfdc_restore_cal_freeze() except RuntimeError as ex: err = f"Setting clock_source={clock_source},time_source={time_source} " \ f"failed, falling back to {self._safe_sync_source}. Error: " \ |