From 9b0203901bc83a07c4ce281f7d0c2e7f825f77a5 Mon Sep 17 00:00:00 2001 From: "Matthias P. Braendli" Date: Sun, 7 Jan 2018 11:26:50 +0100 Subject: OFDM windowing, fix erroneous assignment in assertion --- src/GuardIntervalInserter.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src') diff --git a/src/GuardIntervalInserter.cpp b/src/GuardIntervalInserter.cpp index 14027d3..afb9213 100644 --- a/src/GuardIntervalInserter.cpp +++ b/src/GuardIntervalInserter.cpp @@ -201,7 +201,7 @@ int GuardIntervalInserter::process(Buffer* const dataIn, Buffer* dataOut) memcpy( &out[ox], &in[ix], remaining_prefix_length * sizeof(complexf)); ox += remaining_prefix_length; - assert(ox = end_cyclic_prefix_ox); + assert(ox == end_cyclic_prefix_ox); ix = 0; const bool last_symbol = (sym_ix + 1 >= d_nbSymbols); -- cgit v1.2.3 From 95f556cf0797ab4c23f431e5c8c5accfa7f4c30b Mon Sep 17 00:00:00 2001 From: "Matthias P. Braendli" Date: Sun, 7 Jan 2018 11:30:04 +0100 Subject: Fix a few minor mistakes --- src/DabModulator.cpp | 6 +++--- src/DabModulator.h | 3 ++- src/FrequencyInterleaver.h | 10 ++++------ src/RemoteControl.h | 6 +++--- src/TimestampDecoder.h | 2 +- 5 files changed, 13 insertions(+), 14 deletions(-) (limited to 'src') diff --git a/src/DabModulator.cpp b/src/DabModulator.cpp index 0818f4f..8ba8af6 100644 --- a/src/DabModulator.cpp +++ b/src/DabModulator.cpp @@ -240,7 +240,7 @@ int DabModulator::process(Buffer* dataOut) //////////////////////////////////////////////////////////////// // Data initialisation //////////////////////////////////////////////////////////////// - myFicSizeIn = fic->getFramesize(); + size_t ficSizeIn = fic->getFramesize(); //////////////////////////////////////////////////////////////// // Modules configuration @@ -252,10 +252,10 @@ int DabModulator::process(Buffer* dataOut) PDEBUG(" Framesize: %zu\n", fic->getFramesize()); // Configuring prbs generator - auto ficPrbs = make_shared(myFicSizeIn, 0x110); + auto ficPrbs = make_shared(ficSizeIn, 0x110); // Configuring convolutionnal encoder - auto ficConv = make_shared(myFicSizeIn); + auto ficConv = make_shared(ficSizeIn); // Configuring puncturing encoder auto ficPunc = make_shared(); diff --git a/src/DabModulator.h b/src/DabModulator.h index 6878853..2d7bc35 100644 --- a/src/DabModulator.h +++ b/src/DabModulator.h @@ -72,6 +72,7 @@ protected: size_t myNullSize; size_t mySymSize; size_t myFicSizeOut; - size_t myFicSizeIn; + + std::shared_ptr myOutput; }; diff --git a/src/FrequencyInterleaver.h b/src/FrequencyInterleaver.h index 7c0fb22..43ca21a 100644 --- a/src/FrequencyInterleaver.h +++ b/src/FrequencyInterleaver.h @@ -36,16 +36,14 @@ class FrequencyInterleaver : public ModCodec public: FrequencyInterleaver(size_t mode); virtual ~FrequencyInterleaver(); - FrequencyInterleaver(const FrequencyInterleaver&); - FrequencyInterleaver& operator=(const FrequencyInterleaver&); + FrequencyInterleaver(const FrequencyInterleaver&) = delete; + FrequencyInterleaver& operator=(const FrequencyInterleaver&) = delete; - - int process(Buffer* const dataIn, Buffer* dataOut); - const char* name() { return "FrequencyInterleaver"; } + int process(Buffer* const dataIn, Buffer* dataOut) override; + const char* name() override { return "FrequencyInterleaver"; } protected: size_t d_carriers; - size_t d_num; size_t* d_indexes; }; diff --git a/src/RemoteControl.h b/src/RemoteControl.h index 013738b..11cd52c 100644 --- a/src/RemoteControl.h +++ b/src/RemoteControl.h @@ -94,7 +94,7 @@ class BaseRemoteController { class RemoteControllable { public: RemoteControllable(const std::string& name) : - m_name(name) {} + m_rc_name(name) {} RemoteControllable(const RemoteControllable& other) = delete; RemoteControllable& operator=(const RemoteControllable& other) = delete; @@ -105,7 +105,7 @@ class RemoteControllable { * It might be used in the commands the user has to type, so keep * it short */ - virtual std::string get_rc_name() const { return m_name; } + virtual std::string get_rc_name() const { return m_rc_name; } /* Return a list of possible parameters that can be set */ virtual std::list get_supported_parameters() const; @@ -126,7 +126,7 @@ class RemoteControllable { virtual const std::string get_parameter(const std::string& parameter) const = 0; protected: - std::string m_name; + std::string m_rc_name; std::list< std::vector > m_parameters; }; diff --git a/src/TimestampDecoder.h b/src/TimestampDecoder.h index 943b241..db8f816 100644 --- a/src/TimestampDecoder.h +++ b/src/TimestampDecoder.h @@ -48,7 +48,7 @@ struct frame_timestamp frame_timestamp() = default; frame_timestamp(const frame_timestamp& other) = default; - frame_timestamp operator=(const frame_timestamp &rhs) + frame_timestamp& operator=(const frame_timestamp &rhs) { if (this != &rhs) { this->timestamp_sec = rhs.timestamp_sec; -- cgit v1.2.3