From 90ed2e3a80eef0be3a7270364335f0e82f004cc1 Mon Sep 17 00:00:00 2001 From: Josh Blum Date: Mon, 26 Apr 2010 14:42:32 -0700 Subject: prefixed the ASSERT_THROW macro with UHD for the sake of namespace --- host/lib/usrp/dboard/db_basic_and_lf.cpp | 8 ++++---- host/lib/usrp/dboard/db_rfx.cpp | 10 +++++----- host/lib/usrp/dboard/db_xcvr2450.cpp | 4 ++-- 3 files changed, 11 insertions(+), 11 deletions(-) (limited to 'host/lib/usrp/dboard') diff --git a/host/lib/usrp/dboard/db_basic_and_lf.cpp b/host/lib/usrp/dboard/db_basic_and_lf.cpp index c7b841efb..4ca2ef9b1 100644 --- a/host/lib/usrp/dboard/db_basic_and_lf.cpp +++ b/host/lib/usrp/dboard/db_basic_and_lf.cpp @@ -166,11 +166,11 @@ void basic_rx::rx_set(const wax::obj &key_, const wax::obj &val){ switch(key.as()){ case SUBDEV_PROP_GAIN: - ASSERT_THROW(val.as() == float(0)); + UHD_ASSERT_THROW(val.as() == float(0)); return; case SUBDEV_PROP_ANTENNA: - ASSERT_THROW(val.as() == std::string("")); + UHD_ASSERT_THROW(val.as() == std::string("")); return; case SUBDEV_PROP_FREQ: @@ -261,11 +261,11 @@ void basic_tx::tx_set(const wax::obj &key_, const wax::obj &val){ switch(key.as()){ case SUBDEV_PROP_GAIN: - ASSERT_THROW(val.as() == float(0)); + UHD_ASSERT_THROW(val.as() == float(0)); return; case SUBDEV_PROP_ANTENNA: - ASSERT_THROW(val.as() == std::string("")); + UHD_ASSERT_THROW(val.as() == std::string("")); return; case SUBDEV_PROP_FREQ: diff --git a/host/lib/usrp/dboard/db_rfx.cpp b/host/lib/usrp/dboard/db_rfx.cpp index 49ec9412c..14879dbed 100644 --- a/host/lib/usrp/dboard/db_rfx.cpp +++ b/host/lib/usrp/dboard/db_rfx.cpp @@ -192,7 +192,7 @@ void rfx_xcvr::set_tx_lo_freq(double freq){ void rfx_xcvr::set_rx_ant(const std::string &ant){ //validate input - ASSERT_THROW(ant == "TX/RX" or ant == "RX2"); + UHD_ASSERT_THROW(ant == "TX/RX" or ant == "RX2"); //set the rx atr regs that change with antenna setting this->get_iface()->set_atr_reg( @@ -350,12 +350,12 @@ void rfx_xcvr::rx_get(const wax::obj &key_, wax::obj &val){ return; case SUBDEV_PROP_GAIN: - ASSERT_THROW(name == "PGA0"); + UHD_ASSERT_THROW(name == "PGA0"); val = _rx_pga0_gain; return; case SUBDEV_PROP_GAIN_RANGE: - ASSERT_THROW(name == "PGA0"); + UHD_ASSERT_THROW(name == "PGA0"); val = gain_range_t(0, _max_rx_pga0_gain, float(0.022)); return; @@ -413,7 +413,7 @@ void rfx_xcvr::rx_set(const wax::obj &key_, const wax::obj &val){ return; case SUBDEV_PROP_GAIN: - ASSERT_THROW(name == "PGA0"); + UHD_ASSERT_THROW(name == "PGA0"); set_rx_pga0_gain(val.as()); return; @@ -507,7 +507,7 @@ void rfx_xcvr::tx_set(const wax::obj &key_, const wax::obj &val){ case SUBDEV_PROP_ANTENNA: //its always set to tx/rx, so we only allow this value - ASSERT_THROW(val.as() == "TX/RX"); + UHD_ASSERT_THROW(val.as() == "TX/RX"); return; default: UHD_THROW_PROP_READ_ONLY(); diff --git a/host/lib/usrp/dboard/db_xcvr2450.cpp b/host/lib/usrp/dboard/db_xcvr2450.cpp index 2052511f8..576d08848 100644 --- a/host/lib/usrp/dboard/db_xcvr2450.cpp +++ b/host/lib/usrp/dboard/db_xcvr2450.cpp @@ -395,7 +395,7 @@ void xcvr2450::set_tx_gain(float gain, const std::string &name){ _max2829_regs.tx_baseband_gain = gain_to_tx_bb_reg(gain); send_reg(0x9); } - else ASSERT_THROW(false); + else UHD_ASSERT_THROW(false); _tx_gains[name] = gain; } @@ -409,7 +409,7 @@ void xcvr2450::set_rx_gain(float gain, const std::string &name){ _max2829_regs.rx_lna_gain = gain_to_rx_lna_reg(gain); send_reg(0xB); } - else ASSERT_THROW(false); + else UHD_ASSERT_THROW(false); _rx_gains[name] = gain; } -- cgit v1.2.3