aboutsummaryrefslogtreecommitdiffstats
path: root/host/lib/usrp/common/adf4001_ctrl.cpp
diff options
context:
space:
mode:
authorMartin Braun <martin.braun@ettus.com>2016-10-31 14:30:52 -0700
committerMartin Braun <martin.braun@ettus.com>2016-11-08 08:02:22 -0800
commit99c2730bc9db270560671f2d7d173768465ed51f (patch)
treebc4df495734a075ebe2f7917cf67dec6fb7d8177 /host/lib/usrp/common/adf4001_ctrl.cpp
parent218f4b0b63927110df9dbbaa8353c346eee2d98a (diff)
downloaduhd-99c2730bc9db270560671f2d7d173768465ed51f.tar.gz
uhd-99c2730bc9db270560671f2d7d173768465ed51f.tar.bz2
uhd-99c2730bc9db270560671f2d7d173768465ed51f.zip
Remove all boost:: namespace prefix for uint32_t, int32_t etc. (fixed-width types)
- Also removes all references to boost/cstdint.hpp and replaces it with stdint.h (The 'correct' replacement would be <cstdint>, but not all of our compilers support that).
Diffstat (limited to 'host/lib/usrp/common/adf4001_ctrl.cpp')
-rw-r--r--host/lib/usrp/common/adf4001_ctrl.cpp60
1 files changed, 30 insertions, 30 deletions
diff --git a/host/lib/usrp/common/adf4001_ctrl.cpp b/host/lib/usrp/common/adf4001_ctrl.cpp
index 001b68b7a..01a35dbec 100644
--- a/host/lib/usrp/common/adf4001_ctrl.cpp
+++ b/host/lib/usrp/common/adf4001_ctrl.cpp
@@ -47,47 +47,47 @@ adf4001_regs_t::adf4001_regs_t(void) {
}
-boost::uint32_t adf4001_regs_t::get_reg(boost::uint8_t addr) {
- boost::uint32_t reg = 0;
+uint32_t adf4001_regs_t::get_reg(uint8_t addr) {
+ uint32_t reg = 0;
switch (addr) {
case 0:
- reg |= (boost::uint32_t(ref_counter) & 0x003FFF) << 2;
- reg |= (boost::uint32_t(anti_backlash_width) & 0x000003) << 16;
- reg |= (boost::uint32_t(lock_detect_precision) & 0x000001) << 20;
+ reg |= (uint32_t(ref_counter) & 0x003FFF) << 2;
+ reg |= (uint32_t(anti_backlash_width) & 0x000003) << 16;
+ reg |= (uint32_t(lock_detect_precision) & 0x000001) << 20;
break;
case 1:
- reg |= (boost::uint32_t(n) & 0x001FFF) << 8;
- reg |= (boost::uint32_t(charge_pump_gain) & 0x000001) << 21;
+ reg |= (uint32_t(n) & 0x001FFF) << 8;
+ reg |= (uint32_t(charge_pump_gain) & 0x000001) << 21;
break;
case 2:
- reg |= (boost::uint32_t(counter_reset) & 0x000001) << 2;
- reg |= (boost::uint32_t(power_down) & 0x000001) << 3;
- reg |= (boost::uint32_t(muxout) & 0x000007) << 4;
- reg |= (boost::uint32_t(phase_detector_polarity) & 0x000001) << 7;
- reg |= (boost::uint32_t(charge_pump_mode) & 0x000001) << 8;
- reg |= (boost::uint32_t(fastlock_mode) & 0x000003) << 9;
- reg |= (boost::uint32_t(timer_counter_control) & 0x00000F) << 11;
- reg |= (boost::uint32_t(charge_pump_current_1) & 0x000007) << 15;
- reg |= (boost::uint32_t(charge_pump_current_2) & 0x000007) << 18;
- reg |= (boost::uint32_t(power_down) & 0x000002) << 21;
+ reg |= (uint32_t(counter_reset) & 0x000001) << 2;
+ reg |= (uint32_t(power_down) & 0x000001) << 3;
+ reg |= (uint32_t(muxout) & 0x000007) << 4;
+ reg |= (uint32_t(phase_detector_polarity) & 0x000001) << 7;
+ reg |= (uint32_t(charge_pump_mode) & 0x000001) << 8;
+ reg |= (uint32_t(fastlock_mode) & 0x000003) << 9;
+ reg |= (uint32_t(timer_counter_control) & 0x00000F) << 11;
+ reg |= (uint32_t(charge_pump_current_1) & 0x000007) << 15;
+ reg |= (uint32_t(charge_pump_current_2) & 0x000007) << 18;
+ reg |= (uint32_t(power_down) & 0x000002) << 21;
break;
case 3:
- reg |= (boost::uint32_t(counter_reset) & 0x000001) << 2;
- reg |= (boost::uint32_t(power_down) & 0x000001) << 3;
- reg |= (boost::uint32_t(muxout) & 0x000007) << 4;
- reg |= (boost::uint32_t(phase_detector_polarity) & 0x000001) << 7;
- reg |= (boost::uint32_t(charge_pump_mode) & 0x000001) << 8;
- reg |= (boost::uint32_t(fastlock_mode) & 0x000003) << 9;
- reg |= (boost::uint32_t(timer_counter_control) & 0x00000F) << 11;
- reg |= (boost::uint32_t(charge_pump_current_1) & 0x000007) << 15;
- reg |= (boost::uint32_t(charge_pump_current_2) & 0x000007) << 18;
- reg |= (boost::uint32_t(power_down) & 0x000002) << 20;
+ reg |= (uint32_t(counter_reset) & 0x000001) << 2;
+ reg |= (uint32_t(power_down) & 0x000001) << 3;
+ reg |= (uint32_t(muxout) & 0x000007) << 4;
+ reg |= (uint32_t(phase_detector_polarity) & 0x000001) << 7;
+ reg |= (uint32_t(charge_pump_mode) & 0x000001) << 8;
+ reg |= (uint32_t(fastlock_mode) & 0x000003) << 9;
+ reg |= (uint32_t(timer_counter_control) & 0x00000F) << 11;
+ reg |= (uint32_t(charge_pump_current_1) & 0x000007) << 15;
+ reg |= (uint32_t(charge_pump_current_2) & 0x000007) << 18;
+ reg |= (uint32_t(power_down) & 0x000002) << 20;
break;
default:
break;
}
- reg |= (boost::uint32_t(addr) & 0x03);
+ reg |= (uint32_t(addr) & 0x03);
return reg;
}
@@ -140,8 +140,8 @@ void adf4001_ctrl::program_regs(void) {
}
-void adf4001_ctrl::write_reg(boost::uint8_t addr) {
- boost::uint32_t reg = adf4001_regs.get_reg(addr); //load the reg data
+void adf4001_ctrl::write_reg(uint8_t addr) {
+ uint32_t reg = adf4001_regs.get_reg(addr); //load the reg data
spi_iface->transact_spi(slaveno,
spi_config,