diff options
| author | Martin Braun <martin.braun@ettus.com> | 2017-12-05 16:19:23 -0800 | 
|---|---|---|
| committer | Martin Braun <martin.braun@ettus.com> | 2017-12-22 15:05:58 -0800 | 
| commit | a568e1d58c05fcacc40398d658b2cefdf72403f9 (patch) | |
| tree | 0ea0fa7c91dfa5a449bc86f0345f847bfe623563 /host | |
| parent | 7df29f6ee62d44eaeed878700ddbaeeb1d7fda46 (diff) | |
| download | uhd-a568e1d58c05fcacc40398d658b2cefdf72403f9.tar.gz uhd-a568e1d58c05fcacc40398d658b2cefdf72403f9.tar.bz2 uhd-a568e1d58c05fcacc40398d658b2cefdf72403f9.zip | |
types: Change eeprom_map_to to uint8_t vectors
mpmd_impl was already using this type, fixed conversion from
std::string to std::vector<uint8_t> there too.
Reviewed-By: Brent Stapleton <brent.stapleton@ettus.com>
Diffstat (limited to 'host')
| -rw-r--r-- | host/include/uhd/types/eeprom.hpp | 4 | ||||
| -rw-r--r-- | host/lib/usrp/mpmd/mpmd_impl.cpp | 5 | 
2 files changed, 6 insertions, 3 deletions
| diff --git a/host/include/uhd/types/eeprom.hpp b/host/include/uhd/types/eeprom.hpp index 814d429c8..19729f396 100644 --- a/host/include/uhd/types/eeprom.hpp +++ b/host/include/uhd/types/eeprom.hpp @@ -9,11 +9,11 @@  #include <map>  #include <string> +#include <vector>  namespace uhd { -    typedef std::map<std::string, std::string> eeprom_map_t; - +    typedef std::map<std::string, std::vector<uint8_t>> eeprom_map_t;  } /* namespace uhd */ diff --git a/host/lib/usrp/mpmd/mpmd_impl.cpp b/host/lib/usrp/mpmd/mpmd_impl.cpp index f0498cf99..8deac2743 100644 --- a/host/lib/usrp/mpmd/mpmd_impl.cpp +++ b/host/lib/usrp/mpmd/mpmd_impl.cpp @@ -171,7 +171,10 @@ namespace {              .add_coerced_subscriber([mb](const uhd::usrp::mboard_eeprom_t& mb_eeprom){                  eeprom_map_t eeprom_map;                  for (const auto& key : mb_eeprom.keys()) { -                    eeprom_map[key] = mb_eeprom[key]; +                    eeprom_map[key] = std::vector<uint8_t>( +                            mb_eeprom[key].cbegin(), +                            mb_eeprom[key].cend() +                    );                  }                  mb->rpc->notify_with_token("set_mb_eeprom", eeprom_map);              }) | 
