diff options
author | Brent Stapleton <brent.stapleton@ettus.com> | 2018-07-02 17:13:33 -0700 |
---|---|---|
committer | Martin Braun <martin.braun@ettus.com> | 2018-07-06 14:53:40 -0700 |
commit | 9c2e1907e96d708f71de92faa7a1501d236baf8d (patch) | |
tree | a6fd115360fcec6b2f26537b398be1fb2f455cd4 | |
parent | 7aee32ef9dc1b75b078e219c7ddd79df0350260a (diff) | |
download | uhd-9c2e1907e96d708f71de92faa7a1501d236baf8d.tar.gz uhd-9c2e1907e96d708f71de92faa7a1501d236baf8d.tar.bz2 uhd-9c2e1907e96d708f71de92faa7a1501d236baf8d.zip |
mpm: n3xx: Overridable crossbar base port
Moving the RFNoC crossbar base port to the class overridables. MPM
devices may need to reserve different numbers of ports for non-blocks;
this can now be done by overriding the crossbar_base_port.
-rw-r--r-- | mpm/python/usrp_mpm/periph_manager/base.py | 5 | ||||
-rw-r--r-- | mpm/python/usrp_mpm/periph_manager/n3xx.py | 1 |
2 files changed, 5 insertions, 1 deletions
diff --git a/mpm/python/usrp_mpm/periph_manager/base.py b/mpm/python/usrp_mpm/periph_manager/base.py index d1f2c9f92..f920c9387 100644 --- a/mpm/python/usrp_mpm/periph_manager/base.py +++ b/mpm/python/usrp_mpm/periph_manager/base.py @@ -95,6 +95,9 @@ class PeriphManagerBase(object): # depending on the severity of the issue. If fewer dboards are found, # that's generally considered OK. max_num_dboards = 2 + # The index of the first port of the RFNoC crossbar which is connected to + # an RFNoC block + crossbar_base_port = 0 # Address of the daughterboard EEPROMs. This could be something like # "e0004000.i2c". This value will be passed to get_eeprom_paths() to # determine a full path to an EEPROM device. @@ -670,7 +673,7 @@ class PeriphManagerBase(object): xbar_index -- The index of the crossbar that's being queried """ - return 3 # FIXME It's 3 because 0,1,2 are SFP,SFP,DMA + return self.crossbar_base_port def set_xbar_local_addr(self, xbar_index, local_addr): """ diff --git a/mpm/python/usrp_mpm/periph_manager/n3xx.py b/mpm/python/usrp_mpm/periph_manager/n3xx.py index c09a1a7ff..a90e39b27 100644 --- a/mpm/python/usrp_mpm/periph_manager/n3xx.py +++ b/mpm/python/usrp_mpm/periph_manager/n3xx.py @@ -125,6 +125,7 @@ class n3xx(PeriphManagerBase): 'temp': 'get_temp_sensor', 'fan': 'get_fan_sensor', } + crossbar_base_port = 3 # It's 3 because 0,1,2 are SFP,SFP,DMA dboard_eeprom_addr = "e0004000.i2c" dboard_eeprom_offset = 0 dboard_eeprom_max_len = 64 |