From 7a2a857730588f19fe8ebe3f381136996682cc16 Mon Sep 17 00:00:00 2001 From: vsonnier Date: Fri, 1 Mar 2019 06:57:32 +0100 Subject: [PATCH] Fix wrong remote:scale argument parsing --- client/Streaming.cpp | 2 +- common/SoapyRemoteDefs.hpp | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/client/Streaming.cpp b/client/Streaming.cpp index c1b4fef..6d3b479 100644 --- a/client/Streaming.cpp +++ b/client/Streaming.cpp @@ -188,7 +188,7 @@ SoapySDR::Stream *SoapyRemoteDevice::setupStream( //use the native scale factor when the remote format is native, //otherwise the default scale factor is the max signed integer double scaleFactor = (remoteFormat == nativeFormat)?nativeScaleFactor:double(1 << ((SoapySDR::formatToSize(remoteFormat)*4)-1)); - const auto scaleFactorIt = args.find(SOAPY_REMOTE_KWARG_SCALAR); + const auto scaleFactorIt = args.find(SOAPY_REMOTE_KWARG_SCALE); if (scaleFactorIt != args.end()) scaleFactor = std::stod(scaleFactorIt->second); //determine reliable stream mode with tcp or datagram mode diff --git a/common/SoapyRemoteDefs.hpp b/common/SoapyRemoteDefs.hpp index 4686e09..1b6d142 100644 --- a/common/SoapyRemoteDefs.hpp +++ b/common/SoapyRemoteDefs.hpp @@ -17,8 +17,8 @@ //! Stream args key to set the format on the remote server #define SOAPY_REMOTE_KWARG_FORMAT (SOAPY_REMOTE_KWARG_PREFIX "format") -//! Stream args key to set the scalar for local float conversions -#define SOAPY_REMOTE_KWARG_SCALAR (SOAPY_REMOTE_KWARG_PREFIX "scalar") +//! Stream args key to set the scale for local float conversions +#define SOAPY_REMOTE_KWARG_SCALE (SOAPY_REMOTE_KWARG_PREFIX "scale") //! Stream args key to set the buffer MTU bytes for network transfers #define SOAPY_REMOTE_KWARG_MTU (SOAPY_REMOTE_KWARG_PREFIX "mtu")