aboutsummaryrefslogtreecommitdiffstats
path: root/host/lib/usrp/b200
diff options
context:
space:
mode:
authorMartin Braun <martin.braun@ettus.com>2014-09-25 17:29:43 -0700
committerMartin Braun <martin.braun@ettus.com>2014-09-25 17:29:43 -0700
commit994e993893d921c074ce4097632f8fa5bdecff66 (patch)
treec1e0fe3601e0ce8d7fa3690f578d0f341e610fed /host/lib/usrp/b200
parenta1767ede3c147c1748c6a33a52469d0cba644bf5 (diff)
parent9dc96fd9bf8d430a9f41f3476bc62cc3ba43e1d7 (diff)
downloaduhd-994e993893d921c074ce4097632f8fa5bdecff66.tar.gz
uhd-994e993893d921c074ce4097632f8fa5bdecff66.tar.bz2
uhd-994e993893d921c074ce4097632f8fa5bdecff66.zip
Merge branch 'maint'
Diffstat (limited to 'host/lib/usrp/b200')
-rw-r--r--host/lib/usrp/b200/b200_impl.cpp15
1 files changed, 15 insertions, 0 deletions
diff --git a/host/lib/usrp/b200/b200_impl.cpp b/host/lib/usrp/b200/b200_impl.cpp
index 78b979e04..3ff502858 100644
--- a/host/lib/usrp/b200/b200_impl.cpp
+++ b/host/lib/usrp/b200/b200_impl.cpp
@@ -151,6 +151,21 @@ static device_addrs_t b200_find(const device_addr_t &hint)
new_addr["type"] = "b200";
new_addr["name"] = mb_eeprom["name"];
new_addr["serial"] = handle->get_serial();
+ if (not mb_eeprom["product"].empty())
+ {
+ switch (boost::lexical_cast<boost::uint16_t>(mb_eeprom["product"]))
+ {
+ case 0x0001:
+ case 0x7737:
+ new_addr["product"] = "B200";
+ break;
+ case 0x7738:
+ case 0x0002:
+ new_addr["product"] = "B210";
+ break;
+ default: UHD_MSG(error) << "B200 unknown product code: " << mb_eeprom["product"] << std::endl;
+ }
+ }
//this is a found b200 when the hint serial and name match or blank
if (
(not hint.has_key("name") or hint["name"] == new_addr["name"]) and