aboutsummaryrefslogtreecommitdiffstats
path: root/mpm/python/usrp_mpm/dboard_manager
diff options
context:
space:
mode:
authorMartin Braun <martin.braun@ettus.com>2019-11-08 15:56:46 -0800
committerMartin Braun <martin.braun@ettus.com>2019-11-26 12:21:33 -0800
commit14fb3cc6f4c63303a7f35b81087c31eb494f7166 (patch)
tree9a157743854ff731cf6443dce4fe3c6a465627b0 /mpm/python/usrp_mpm/dboard_manager
parentd60e4d87d8e83cc7810af2b8a9e01147096b3475 (diff)
downloaduhd-14fb3cc6f4c63303a7f35b81087c31eb494f7166.tar.gz
uhd-14fb3cc6f4c63303a7f35b81087c31eb494f7166.tar.bz2
uhd-14fb3cc6f4c63303a7f35b81087c31eb494f7166.zip
e310: Fix issues in MPM and UHD
- Remove superfluous INFO logging - Improve formatting in many places - Improve Pylint score in various places - Add tear_down to DB object - Simplify custom EEPROM code for E310 - Fix time source selection code - Remove references to GPS_CTRL and GPS_STATUS (are E320 only) - Move clock source control out of MboardRegs object
Diffstat (limited to 'mpm/python/usrp_mpm/dboard_manager')
-rw-r--r--mpm/python/usrp_mpm/dboard_manager/e31x_db.py14
1 files changed, 13 insertions, 1 deletions
diff --git a/mpm/python/usrp_mpm/dboard_manager/e31x_db.py b/mpm/python/usrp_mpm/dboard_manager/e31x_db.py
index add77553f..8c38fa652 100644
--- a/mpm/python/usrp_mpm/dboard_manager/e31x_db.py
+++ b/mpm/python/usrp_mpm/dboard_manager/e31x_db.py
@@ -126,6 +126,18 @@ class E31x_db(DboardManagerBase):
self.set_catalina_clock_rate(self.master_clock_rate)
return True
+ def tear_down(self):
+ """
+ De-init this object as much as possible.
+ """
+ self.log.trace("Tearing down E310 DB object!")
+ for method in [
+ x for x in dir(self.catalina)
+ if not x.startswith("_") and \
+ callable(getattr(self.catalina, x))]:
+ delattr(self, method)
+ self.catalina = None
+
def get_master_clock_rate(self):
" Return master clock rate (== sampling rate) "
return self.master_clock_rate
@@ -197,7 +209,7 @@ class E31x_db(DboardManagerBase):
"""
Async call to catalina set_clock_rate
"""
- self.log.trace("Setting Clock rate to {}".format(rate))
+ self.log.trace("Setting Clock rate to {} MHz".format(rate/1e6))
async_exec(lib.ad9361, "set_clock_rate", self.catalina, rate)
return rate