diff options
author | Martin Braun <martin.braun@ettus.com> | 2018-05-29 16:24:21 -0700 |
---|---|---|
committer | Martin Braun <martin.braun@ettus.com> | 2018-05-31 01:20:04 +0200 |
commit | 208c2c9639ca7cf09a9f716bb3865cd61a8d257d (patch) | |
tree | a679b415ff768f5f335c72d0f97c6df42514b936 /host/lib/usrp | |
parent | 6294c1e55d887f0fc781663b3e39fa7737280570 (diff) | |
download | uhd-208c2c9639ca7cf09a9f716bb3865cd61a8d257d.tar.gz uhd-208c2c9639ca7cf09a9f716bb3865cd61a8d257d.tar.bz2 uhd-208c2c9639ca7cf09a9f716bb3865cd61a8d257d.zip |
mg: Rename _L to _log_prefix
Avoids clashes with ctype.h.
Diffstat (limited to 'host/lib/usrp')
-rw-r--r-- | host/lib/usrp/dboard/magnesium/magnesium_ad9371_iface.cpp | 20 | ||||
-rw-r--r-- | host/lib/usrp/dboard/magnesium/magnesium_ad9371_iface.hpp | 4 |
2 files changed, 12 insertions, 12 deletions
diff --git a/host/lib/usrp/dboard/magnesium/magnesium_ad9371_iface.cpp b/host/lib/usrp/dboard/magnesium/magnesium_ad9371_iface.cpp index 4e567c493..41e33574d 100644 --- a/host/lib/usrp/dboard/magnesium/magnesium_ad9371_iface.cpp +++ b/host/lib/usrp/dboard/magnesium/magnesium_ad9371_iface.cpp @@ -37,9 +37,9 @@ magnesium_ad9371_iface::magnesium_ad9371_iface( ) : _rpcc(rpcc) , _slot_idx(slot_idx) , _rpc_prefix((slot_idx == 0) ? "db_0_" : "db_1_") - , _L((slot_idx == 0) ? "AD9371-0" : "AD9371-1") + , _log_prefix((slot_idx == 0) ? "AD9371-0" : "AD9371-1") { - UHD_LOG_TRACE(_L, + UHD_LOG_TRACE(_log_prefix, "Initialized controls with RPC prefix " << _rpc_prefix << " for slot " << _slot_idx); } @@ -52,7 +52,7 @@ double magnesium_ad9371_iface::set_frequency( // Note: This sets the frequency for both channels (1 and 2). auto which = _get_which(dir, chan); auto actual_freq = request<double>("set_freq", which, freq, false); - UHD_LOG_TRACE(_L, + UHD_LOG_TRACE(_log_prefix, _rpc_prefix << "set_freq returned " << actual_freq); return actual_freq; } @@ -64,7 +64,7 @@ double magnesium_ad9371_iface::set_gain( ) { auto which = _get_which(dir, chan); auto retval = request<double>("set_gain", which, gain); - UHD_LOG_TRACE(_L, _rpc_prefix << "set_gain returned " << retval); + UHD_LOG_TRACE(_log_prefix, _rpc_prefix << "set_gain returned " << retval); return retval; //return 0.0; @@ -75,7 +75,7 @@ double magnesium_ad9371_iface::set_bandwidth(const double bandwidth, const size_ { auto const which = _get_which(dir, chan); auto retval = request<double>("set_bw_filter", which, bandwidth); - UHD_LOG_TRACE(_L, _rpc_prefix << "set_bw_filter returned " << retval); + UHD_LOG_TRACE(_log_prefix, _rpc_prefix << "set_bw_filter returned " << retval); return retval; } @@ -85,7 +85,7 @@ double magnesium_ad9371_iface::get_frequency( ) { auto which = _get_which(dir, chan); auto retval = request<double>("get_freq", which); - UHD_LOG_TRACE(_L, _rpc_prefix << "get_freq returned " << retval); + UHD_LOG_TRACE(_log_prefix, _rpc_prefix << "get_freq returned " << retval); return retval; } @@ -93,14 +93,14 @@ double magnesium_ad9371_iface::get_gain(const size_t chan, const direction_t dir { auto which = _get_which(dir, chan); auto retval = request<double>("get_gain", which); - UHD_LOG_TRACE(_L, _rpc_prefix << "get_gain returned " << retval); + UHD_LOG_TRACE(_log_prefix, _rpc_prefix << "get_gain returned " << retval); return retval; } double magnesium_ad9371_iface::get_bandwidth(const size_t /*chan*/, const direction_t /*dir*/) { // TODO: implement - UHD_LOG_WARNING(_L, "Ignoring attempt to get bandwidth"); + UHD_LOG_WARNING(_log_prefix, "Ignoring attempt to get bandwidth"); return 0.0; } @@ -111,7 +111,7 @@ std::string magnesium_ad9371_iface::set_lo_source( // There is only one LO for 2 channels. Using channel 0 for 'which' auto which = _get_which(dir, 0); auto retval = request<std::string>("set_lo_source", which, source); - UHD_LOG_TRACE(_L, _rpc_prefix << "set_lo_source returned " << retval); + UHD_LOG_TRACE(_log_prefix, _rpc_prefix << "set_lo_source returned " << retval); return retval; } @@ -121,7 +121,7 @@ std::string magnesium_ad9371_iface::get_lo_source( // There is only one LO for 2 channels. Using channel 0 for 'which' auto which = _get_which(dir, 0); auto retval = request<std::string>("get_lo_source", which); - UHD_LOG_TRACE(_L, _rpc_prefix << "get_lo_source returned " << retval); + UHD_LOG_TRACE(_log_prefix, _rpc_prefix << "get_lo_source returned " << retval); return retval; } diff --git a/host/lib/usrp/dboard/magnesium/magnesium_ad9371_iface.hpp b/host/lib/usrp/dboard/magnesium/magnesium_ad9371_iface.hpp index 5da9e68e5..592af578e 100644 --- a/host/lib/usrp/dboard/magnesium/magnesium_ad9371_iface.hpp +++ b/host/lib/usrp/dboard/magnesium/magnesium_ad9371_iface.hpp @@ -70,7 +70,7 @@ private: template <typename return_type, typename... Args> return_type request(std::string const& func_name, Args&&... args) { - UHD_LOG_TRACE(_L, "[RPC] Calling " << func_name); + UHD_LOG_TRACE(_log_prefix, "[RPC] Calling " << func_name); return _rpcc->request_with_token<return_type>( _rpc_prefix + func_name, std::forward<Args>(args)... @@ -87,7 +87,7 @@ private: const std::string _rpc_prefix; //! Logger prefix - const std::string _L; + const std::string _log_prefix; }; |