From 966d38e710a596a0be877dcbb81a79351c03dee0 Mon Sep 17 00:00:00 2001 From: Dmitry Sharshakov Date: Sun, 12 Nov 2023 10:12:23 +0300 Subject: [PATCH] host: fix Boost warnings due to global placeholders --- host/cores/super_recv_packet_handler.hpp | 2 +- host/umtrx_iface.cpp | 2 +- host/umtrx_impl.cpp | 120 +++++++++++------------ host/umtrx_io_impl.cpp | 8 +- 4 files changed, 66 insertions(+), 66 deletions(-) diff --git a/host/cores/super_recv_packet_handler.hpp b/host/cores/super_recv_packet_handler.hpp index 91d5df9b1..9623a6995 100644 --- a/host/cores/super_recv_packet_handler.hpp +++ b/host/cores/super_recv_packet_handler.hpp @@ -32,7 +32,7 @@ #include #include #include -#include +#include #include #include #include diff --git a/host/umtrx_iface.cpp b/host/umtrx_iface.cpp index 477f8ad7f..82da24950 100644 --- a/host/umtrx_iface.cpp +++ b/host/umtrx_iface.cpp @@ -30,7 +30,7 @@ #include //used for htonl and ntohl #include #include -#include +#include #include #include #include diff --git a/host/umtrx_impl.cpp b/host/umtrx_impl.cpp index ef0a67430..3665dbe03 100644 --- a/host/umtrx_impl.cpp +++ b/host/umtrx_impl.cpp @@ -21,7 +21,7 @@ #include "umtrx_log_adapter.hpp" #include "cores/apply_corrections.hpp" #include -#include +#include #include //sleep #include #include @@ -107,7 +107,7 @@ template property &property_alias(uhd::property_tree::sptr &_tre { // By default route each chanel to its own antenna return _tree->create(alias) - .subscribe(boost::bind(&uhd::property::set, boost::ref(_tree->access(orig)), _1)) + .subscribe(boost::bind(&uhd::property::set, boost::ref(_tree->access(orig)), boost::placeholders::_1)) .publish(boost::bind(&uhd::property::get, boost::ref(_tree->access(orig)))); } @@ -266,23 +266,23 @@ umtrx_impl::umtrx_impl(const device_addr_t &device_addr) _ctrl = umtrx_fifo_ctrl::make(this->make_xport(UMTRX_CTRL_FRAMER, device_addr_t()), UMTRX_CTRL_SID, fifo_ctrl_window); _ctrl->peek32(0); //test readback _tree->create(mb_path / "time/cmd") - .subscribe(boost::bind(&umtrx_fifo_ctrl::set_time, _ctrl, _1)); + .subscribe(boost::bind(&umtrx_fifo_ctrl::set_time, _ctrl, boost::placeholders::_1)); _tree->create(mb_path / "tick_rate") - .subscribe(boost::bind(&umtrx_fifo_ctrl::set_tick_rate, _ctrl, _1)); + .subscribe(boost::bind(&umtrx_fifo_ctrl::set_tick_rate, _ctrl, boost::placeholders::_1)); //////////////////////////////////////////////////////////////////// // setup the mboard eeprom //////////////////////////////////////////////////////////////////// _tree->create(mb_path / "eeprom") .set(_iface->mb_eeprom) - .subscribe(boost::bind(&umtrx_impl::set_mb_eeprom, this, _iface, _1)); + .subscribe(boost::bind(&umtrx_impl::set_mb_eeprom, this, _iface, boost::placeholders::_1)); //////////////////////////////////////////////////////////////// // create clock control objects //////////////////////////////////////////////////////////////// _tree->access(mb_path / "tick_rate") .publish(boost::bind(&umtrx_impl::get_master_clock_rate, this)) - .subscribe(boost::bind(&umtrx_impl::update_tick_rate, this, _1)); + .subscribe(boost::bind(&umtrx_impl::update_tick_rate, this, boost::placeholders::_1)); _tree->create(mb_path / "dsp_rate") .publish(boost::bind(&umtrx_impl::get_master_dsp_rate, this)); @@ -336,13 +336,13 @@ umtrx_impl::umtrx_impl(const device_addr_t &device_addr) // note: the control is also aliased to RF frontend later _tree->create(mb_path / "divsw1") - .subscribe(boost::bind(&umtrx_impl::set_diversity, this, _1, 0)) + .subscribe(boost::bind(&umtrx_impl::set_diversity, this, boost::placeholders::_1, 0)) .set(device_addr.cast("divsw1", false)); UHD_MSG(status) << "Diversity switch for channel 1: " << (_tree->access(mb_path / "divsw1").get()?"true":"false") << std::endl; _tree->create(mb_path / "divsw2") - .subscribe(boost::bind(&umtrx_impl::set_diversity, this, _1, 1)) + .subscribe(boost::bind(&umtrx_impl::set_diversity, this, boost::placeholders::_1, 1)) .set(device_addr.cast("divsw2", false)); UHD_MSG(status) << "Diversity switch for channel 2: " << (_tree->access(mb_path / "divsw2").get()?"true":"false") @@ -425,9 +425,9 @@ umtrx_impl::umtrx_impl(const device_addr_t &device_addr) _tx_fes[1] = tx_frontend_core_200::make(_ctrl, U2_REG_SR_ADDR(SR_TX_FRONT1)); _tree->create(mb_path / "rx_subdev_spec") - .subscribe(boost::bind(&umtrx_impl::update_rx_subdev_spec, this, _1)); + .subscribe(boost::bind(&umtrx_impl::update_rx_subdev_spec, this, boost::placeholders::_1)); _tree->create(mb_path / "tx_subdev_spec") - .subscribe(boost::bind(&umtrx_impl::update_tx_subdev_spec, this, _1)); + .subscribe(boost::bind(&umtrx_impl::update_tx_subdev_spec, this, boost::placeholders::_1)); for (char name = 'A'; name <= 'B'; name++) { @@ -440,21 +440,21 @@ umtrx_impl::umtrx_impl(const device_addr_t &device_addr) tx_fe->set_mux("IQ"); rx_fe->set_mux(false/*no swap*/); _tree->create >(rx_fe_path / "dc_offset" / "value") - .coerce(boost::bind(&rx_frontend_core_200::set_dc_offset, rx_fe, _1)) + .coerce(boost::bind(&rx_frontend_core_200::set_dc_offset, rx_fe, boost::placeholders::_1)) .set(std::complex(0.0, 0.0)); _tree->create(rx_fe_path / "dc_offset" / "enable") - .subscribe(boost::bind(&rx_frontend_core_200::set_dc_offset_auto, rx_fe, _1)) + .subscribe(boost::bind(&rx_frontend_core_200::set_dc_offset_auto, rx_fe, boost::placeholders::_1)) .set(true); _tree->create >(rx_fe_path / "iq_balance" / "value") - .subscribe(boost::bind(&rx_frontend_core_200::set_iq_balance, rx_fe, _1)) + .subscribe(boost::bind(&rx_frontend_core_200::set_iq_balance, rx_fe, boost::placeholders::_1)) .set(std::polar(0.0, 0.0)); /* _tree->create >(tx_fe_path / "dc_offset" / "value") - .coerce(boost::bind(&tx_frontend_core_200::set_dc_offset, tx_fe, _1)) + .coerce(boost::bind(&tx_frontend_core_200::set_dc_offset, tx_fe, boost::placeholders::_1)) .set(std::complex(0.0, 0.0)); */ _tree->create >(tx_fe_path / "iq_balance" / "value") - .subscribe(boost::bind(&tx_frontend_core_200::set_iq_balance, tx_fe, _1)) + .subscribe(boost::bind(&tx_frontend_core_200::set_iq_balance, tx_fe, boost::placeholders::_1)) .set(std::polar(0.0, 0.0)); } @@ -473,22 +473,22 @@ umtrx_impl::umtrx_impl(const device_addr_t &device_addr) _rx_dsps[dspno]->set_mux("IQ", false/*no swap*/); _rx_dsps[dspno]->set_link_rate(UMTRX_LINK_RATE_BPS); _tree->access(mb_path / "dsp_rate") - .subscribe(boost::bind(&rx_dsp_core_200::set_tick_rate, _rx_dsps[dspno], _1)); + .subscribe(boost::bind(&rx_dsp_core_200::set_tick_rate, _rx_dsps[dspno], boost::placeholders::_1)); _tree->access(mb_path / "tick_rate") - .subscribe(boost::bind(&rx_dsp_core_200::set_vita_rate, _rx_dsps[dspno], _1)); + .subscribe(boost::bind(&rx_dsp_core_200::set_vita_rate, _rx_dsps[dspno], boost::placeholders::_1)); fs_path rx_dsp_path = mb_path / str(boost::format("rx_dsps/%u") % dspno); _tree->create(rx_dsp_path / "rate/range") .publish(boost::bind(&rx_dsp_core_200::get_host_rates, _rx_dsps[dspno])); _tree->create(rx_dsp_path / "rate/value") .set(this->get_master_clock_rate()/12) //some default - .coerce(boost::bind(&rx_dsp_core_200::set_host_rate, _rx_dsps[dspno], _1)) - .subscribe(boost::bind(&umtrx_impl::update_rx_samp_rate, this, dspno, _1)); + .coerce(boost::bind(&rx_dsp_core_200::set_host_rate, _rx_dsps[dspno], boost::placeholders::_1)) + .subscribe(boost::bind(&umtrx_impl::update_rx_samp_rate, this, dspno, boost::placeholders::_1)); _tree->create(rx_dsp_path / "freq/value") - .coerce(boost::bind(&rx_dsp_core_200::set_freq, _rx_dsps[dspno], _1)); + .coerce(boost::bind(&rx_dsp_core_200::set_freq, _rx_dsps[dspno], boost::placeholders::_1)); _tree->create(rx_dsp_path / "freq/range") .publish(boost::bind(&rx_dsp_core_200::get_freq_range, _rx_dsps[dspno])); _tree->create(rx_dsp_path / "stream_cmd") - .subscribe(boost::bind(&rx_dsp_core_200::issue_stream_command, _rx_dsps[dspno], _1)); + .subscribe(boost::bind(&rx_dsp_core_200::issue_stream_command, _rx_dsps[dspno], boost::placeholders::_1)); } //////////////////////////////////////////////////////////////// @@ -503,16 +503,16 @@ umtrx_impl::umtrx_impl(const device_addr_t &device_addr) for (size_t dspno = 0; dspno < _tx_dsps.size(); dspno++){ _tx_dsps[dspno]->set_link_rate(UMTRX_LINK_RATE_BPS); _tree->access(mb_path / "dsp_rate") - .subscribe(boost::bind(&tx_dsp_core_200::set_tick_rate, _tx_dsps[dspno], _1)); + .subscribe(boost::bind(&tx_dsp_core_200::set_tick_rate, _tx_dsps[dspno], boost::placeholders::_1)); fs_path tx_dsp_path = mb_path / str(boost::format("tx_dsps/%u") % dspno); _tree->create(tx_dsp_path / "rate/range") .publish(boost::bind(&tx_dsp_core_200::get_host_rates, _tx_dsps[dspno])); _tree->create(tx_dsp_path / "rate/value") .set(this->get_master_clock_rate()/12) //some default - .coerce(boost::bind(&tx_dsp_core_200::set_host_rate, _tx_dsps[dspno], _1)) - .subscribe(boost::bind(&umtrx_impl::update_tx_samp_rate, this, dspno, _1)); + .coerce(boost::bind(&tx_dsp_core_200::set_host_rate, _tx_dsps[dspno], boost::placeholders::_1)) + .subscribe(boost::bind(&umtrx_impl::update_tx_samp_rate, this, dspno, boost::placeholders::_1)); _tree->create(tx_dsp_path / "freq/value") - .coerce(boost::bind(&tx_dsp_core_200::set_freq, _tx_dsps[dspno], _1)); + .coerce(boost::bind(&tx_dsp_core_200::set_freq, _tx_dsps[dspno], boost::placeholders::_1)); _tree->create(tx_dsp_path / "freq/range") .publish(boost::bind(&tx_dsp_core_200::get_freq_range, _tx_dsps[dspno])); } @@ -528,21 +528,21 @@ umtrx_impl::umtrx_impl(const device_addr_t &device_addr) _time64 = time64_core_200::make(_ctrl, U2_REG_SR_ADDR(SR_TIME64), time64_rb_bases); _tree->access(mb_path / "tick_rate") - .subscribe(boost::bind(&time64_core_200::set_tick_rate, _time64, _1)); + .subscribe(boost::bind(&time64_core_200::set_tick_rate, _time64, boost::placeholders::_1)); _tree->create(mb_path / "time" / "now") .publish(boost::bind(&time64_core_200::get_time_now, _time64)) - .subscribe(boost::bind(&time64_core_200::set_time_now, _time64, _1)); + .subscribe(boost::bind(&time64_core_200::set_time_now, _time64, boost::placeholders::_1)); _tree->create(mb_path / "time" / "pps") .publish(boost::bind(&time64_core_200::get_time_last_pps, _time64)) - .subscribe(boost::bind(&time64_core_200::set_time_next_pps, _time64, _1)); + .subscribe(boost::bind(&time64_core_200::set_time_next_pps, _time64, boost::placeholders::_1)); //setup time source props _tree->create(mb_path / "time_source" / "value") - .subscribe(boost::bind(&time64_core_200::set_time_source, _time64, _1)); + .subscribe(boost::bind(&time64_core_200::set_time_source, _time64, boost::placeholders::_1)); _tree->create >(mb_path / "time_source" / "options") .publish(boost::bind(&time64_core_200::get_time_sources, _time64)); //setup reference source props _tree->create(mb_path / "clock_source" / "value") - .subscribe(boost::bind(&umtrx_impl::update_clock_source, this, _1)); + .subscribe(boost::bind(&umtrx_impl::update_clock_source, this, boost::placeholders::_1)); static const std::vector clock_sources = boost::assign::list_of("internal")("external"); _tree->create >(mb_path / "clock_source"/ "options").set(clock_sources); @@ -594,7 +594,7 @@ umtrx_impl::umtrx_impl(const device_addr_t &device_addr) .publish(boost::bind(&lms6002d_ctrl::get_rx_gain_range, ctrl, name)); _tree->create(rx_rf_fe_path / "gains" / name / "value") - .coerce(boost::bind(&lms6002d_ctrl::set_rx_gain, ctrl, _1, name)) + .coerce(boost::bind(&lms6002d_ctrl::set_rx_gain, ctrl, boost::placeholders::_1, name)) .set((ctrl->get_rx_gain_range(name).start() + ctrl->get_rx_gain_range(name).stop())/2.0); } @@ -608,7 +608,7 @@ umtrx_impl::umtrx_impl(const device_addr_t &device_addr) .publish(boost::bind(&lms6002d_ctrl::get_tx_gain_range, ctrl, name)); _tree->create(tx_rf_fe_path / "gains" / name / "value") - .coerce(boost::bind(&lms6002d_ctrl::set_tx_gain, ctrl, _1, name)) + .coerce(boost::bind(&lms6002d_ctrl::set_tx_gain, ctrl, boost::placeholders::_1, name)) .set((ctrl->get_tx_gain_range(name).start() + ctrl->get_tx_gain_range(name).stop())/2.0); } } else { @@ -623,7 +623,7 @@ umtrx_impl::umtrx_impl(const device_addr_t &device_addr) .publish(boost::bind(&umtrx_impl::get_tx_power_range, this, fe_name)); _tree->create(tx_rf_fe_path / "gains" / "PA" / "value") - .coerce(boost::bind(&umtrx_impl::set_tx_power, this, _1, fe_name)) + .coerce(boost::bind(&umtrx_impl::set_tx_power, this, boost::placeholders::_1, fe_name)) // Set default output power to maximum .set(get_tx_power_range(fe_name).stop()); @@ -631,14 +631,14 @@ umtrx_impl::umtrx_impl(const device_addr_t &device_addr) //rx freq _tree->create(rx_rf_fe_path / "freq" / "value") - .coerce(boost::bind(&umtrx_impl::set_rx_freq, this, fe_name, _1)); + .coerce(boost::bind(&umtrx_impl::set_rx_freq, this, fe_name, boost::placeholders::_1)); _tree->create(rx_rf_fe_path / "freq" / "range") .publish(boost::bind(&umtrx_impl::get_rx_freq_range, this, fe_name)); _tree->create(rx_rf_fe_path / "use_lo_offset").set(false); //tx freq _tree->create(tx_rf_fe_path / "freq" / "value") - .coerce(boost::bind(&lms6002d_ctrl::set_tx_freq, ctrl, _1)); + .coerce(boost::bind(&lms6002d_ctrl::set_tx_freq, ctrl, boost::placeholders::_1)); _tree->create(tx_rf_fe_path / "freq" / "range") .publish(boost::bind(&lms6002d_ctrl::get_tx_freq_range, ctrl)); _tree->create(tx_rf_fe_path / "use_lo_offset").set(false); @@ -647,34 +647,34 @@ umtrx_impl::umtrx_impl(const device_addr_t &device_addr) _tree->create >(rx_rf_fe_path / "antenna" / "options") .publish(boost::bind(&lms6002d_ctrl::get_rx_antennas, ctrl)); _tree->create(rx_rf_fe_path / "antenna" / "value") - .subscribe(boost::bind(&lms6002d_ctrl::set_rx_ant, ctrl, _1)) + .subscribe(boost::bind(&lms6002d_ctrl::set_rx_ant, ctrl, boost::placeholders::_1)) .set("RX1"); //tx ant _tree->create >(tx_rf_fe_path / "antenna" / "options") .publish(boost::bind(&lms6002d_ctrl::get_tx_antennas, ctrl)); _tree->create(tx_rf_fe_path / "antenna" / "value") - .subscribe(boost::bind(&lms6002d_ctrl::set_tx_ant, ctrl, _1)) + .subscribe(boost::bind(&lms6002d_ctrl::set_tx_ant, ctrl, boost::placeholders::_1)) .set("TX2"); //misc _tree->create(rx_rf_fe_path / "connection").set("IQ"); _tree->create(tx_rf_fe_path / "connection").set("IQ"); _tree->create(rx_rf_fe_path / "enabled") - .coerce(boost::bind(&lms6002d_ctrl::set_rx_enabled, ctrl, _1)); + .coerce(boost::bind(&lms6002d_ctrl::set_rx_enabled, ctrl, boost::placeholders::_1)); _tree->create(tx_rf_fe_path / "enabled") - .coerce(boost::bind(&lms6002d_ctrl::set_tx_enabled, ctrl, _1)); + .coerce(boost::bind(&lms6002d_ctrl::set_tx_enabled, ctrl, boost::placeholders::_1)); //rx bw _tree->create(rx_rf_fe_path / "bandwidth" / "value") - .coerce(boost::bind(&lms6002d_ctrl::set_rx_bandwidth, ctrl, _1)) + .coerce(boost::bind(&lms6002d_ctrl::set_rx_bandwidth, ctrl, boost::placeholders::_1)) .set(2*0.75e6); _tree->create(rx_rf_fe_path / "bandwidth" / "range") .publish(boost::bind(&lms6002d_ctrl::get_rx_bw_range, ctrl)); //tx bw _tree->create(tx_rf_fe_path / "bandwidth" / "value") - .coerce(boost::bind(&lms6002d_ctrl::set_tx_bandwidth, ctrl, _1)) + .coerce(boost::bind(&lms6002d_ctrl::set_tx_bandwidth, ctrl, boost::placeholders::_1)) .set(2*0.75e6); _tree->create(tx_rf_fe_path / "bandwidth" / "range") .publish(boost::bind(&lms6002d_ctrl::get_tx_bw_range, ctrl)); @@ -682,17 +682,17 @@ umtrx_impl::umtrx_impl(const device_addr_t &device_addr) //bind frontend corrections to the dboard freq props _tree->access(tx_rf_fe_path / "freq" / "value") .set(0.0) //default value - .subscribe(boost::bind(&umtrx_impl::set_tx_fe_corrections, this, "0", fe_name, _1)); + .subscribe(boost::bind(&umtrx_impl::set_tx_fe_corrections, this, "0", fe_name, boost::placeholders::_1)); _tree->access(rx_rf_fe_path / "freq" / "value") .set(0.0) //default value - .subscribe(boost::bind(&umtrx_impl::set_rx_fe_corrections, this, "0", fe_name, _1)); + .subscribe(boost::bind(&umtrx_impl::set_rx_fe_corrections, this, "0", fe_name, boost::placeholders::_1)); //tx cal props _tree->create(tx_rf_fe_path / "lms6002d" / "tx_dc_i" / "value") - .subscribe(boost::bind(&lms6002d_ctrl::_set_tx_vga1dc_i_int, ctrl, _1)) + .subscribe(boost::bind(&lms6002d_ctrl::_set_tx_vga1dc_i_int, ctrl, boost::placeholders::_1)) .publish(boost::bind(&lms6002d_ctrl::get_tx_vga1dc_i_int, ctrl)); _tree->create(tx_rf_fe_path / "lms6002d" / "tx_dc_q" / "value") - .subscribe(boost::bind(&lms6002d_ctrl::_set_tx_vga1dc_q_int, ctrl, _1)) + .subscribe(boost::bind(&lms6002d_ctrl::_set_tx_vga1dc_q_int, ctrl, boost::placeholders::_1)) .publish(boost::bind(&lms6002d_ctrl::get_tx_vga1dc_q_int, ctrl)); //set Tx DC calibration values, which are read from mboard EEPROM @@ -705,37 +705,37 @@ umtrx_impl::umtrx_impl(const device_addr_t &device_addr) //plugin dc_offset from lms into the frontend corrections _tree->create >(mb_path / "tx_frontends" / fe_name / "dc_offset" / "value") .publish(boost::bind(&umtrx_impl::get_dc_offset_correction, this, fe_name)) - .subscribe(boost::bind(&umtrx_impl::set_dc_offset_correction, this, fe_name, _1)) + .subscribe(boost::bind(&umtrx_impl::set_dc_offset_correction, this, fe_name, boost::placeholders::_1)) .set(std::complex(dc_i, dc_q)); //rx cal props _tree->create(rx_rf_fe_path / "lms6002d" / "rx_fe_dc_i" / "value") .publish(boost::bind(&lms6002d_ctrl::get_rxfe_dc_i, ctrl)) - .subscribe(boost::bind(&lms6002d_ctrl::set_rxfe_dc_i, ctrl, _1)); + .subscribe(boost::bind(&lms6002d_ctrl::set_rxfe_dc_i, ctrl, boost::placeholders::_1)); _tree->create(rx_rf_fe_path / "lms6002d" / "rx_fe_dc_q" / "value") .publish(boost::bind(&lms6002d_ctrl::get_rxfe_dc_q, ctrl)) - .subscribe(boost::bind(&lms6002d_ctrl::set_rxfe_dc_q, ctrl, _1)); + .subscribe(boost::bind(&lms6002d_ctrl::set_rxfe_dc_q, ctrl, boost::placeholders::_1)); _tree->create(rx_rf_fe_path / "lms6002d" / "rx_lpf_dc_i" / "value") .publish(boost::bind(&lms6002d_ctrl::get_rxlpf_dc_i, ctrl)) - .subscribe(boost::bind(&lms6002d_ctrl::set_rxlpf_dc_i, ctrl, _1)); + .subscribe(boost::bind(&lms6002d_ctrl::set_rxlpf_dc_i, ctrl, boost::placeholders::_1)); _tree->create(rx_rf_fe_path / "lms6002d" / "rx_lpf_dc_q" / "value") .publish(boost::bind(&lms6002d_ctrl::get_rxlpf_dc_q, ctrl)) - .subscribe(boost::bind(&lms6002d_ctrl::set_rxlpf_dc_q, ctrl, _1)); + .subscribe(boost::bind(&lms6002d_ctrl::set_rxlpf_dc_q, ctrl, boost::placeholders::_1)); _tree->create(rx_rf_fe_path / "lms6002d" / "rxvga2_dc_reference" / "value") .publish(boost::bind(&lms6002d_ctrl::get_rxvga2_dc_reference, ctrl)) - .subscribe(boost::bind(&lms6002d_ctrl::set_rxvga2_dc_reference, ctrl, _1)); + .subscribe(boost::bind(&lms6002d_ctrl::set_rxvga2_dc_reference, ctrl, boost::placeholders::_1)); _tree->create(rx_rf_fe_path / "lms6002d" / "rxvga2a_dc_i" / "value") .publish(boost::bind(&lms6002d_ctrl::get_rxvga2a_dc_i, ctrl)) - .subscribe(boost::bind(&lms6002d_ctrl::set_rxvga2a_dc_i, ctrl, _1)); + .subscribe(boost::bind(&lms6002d_ctrl::set_rxvga2a_dc_i, ctrl, boost::placeholders::_1)); _tree->create(rx_rf_fe_path / "lms6002d" / "rxvga2a_dc_q" / "value") .publish(boost::bind(&lms6002d_ctrl::get_rxvga2a_dc_q, ctrl)) - .subscribe(boost::bind(&lms6002d_ctrl::set_rxvga2a_dc_q, ctrl, _1)); + .subscribe(boost::bind(&lms6002d_ctrl::set_rxvga2a_dc_q, ctrl, boost::placeholders::_1)); _tree->create(rx_rf_fe_path / "lms6002d" / "rxvga2b_dc_i" / "value") .publish(boost::bind(&lms6002d_ctrl::get_rxvga2b_dc_i, ctrl)) - .subscribe(boost::bind(&lms6002d_ctrl::set_rxvga2b_dc_i, ctrl, _1)); + .subscribe(boost::bind(&lms6002d_ctrl::set_rxvga2b_dc_i, ctrl, boost::placeholders::_1)); _tree->create(rx_rf_fe_path / "lms6002d" / "rxvga2b_dc_q" / "value") .publish(boost::bind(&lms6002d_ctrl::get_rxvga2b_dc_q, ctrl)) - .subscribe(boost::bind(&lms6002d_ctrl::set_rxvga2b_dc_q, ctrl, _1)); + .subscribe(boost::bind(&lms6002d_ctrl::set_rxvga2b_dc_q, ctrl, boost::placeholders::_1)); // Alias diversity switch control from mb_path property_alias(_tree, mb_path / "divsw"+(fe_name=="A"?"1":"2"), rx_rf_fe_path / "diversity"); @@ -743,7 +743,7 @@ umtrx_impl::umtrx_impl(const device_addr_t &device_addr) //TCXO DAC calibration control _tree->create(mb_path / "tcxo_dac" / "value") - .subscribe(boost::bind(&umtrx_impl::set_tcxo_dac, this, _iface, _1)); + .subscribe(boost::bind(&umtrx_impl::set_tcxo_dac, this, _iface, boost::placeholders::_1)); //////////////////////////////////////////////////////////////////// // post config tasks @@ -1103,7 +1103,7 @@ void umtrx_impl::detect_hw_rev(const fs_path& mb_path) _hw_rev = UMTRX_VER_2_3_1; _tree->create(mb_path / "pa_dcdc_r") - .subscribe(boost::bind(&umtrx_impl::set_pa_dcdc_r, this, _1)); + .subscribe(boost::bind(&umtrx_impl::set_pa_dcdc_r, this, boost::placeholders::_1)); std::string pa_dcdc_r = _iface->mb_eeprom.get("pa_dcdc_r", ""); char* pa_dcdc_r_env = getenv("UMTRX_PA_DCDC_R"); @@ -1138,11 +1138,11 @@ void umtrx_impl::detect_hw_rev(const fs_path& mb_path) _pa_nlow = (boost::lexical_cast(pa_low) == 0); _tree->create(mb_path / "pa_en1") - .subscribe(boost::bind(&umtrx_impl::set_enpa1, this, _1)); + .subscribe(boost::bind(&umtrx_impl::set_enpa1, this, boost::placeholders::_1)); _tree->create(mb_path / "pa_en2") - .subscribe(boost::bind(&umtrx_impl::set_enpa2, this, _1)); + .subscribe(boost::bind(&umtrx_impl::set_enpa2, this, boost::placeholders::_1)); _tree->create(mb_path / "pa_nlow") - .subscribe(boost::bind(&umtrx_impl::set_nlow, this, _1)); + .subscribe(boost::bind(&umtrx_impl::set_nlow, this, boost::placeholders::_1)); commit_pa_state(); UHD_MSG(status) << "PA low=`" << pa_low.c_str() diff --git a/host/umtrx_io_impl.cpp b/host/umtrx_io_impl.cpp index a9e810b3c..8d7571967 100644 --- a/host/umtrx_io_impl.cpp +++ b/host/umtrx_io_impl.cpp @@ -249,10 +249,10 @@ uhd::rx_streamer::sptr umtrx_impl::get_rx_stream(const uhd::stream_args_t &args_ _rx_dsps[dsp]->set_nsamps_per_packet(spp); //seems to be a good place to set this _rx_dsps[dsp]->setup(args); my_streamer->set_xport_chan_get_buff(chan_i, boost::bind( - &zero_copy_if::get_recv_buff, xports[chan_i], _1 + &zero_copy_if::get_recv_buff, xports[chan_i], boost::placeholders::_1 ), true /*flush*/); my_streamer->set_issue_stream_cmd(chan_i, boost::bind( - &rx_dsp_core_200::issue_stream_command, _rx_dsps[dsp], _1)); + &rx_dsp_core_200::issue_stream_command, _rx_dsps[dsp], boost::placeholders::_1)); _rx_streamers[dsp] = my_streamer; //store weak pointer } @@ -471,7 +471,7 @@ uhd::tx_streamer::sptr umtrx_impl::get_tx_stream(const uhd::stream_args_t &args_ //shared async queue for all channels in streamer boost::shared_ptr async_md(new async_md_type(1000/*messages deep*/)); if (not _old_async_queue) _old_async_queue.reset(new async_md_type(1000/*messages deep*/)); - my_streamer->set_async_receiver(boost::bind(&async_md_type::pop_with_timed_wait, async_md, _1, _2)); + my_streamer->set_async_receiver(boost::bind(&async_md_type::pop_with_timed_wait, async_md, boost::placeholders::_1, boost::placeholders::_2)); //bind callbacks for the handler for (size_t chan_i = 0; chan_i < args.channels.size(); chan_i++) @@ -506,7 +506,7 @@ uhd::tx_streamer::sptr umtrx_impl::get_tx_stream(const uhd::stream_args_t &args_ //buffer get method handles flow control and hold task reference count my_streamer->set_xport_chan_get_buff(chan_i, boost::bind( - &get_send_buff, task, fc_mon, xports[chan_i], _1 + &get_send_buff, task, fc_mon, xports[chan_i], boost::placeholders::_1 )); _tx_streamers[dsp] = my_streamer; //store weak pointer