aboutsummaryrefslogtreecommitdiffstats
path: root/host/lib/usrp/misc_utils.cpp
diff options
context:
space:
mode:
authorJosh Blum <josh@joshknows.com>2011-01-11 19:46:45 -0800
committerJosh Blum <josh@joshknows.com>2011-01-11 19:46:45 -0800
commit395bbbbc1118b061262a10d5c847f17a4fd0c6ae (patch)
tree6347a18702529cfd42dcb94c37ce2866b49b93f4 /host/lib/usrp/misc_utils.cpp
parent18defbd9d40a4c11a33025c8684f48fe51f102c5 (diff)
downloaduhd-395bbbbc1118b061262a10d5c847f17a4fd0c6ae.tar.gz
uhd-395bbbbc1118b061262a10d5c847f17a4fd0c6ae.tar.bz2
uhd-395bbbbc1118b061262a10d5c847f17a4fd0c6ae.zip
uhd: replace all the instances of float not pertaining to io types with double, simplifies life
Diffstat (limited to 'host/lib/usrp/misc_utils.cpp')
-rw-r--r--host/lib/usrp/misc_utils.cpp20
1 files changed, 10 insertions, 10 deletions
diff --git a/host/lib/usrp/misc_utils.cpp b/host/lib/usrp/misc_utils.cpp
index 5856d706f..0385187eb 100644
--- a/host/lib/usrp/misc_utils.cpp
+++ b/host/lib/usrp/misc_utils.cpp
@@ -39,24 +39,24 @@ static gain_range_t get_codec_gain_range(wax::obj codec, const std::string &name
return codec[named_prop_t(CODEC_PROP_GAIN_RANGE, name)].as<gain_range_t>();
}
-static float get_codec_gain_i(wax::obj codec, const std::string &name){
- return codec[named_prop_t(CODEC_PROP_GAIN_I, name)].as<float>();
+static double get_codec_gain_i(wax::obj codec, const std::string &name){
+ return codec[named_prop_t(CODEC_PROP_GAIN_I, name)].as<double>();
}
-static float get_codec_gain_q(wax::obj codec, const std::string &name){
- return codec[named_prop_t(CODEC_PROP_GAIN_Q, name)].as<float>();
+static double get_codec_gain_q(wax::obj codec, const std::string &name){
+ return codec[named_prop_t(CODEC_PROP_GAIN_Q, name)].as<double>();
}
-static void set_codec_gain_both(wax::obj codec, const std::string &name, float gain){
+static void set_codec_gain_both(wax::obj codec, const std::string &name, double gain){
codec[named_prop_t(CODEC_PROP_GAIN_I, name)] = gain;
codec[named_prop_t(CODEC_PROP_GAIN_Q, name)] = gain;
}
-static void set_codec_gain_i(wax::obj codec, const std::string &name, float gain){
+static void set_codec_gain_i(wax::obj codec, const std::string &name, double gain){
codec[named_prop_t(CODEC_PROP_GAIN_I, name)] = gain;
}
-static void set_codec_gain_q(wax::obj codec, const std::string &name, float gain){
+static void set_codec_gain_q(wax::obj codec, const std::string &name, double gain){
codec[named_prop_t(CODEC_PROP_GAIN_Q, name)] = gain;
}
@@ -64,15 +64,15 @@ static void set_codec_gain_q(wax::obj codec, const std::string &name, float gain
* subdev gain group helper functions:
* do this so we dont have to bind a templated function
**********************************************************************/
-static float get_subdev_gain(wax::obj subdev, const std::string &name){
- return subdev[named_prop_t(SUBDEV_PROP_GAIN, name)].as<float>();
+static double get_subdev_gain(wax::obj subdev, const std::string &name){
+ return subdev[named_prop_t(SUBDEV_PROP_GAIN, name)].as<double>();
}
static gain_range_t get_subdev_gain_range(wax::obj subdev, const std::string &name){
return subdev[named_prop_t(SUBDEV_PROP_GAIN_RANGE, name)].as<gain_range_t>();
}
-static void set_subdev_gain(wax::obj subdev, const std::string &name, float gain){
+static void set_subdev_gain(wax::obj subdev, const std::string &name, double gain){
subdev[named_prop_t(SUBDEV_PROP_GAIN, name)] = gain;
}