summaryrefslogtreecommitdiffstats
path: root/src/OfdmGenerator.cpp
diff options
context:
space:
mode:
authorMatthias P. Braendli <matthias.braendli@mpb.li>2018-08-07 11:29:47 +0200
committerMatthias P. Braendli <matthias.braendli@mpb.li>2018-08-07 11:29:47 +0200
commitb6e9577aaed919975f32ee1a5a9821668089f2db (patch)
tree18d3c0ebdc5db92a7caa5931c8171787932f333c /src/OfdmGenerator.cpp
parente68fa7c6cb9a718ec16cf849e5885e1ca9b3cf3d (diff)
downloaddabmod-b6e9577aaed919975f32ee1a5a9821668089f2db.tar.gz
dabmod-b6e9577aaed919975f32ee1a5a9821668089f2db.tar.bz2
dabmod-b6e9577aaed919975f32ee1a5a9821668089f2db.zip
Keep RC-modified settings across modulator restarts
Diffstat (limited to 'src/OfdmGenerator.cpp')
-rw-r--r--src/OfdmGenerator.cpp9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/OfdmGenerator.cpp b/src/OfdmGenerator.cpp
index 9a824ec..d9c3608 100644
--- a/src/OfdmGenerator.cpp
+++ b/src/OfdmGenerator.cpp
@@ -40,9 +40,9 @@ static const size_t MAX_CLIP_STATS = 10;
OfdmGenerator::OfdmGenerator(size_t nbSymbols,
size_t nbCarriers,
size_t spacing,
- bool enableCfr,
- float cfrClip,
- float cfrErrorClip,
+ bool& enableCfr,
+ float& cfrClip,
+ float& cfrErrorClip,
bool inverse) :
ModCodec(), RemoteControllable("ofdm"),
myFftPlan(nullptr),
@@ -197,10 +197,9 @@ int OfdmGenerator::process(Buffer* const dataIn, Buffer* dataOut)
// The PAPRStats' clear() is not threadsafe, do not access it
// from the RC functions.
- if (myPaprClearRequest.load()) {
+ if (myPaprClearRequest.exchange(false)) {
myPaprBeforeCFR.clear();
myPaprAfterCFR.clear();
- myPaprClearRequest.store(false);
}
for (size_t i = 0; i < myNbSymbols; ++i) {