diff options
author | Sugandha Gupta <sugandha.gupta@ettus.com> | 2018-11-29 21:26:33 -0800 |
---|---|---|
committer | Brent Stapleton <bstapleton@g.hmc.edu> | 2018-11-30 16:43:02 -0800 |
commit | f4a8e6fc4afc44c2a7a477206a5061406c08bd4a (patch) | |
tree | 6c0f789b8a6d7f36899ec800b676cb9a3cdd2843 /mpm/python/usrp_mpm | |
parent | 4f807a9da4e612e5fb4e9485dba3365d20ac9bd2 (diff) | |
download | uhd-f4a8e6fc4afc44c2a7a477206a5061406c08bd4a.tar.gz uhd-f4a8e6fc4afc44c2a7a477206a5061406c08bd4a.tar.bz2 uhd-f4a8e6fc4afc44c2a7a477206a5061406c08bd4a.zip |
e320: Fix return value of get_fpga_type
Return value should be fpga image type and not
sfp type, fixes a bug with uhd_image_loader while
trying to update XG and AA images
Diffstat (limited to 'mpm/python/usrp_mpm')
-rw-r--r-- | mpm/python/usrp_mpm/periph_manager/e320_periphs.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/mpm/python/usrp_mpm/periph_manager/e320_periphs.py b/mpm/python/usrp_mpm/periph_manager/e320_periphs.py index cf9a6335f..fa8ad30b2 100644 --- a/mpm/python/usrp_mpm/periph_manager/e320_periphs.py +++ b/mpm/python/usrp_mpm/periph_manager/e320_periphs.py @@ -297,10 +297,10 @@ class MboardRegsControl(object): sfp_info_rb = self.peek32(self.MB_SFP_PORT_INFO) # Print the registers values as 32-bit hex values self.log.trace("SFP Info: 0x{0:0{1}X}".format(sfp_info_rb, 8)) + sfp_type = E320_SFP_TYPES.get((sfp_info_rb & 0x0000FF00) >> 8, "") + self.log.trace("SFP type: {}".format(sfp_type)) try: - sfp_type = E320_SFP_TYPES.get((sfp_info_rb & 0x0000FF00) >> 8, "") - self.log.trace("SFP type: {}".format(sfp_type)) - return sfp_type + return E320_FPGA_TYPES_BY_SFP[(sfp_type)] except KeyError: self.log.warning("Unrecognized SFP type: {}" .format(sfp_type)) |