diff --git a/ft8/ft8.h b/ft8/ft8.h index 326edc5f2..2e84f3ac3 100644 --- a/ft8/ft8.h +++ b/ft8/ft8.h @@ -85,8 +85,9 @@ struct FT8_API cdecode // total transmission time is 12.64 seconds // tunable parameters -struct FT8_API FT8Params +class FT8_API FT8Params { +public: int nthreads; // number of parallel threads, for multi-core int npasses_one; // number of spectral subtraction passes int npasses_two; // number of spectral subtraction passes diff --git a/httpserver/httpconnectionhandlerpool.cpp b/httpserver/httpconnectionhandlerpool.cpp index 6de3a2e0e..27314ef29 100644 --- a/httpserver/httpconnectionhandlerpool.cpp +++ b/httpserver/httpconnectionhandlerpool.cpp @@ -94,7 +94,7 @@ void HttpConnectionHandlerPool::cleanup() if (++idleCounter > maxIdleHandlers) { pool.removeOne(handler); - qDebug("HttpConnectionHandlerPool: Removed connection handler (%p), pool size is now %i",handler,pool.size()); + qDebug("HttpConnectionHandlerPool: Removed connection handler (%p), pool size is now %i",handler,(int)pool.size()); delete handler; break; // remove only one handler in each interval } diff --git a/httpserver/staticfilecontroller.cpp b/httpserver/staticfilecontroller.cpp index 7db2c9563..686bff1f5 100644 --- a/httpserver/staticfilecontroller.cpp +++ b/httpserver/staticfilecontroller.cpp @@ -35,7 +35,7 @@ StaticFileController::StaticFileController(QSettings* settings, QObject* parent) maxCachedFileSize=settings->value("maxCachedFileSize","65536").toInt(); cache.setMaxCost(settings->value("cacheSize","1000000").toInt()); cacheTimeout=settings->value("cacheTime","60000").toInt(); - qDebug("StaticFileController: cache timeout=%i, size=%i",cacheTimeout,cache.maxCost()); + qDebug("StaticFileController: cache timeout=%i, size=%i",cacheTimeout,(int)cache.maxCost()); } StaticFileController::StaticFileController(const HttpDocrootSettings& settings, QObject* parent) @@ -56,7 +56,7 @@ StaticFileController::StaticFileController(const HttpDocrootSettings& settings, maxCachedFileSize=settings.maxCachedFileSize; cache.setMaxCost(settings.cacheSize); cacheTimeout=settings.cacheTime; - qDebug("StaticFileController: cache timeout=%i, size=%i",cacheTimeout,cache.maxCost()); + qDebug("StaticFileController: cache timeout=%i, size=%i",cacheTimeout,(int)cache.maxCost()); } void StaticFileController::service(HttpRequest& request, HttpResponse& response) diff --git a/modemm17/Util.h b/modemm17/Util.h index c446b6605..81a4a3209 100644 --- a/modemm17/Util.h +++ b/modemm17/Util.h @@ -239,7 +239,7 @@ constexpr T to_int(uint8_t v) { constexpr auto MAX_LOCAL_INPUT = (1 << (n - 1)); constexpr auto NEGATIVE_OFFSET = std::numeric_limits::type>::max() - (MAX_LOCAL_INPUT - 1); - T r = v & (1 << (n - 1)) ? NEGATIVE_OFFSET : 0; + T r = v & (1 << (n - 1)) ? (T)NEGATIVE_OFFSET : 0; return r + (v & (MAX_LOCAL_INPUT - 1)); } diff --git a/plugins/channelmimo/beamsteeringcwmod/beamsteeringcwmod.h b/plugins/channelmimo/beamsteeringcwmod/beamsteeringcwmod.h index fa2c614b3..052d1c704 100644 --- a/plugins/channelmimo/beamsteeringcwmod/beamsteeringcwmod.h +++ b/plugins/channelmimo/beamsteeringcwmod/beamsteeringcwmod.h @@ -158,8 +158,6 @@ private: BeamSteeringCWModBaseband* m_basebandSource; QMutex m_mutex; bool m_running; - BasebandSampleSink* m_spectrumSink; - BasebandSampleSink* m_scopeSink; BeamSteeringCWModSettings m_settings; MessageQueue *m_guiMessageQueue; //!< Input message queue to the GUI @@ -168,7 +166,6 @@ private: int64_t m_frequencyOffset; uint32_t m_basebandSampleRate; - int m_count0, m_count1; virtual bool handleMessage(const Message& cmd); //!< Processing of a message. Returns true if message has actually been processed void applySettings(const BeamSteeringCWModSettings& settings, bool force = false); diff --git a/plugins/channelmimo/doa2/doa2.h b/plugins/channelmimo/doa2/doa2.h index 236f90b29..35e391f30 100644 --- a/plugins/channelmimo/doa2/doa2.h +++ b/plugins/channelmimo/doa2/doa2.h @@ -177,7 +177,6 @@ private: int64_t m_frequencyOffset; uint32_t m_deviceSampleRate; qint64 m_deviceCenterFrequency; - int m_count0, m_count1; virtual bool handleMessage(const Message& cmd); //!< Processing of a message. Returns true if message has actually been processed void applySettings(const DOA2Settings& settings, bool force = false); diff --git a/plugins/channelmimo/doa2/doa2corr.cpp b/plugins/channelmimo/doa2/doa2corr.cpp index 97098387c..8354be90e 100644 --- a/plugins/channelmimo/doa2/doa2corr.cpp +++ b/plugins/channelmimo/doa2/doa2corr.cpp @@ -264,7 +264,7 @@ bool DOA2Correlator::performFFTProd( m_fft[0]->out() + m_fftSize, m_dataj, m_invFFT->in(), - [this](std::complex& a, const std::complex& b) -> std::complex { + [](std::complex& a, const std::complex& b) -> std::complex { return (a*b); } ); diff --git a/plugins/channelmimo/doa2/doa2streamsink.h b/plugins/channelmimo/doa2/doa2streamsink.h index 07612c5b7..61d51d855 100644 --- a/plugins/channelmimo/doa2/doa2streamsink.h +++ b/plugins/channelmimo/doa2/doa2streamsink.h @@ -44,9 +44,6 @@ private: int m_dataSize; int m_bufferSize; int m_dataStart; - - uint32_t m_log2Decim; - uint32_t m_filterChainHash; }; diff --git a/plugins/channelmimo/interferometer/interferometer.h b/plugins/channelmimo/interferometer/interferometer.h index 927282675..8e92fd1a5 100644 --- a/plugins/channelmimo/interferometer/interferometer.h +++ b/plugins/channelmimo/interferometer/interferometer.h @@ -196,7 +196,6 @@ private: uint64_t m_centerFrequency; int64_t m_frequencyOffset; uint32_t m_deviceSampleRate; - int m_count0, m_count1; QList m_localInputDeviceIndexes; diff --git a/plugins/channelmimo/interferometer/interferometercorr.cpp b/plugins/channelmimo/interferometer/interferometercorr.cpp index 1c90c433d..ee95fabad 100644 --- a/plugins/channelmimo/interferometer/interferometercorr.cpp +++ b/plugins/channelmimo/interferometer/interferometercorr.cpp @@ -555,7 +555,7 @@ bool InterferometerCorrelator::performFFTProd( m_fft2[0]->out() + m_fftSize, m_dataj, m_invFFT2->in(), - [this](std::complex& a, const std::complex& b) -> std::complex { + [](std::complex& a, const std::complex& b) -> std::complex { return (a*b); } ); diff --git a/plugins/channelmimo/interferometer/interferometerstreamsink.h b/plugins/channelmimo/interferometer/interferometerstreamsink.h index e3cb8af99..43fbe7ea2 100644 --- a/plugins/channelmimo/interferometer/interferometerstreamsink.h +++ b/plugins/channelmimo/interferometer/interferometerstreamsink.h @@ -44,9 +44,6 @@ private: int m_dataSize; int m_bufferSize; int m_dataStart; - - uint32_t m_log2Decim; - uint32_t m_filterChainHash; }; diff --git a/plugins/channelrx/channelpower/channelpowersink.cpp b/plugins/channelrx/channelpower/channelpowersink.cpp index fa78ce2f1..f34c948ae 100644 --- a/plugins/channelrx/channelpower/channelpowersink.cpp +++ b/plugins/channelrx/channelpower/channelpowersink.cpp @@ -21,12 +21,13 @@ #include "channelpowersink.h" ChannelPowerSink::ChannelPowerSink(ChannelPower *channelPower) : - m_channelPower(channelPower), m_channelSampleRate(10000), m_channelFrequencyOffset(0), m_lowpassFFT(nullptr), m_lowpassBufferIdx(0) { + (void)channelPower; + resetMagLevels(); applySettings(m_settings, QStringList(), true); @@ -41,7 +42,6 @@ ChannelPowerSink::~ChannelPowerSink() void ChannelPowerSink::feed(const SampleVector::const_iterator& begin, const SampleVector::const_iterator& end) { QMutexLocker mutexLocker(&m_mutex); - Complex ci; for (SampleVector::const_iterator it = begin; it != end; ++it) { diff --git a/plugins/channelrx/channelpower/channelpowersink.h b/plugins/channelrx/channelpower/channelpowersink.h index 2bfa73714..3f276f293 100644 --- a/plugins/channelrx/channelpower/channelpowersink.h +++ b/plugins/channelrx/channelpower/channelpowersink.h @@ -65,7 +65,6 @@ public: private: - ChannelPower *m_channelPower; ChannelPowerSettings m_settings; ChannelAPI *m_channel; int m_channelSampleRate; diff --git a/plugins/channelrx/demodadsb/adsbdemodgui.cpp b/plugins/channelrx/demodadsb/adsbdemodgui.cpp index 342e8f5c8..646147b38 100644 --- a/plugins/channelrx/demodadsb/adsbdemodgui.cpp +++ b/plugins/channelrx/demodadsb/adsbdemodgui.cpp @@ -4991,7 +4991,7 @@ ADSBDemodGUI::ADSBDemodGUI(PluginAPI* pluginAPI, DeviceUISet *deviceUISet, Baseb m_azEl.setLocation(stationLatitude, stationLongitude, stationAltitude); // These are the default values in sdrbase/settings/preferences.cpp - if ((stationLatitude == 49.012423) && (stationLongitude == 8.418125)) { + if ((stationLatitude == (float)49.012423) && (stationLongitude == (float)8.418125)) { ui->warning->setText("Please set your antenna location under Preferences > My Position"); } diff --git a/plugins/channelrx/demodadsb/adsbdemodgui.h b/plugins/channelrx/demodadsb/adsbdemodgui.h index a05e829bc..ebf257408 100644 --- a/plugins/channelrx/demodadsb/adsbdemodgui.h +++ b/plugins/channelrx/demodadsb/adsbdemodgui.h @@ -811,6 +811,10 @@ public: { m_aircraftRegExp.optimize(); } + + virtual ~ModelMatch() + { + } virtual bool match(const QString &aircraft, const QString &manufacturer, QString &model) { diff --git a/plugins/channelrx/demodadsb/adsbdemodsink.cpp b/plugins/channelrx/demodadsb/adsbdemodsink.cpp index eeeaa15ab..6b9da6eae 100644 --- a/plugins/channelrx/demodadsb/adsbdemodsink.cpp +++ b/plugins/channelrx/demodadsb/adsbdemodsink.cpp @@ -79,7 +79,6 @@ void ADSBDemodSink::feed(const SampleVector::const_iterator& begin, const Sample for (SampleVector::const_iterator it = begin; it != end; ++it) { Complex c(it->real(), it->imag()); - Complex ci; c *= m_nco.nextIQ(); processOneSample(complexMagSq(c)); } diff --git a/plugins/channelrx/demodais/aisdemodsink.cpp b/plugins/channelrx/demodais/aisdemodsink.cpp index a961201be..55dee3fa1 100644 --- a/plugins/channelrx/demodais/aisdemodsink.cpp +++ b/plugins/channelrx/demodais/aisdemodsink.cpp @@ -118,8 +118,6 @@ void AISDemodSink::feed(const SampleVector::const_iterator& begin, const SampleV void AISDemodSink::processOneSample(Complex &ci) { - Complex ca; - // FM demodulation double magsqRaw; Real deviation; diff --git a/plugins/channelrx/demodam/amdemodgui.cpp b/plugins/channelrx/demodam/amdemodgui.cpp index 415a65f3e..2dc7e96c5 100644 --- a/plugins/channelrx/demodam/amdemodgui.cpp +++ b/plugins/channelrx/demodam/amdemodgui.cpp @@ -663,7 +663,7 @@ void AMDemodGUI::snapClicked() { applySnap(); - qint64 value; + qint64 value = 0; if (m_settings.m_frequencyMode == AMDemodSettings::Offset) { value = m_settings.m_inputFrequencyOffset; diff --git a/plugins/channelrx/demodapt/aptdemodsink.cpp b/plugins/channelrx/demodapt/aptdemodsink.cpp index 13b41f798..87a156c5c 100644 --- a/plugins/channelrx/demodapt/aptdemodsink.cpp +++ b/plugins/channelrx/demodapt/aptdemodsink.cpp @@ -24,7 +24,6 @@ #include "aptdemodsink.h" APTDemodSink::APTDemodSink(APTDemod *packetDemod) : - m_aptDemod(packetDemod), m_channelSampleRate(APTDEMOD_AUDIO_SAMPLE_RATE), m_channelFrequencyOffset(0), m_magsqSum(0.0f), @@ -33,6 +32,8 @@ APTDemodSink::APTDemodSink(APTDemod *packetDemod) : m_imageWorkerMessageQueue(nullptr), m_samples(nullptr) { + (void)packetDemod; + m_magsq = 0.0; applySettings(m_settings, true); @@ -129,8 +130,6 @@ void APTDemodSink::feed(const SampleVector::const_iterator& begin, const SampleV void APTDemodSink::processOneSample(Complex &ci) { - Complex ca; - // FM demodulation double magsqRaw; Real deviation; diff --git a/plugins/channelrx/demodapt/aptdemodsink.h b/plugins/channelrx/demodapt/aptdemodsink.h index e65f903e5..7a4f85d53 100644 --- a/plugins/channelrx/demodapt/aptdemodsink.h +++ b/plugins/channelrx/demodapt/aptdemodsink.h @@ -87,7 +87,6 @@ private: double m_magsqPeak; }; - APTDemod *m_aptDemod; APTDemodSettings m_settings; int m_channelSampleRate; int m_channelFrequencyOffset; diff --git a/plugins/channelrx/demodatv/atvdemodsettings.h b/plugins/channelrx/demodatv/atvdemodsettings.h index f25df5b21..db428fddb 100644 --- a/plugins/channelrx/demodatv/atvdemodsettings.h +++ b/plugins/channelrx/demodatv/atvdemodsettings.h @@ -101,9 +101,6 @@ struct ATVDemodSettings static float getNominalLineTime(int nbLines, int fps); static float getRFBandwidthDivisor(ATVModulation modulation); static void getBaseValues(int sampleRate, int linesPerSecond, uint32_t& nbPointsPerLine); - -private: - int m_rfSliderDivisor; }; #endif /* PLUGINS_CHANNELRX_DEMODATV_ATVDEMODSETTINGS_H_ */ diff --git a/plugins/channelrx/demodatv/atvdemodsink.h b/plugins/channelrx/demodatv/atvdemodsink.h index a6b47f024..6af9b58df 100644 --- a/plugins/channelrx/demodatv/atvdemodsink.h +++ b/plugins/channelrx/demodatv/atvdemodsink.h @@ -163,7 +163,6 @@ private: int m_hSyncErrorCount; float prevSample; - int m_avgColIndex; SampleVector m_sampleBuffer; diff --git a/plugins/channelrx/demodbfm/rdsparser.cpp b/plugins/channelrx/demodbfm/rdsparser.cpp index 663d74a19..b02f8742b 100644 --- a/plugins/channelrx/demodbfm/rdsparser.cpp +++ b/plugins/channelrx/demodbfm/rdsparser.cpp @@ -467,7 +467,6 @@ void RDSParser::decode_type0(unsigned int *group, bool B) { unsigned int af_code_1 = 0; unsigned int af_code_2 = 0; - unsigned int no_af = 0; double af_1 = 0; double af_2 = 0; @@ -534,7 +533,7 @@ void RDSParser::decode_type0(unsigned int *group, bool B) // @TODO: Find proper header or STL on OSX auto res = m_g0_alt_freq.insert(af_1/1e3); m_g0_af_updated = m_g0_af_updated || res.second; - no_af += 1; + // no_af += 1; } if (af_2) @@ -542,7 +541,7 @@ void RDSParser::decode_type0(unsigned int *group, bool B) // @TODO: Find proper header or STL on OSX auto res = m_g0_alt_freq.insert(af_2/1e3); m_g0_af_updated = m_g0_af_updated || res.second; - no_af += 2; + // no_af += 2; } /* diff --git a/plugins/channelrx/demoddab/dabdemodsink.cpp b/plugins/channelrx/demoddab/dabdemodsink.cpp index 193d00dac..70a1f0b25 100644 --- a/plugins/channelrx/demoddab/dabdemodsink.cpp +++ b/plugins/channelrx/demoddab/dabdemodsink.cpp @@ -488,7 +488,6 @@ void DABDemodSink::processOneAudioSample(Complex &ci) } DABDemodSink::DABDemodSink(DABDemod *packetDemod) : - m_dabDemod(packetDemod), m_audioSampleRate(48000), m_dabAudioSampleRate(10000), // Unused value to begin with m_channelSampleRate(DABDEMOD_CHANNEL_SAMPLE_RATE), @@ -500,6 +499,8 @@ DABDemodSink::DABDemodSink(DABDemod *packetDemod) : m_messageQueueToChannel(nullptr), m_audioFifo(48000) { + (void)packetDemod; + m_audioBuffer.resize(1<<14); m_audioBufferFill = 0; diff --git a/plugins/channelrx/demoddab/dabdemodsink.h b/plugins/channelrx/demoddab/dabdemodsink.h index 7f133dea2..1dd975075 100644 --- a/plugins/channelrx/demoddab/dabdemodsink.h +++ b/plugins/channelrx/demoddab/dabdemodsink.h @@ -106,7 +106,6 @@ private: double m_magsqPeak; }; - DABDemod *m_dabDemod; DABDemodSettings m_settings; ChannelAPI *m_channel; diff --git a/plugins/channelrx/demoddatv/datvdemodsink.cpp b/plugins/channelrx/demoddatv/datvdemodsink.cpp index 42e47170d..7328bdc8f 100644 --- a/plugins/channelrx/demoddatv/datvdemodsink.cpp +++ b/plugins/channelrx/demoddatv/datvdemodsink.cpp @@ -1096,12 +1096,12 @@ void DATVDemodSink::InitDATVS2Framework() p_vbitcount= new leansdr::pipebuf(m_objScheduler, "Bits processed", BUF_S2PACKETS); p_verrcount = new leansdr::pipebuf(m_objScheduler, "Bits corrected", BUF_S2PACKETS); - bool commandFileValid = false; + // bool commandFileValid = false; if (QFileInfo::exists(m_settings.m_softLDPCToolPath)) { QFileInfo fileInfo = QFileInfo(m_settings.m_softLDPCToolPath); - commandFileValid = fileInfo.isExecutable(); + // commandFileValid = fileInfo.isExecutable(); } if (m_settings.m_softLDPC /*&& commandFileValid*/) @@ -1195,11 +1195,6 @@ void DATVDemodSink::InitDATVS2Framework() void DATVDemodSink::feed(const SampleVector::const_iterator& begin, const SampleVector::const_iterator& end) { - float fltI; - float fltQ; - fftfilt::cmplx *objRF; - int intRFOut; - int lngWritable=0; leansdr::s2_frame_receiver *objDemodulatorDVBS2 = (leansdr::s2_frame_receiver *) m_objDemodulatorDVBS2; diff --git a/plugins/channelrx/demoddatv/datvdemodsink.h b/plugins/channelrx/demoddatv/datvdemodsink.h index 70af99272..b56cb6531 100644 --- a/plugins/channelrx/demoddatv/datvdemodsink.h +++ b/plugins/channelrx/demoddatv/datvdemodsink.h @@ -333,8 +333,8 @@ private: Interpolator m_interpolator; Real m_interpolatorDistance; Real m_interpolatorDistanceRemain; - static const int m_interpolatorPhaseSteps = 4; // Higher than these two values will struggle to run in real-time - static const int m_interpolatorTapsPerPhase = 3.5f; // without gaining much improvement in PER + static constexpr int m_interpolatorPhaseSteps = 4; // Higher than these two values will struggle to run in real-time + static constexpr float m_interpolatorTapsPerPhase = 3.5f; // without gaining much improvement in PER bool m_blnInitialized; bool m_blnRenderingVideo; diff --git a/plugins/channelrx/demoddatv/leansdr/discrmath.h b/plugins/channelrx/demoddatv/leansdr/discrmath.h index f4a0618da..de3835713 100644 --- a/plugins/channelrx/demoddatv/leansdr/discrmath.h +++ b/plugins/channelrx/demoddatv/leansdr/discrmath.h @@ -58,7 +58,7 @@ struct bitvect for (int i = 0; i < nw; ++i) v[i] = a.v[i]; if (M < N) - for (int i = a.NW; i < NW; ++i) + for (size_t i = a.NW; i < NW; ++i) v[i] = 0; if (M > N) truncate_to_N(); diff --git a/plugins/channelrx/demoddatv/leansdr/dvbs2.h b/plugins/channelrx/demoddatv/leansdr/dvbs2.h index 47c2acf60..69ad0d315 100644 --- a/plugins/channelrx/demoddatv/leansdr/dvbs2.h +++ b/plugins/channelrx/demoddatv/leansdr/dvbs2.h @@ -458,6 +458,8 @@ struct s2_frame_transmitter : runnable std::complex *pout ) { + (void)mcinfo; + std::complex *pout0 = pout; // For sanity check // PLHEADER: SOF AND PLSCODE // EN 302 307-1 section 5.5.2 PL signalling @@ -2584,6 +2586,8 @@ struct s2_deinterleaver : runnable static inline void split_symbol(const llr_ss &ps, hard_sb accs[/*bps*/], int nacc) { + (void)nacc; + if (MSB_FIRST) { for (int b = 0; b < BPS; ++b) { @@ -3833,10 +3837,6 @@ struct s2_fecdec_helper : runnable // Receive a finished job. void receive_frame(const helper_job *job) { - // Read corrected frame from helper - const s2_pls *pls = &job->pls; - int iosize = (pls->framebits() / 8) * sizeof(ldpc_buf[0]); - // Non blocking read - will do the next time if no adata is available if (job->h->m_worker->dataAvailable()) { @@ -4267,7 +4267,6 @@ private: // 188 = waiting for CRC uint8_t leftover[188]; static const int MAX_TS_PER_BBFRAME = fec_info::KBCH_MAX / 8 / 188 + 1; - bool locked; pipereader in; pipewriter out; int current_state; diff --git a/plugins/channelrx/demoddatv/leansdr/generic.h b/plugins/channelrx/demoddatv/leansdr/generic.h index 6c89701ac..893468ad8 100644 --- a/plugins/channelrx/demoddatv/leansdr/generic.h +++ b/plugins/channelrx/demoddatv/leansdr/generic.h @@ -544,6 +544,7 @@ struct serializer : runnable in(_in), out(_out, nout) { + (void)sch; if (nin * sizeof(Tin) != nout * sizeof(Tout)) { fail("serializer: incompatible sizes"); } diff --git a/plugins/channelrx/demoddatv/leansdr/sdr.h b/plugins/channelrx/demoddatv/leansdr/sdr.h index 314f587c3..9ce9cdf5b 100644 --- a/plugins/channelrx/demoddatv/leansdr/sdr.h +++ b/plugins/channelrx/demoddatv/leansdr/sdr.h @@ -414,7 +414,6 @@ struct simple_agc : runnable float gain = estimated ? out_rms / sqrtf(estimated) : 0; pin = in.rd(); std::complex *pout = out.wr(); - float bwcomp = 1 - bw; for (; pin < pend; ++pin, ++pout) { diff --git a/plugins/channelrx/demoddsc/dscdemodgui.cpp b/plugins/channelrx/demoddsc/dscdemodgui.cpp index cbade9cbd..ed7febbd3 100644 --- a/plugins/channelrx/demoddsc/dscdemodgui.cpp +++ b/plugins/channelrx/demoddsc/dscdemodgui.cpp @@ -767,7 +767,7 @@ void DSCDemodGUI::customContextMenuRequested(QPoint pos) QAction* sendAreaToMapAction = new QAction(QString("Display %1 on map").arg(address), tableContextMenu); connect(sendAreaToMapAction, &QAction::triggered, this, [this, name, address, info]()->void { sendAreaToMapFeature(name, address, info); - QTimer::singleShot(500, [this, name] { + QTimer::singleShot(500, [ name] { FeatureWebAPIUtils::mapFind(name); }); }); @@ -776,7 +776,7 @@ void DSCDemodGUI::customContextMenuRequested(QPoint pos) else { QAction* findAreaOnMapAction = new QAction(QString("Center map on %1").arg(address), tableContextMenu); - connect(findAreaOnMapAction, &QAction::triggered, this, [this, name]()->void { + connect(findAreaOnMapAction, &QAction::triggered, this, [ name]()->void { FeatureWebAPIUtils::mapFind(name); }); tableContextMenu->addAction(findAreaOnMapAction); @@ -814,7 +814,7 @@ void DSCDemodGUI::customContextMenuRequested(QPoint pos) if (sampleSource) { QAction* tuneRxAction = new QAction(QString("Tune SSB Demod %1:%2 to %3").arg(deviceSetIndex).arg(chi).arg(rxFormatted), tableContextMenu); - connect(tuneRxAction, &QAction::triggered, this, [this, deviceSetIndex, chi, rxFreq, sampleSource]()->void { + connect(tuneRxAction, &QAction::triggered, this, [deviceSetIndex, chi, rxFreq, sampleSource]()->void { int bw = sampleSource->getSampleRate(); quint64 cf = sampleSource->getCenterFrequency(); diff --git a/plugins/channelrx/demodendoftrain/endoftraindemodsink.cpp b/plugins/channelrx/demodendoftrain/endoftraindemodsink.cpp index 079ff6b10..0bbea6d7f 100644 --- a/plugins/channelrx/demodendoftrain/endoftraindemodsink.cpp +++ b/plugins/channelrx/demodendoftrain/endoftraindemodsink.cpp @@ -119,8 +119,6 @@ void EndOfTrainDemodSink::feed(const SampleVector::const_iterator& begin, const void EndOfTrainDemodSink::processOneSample(Complex &ci) { - Complex ca; - // FM demodulation double magsqRaw; Real deviation; diff --git a/plugins/channelrx/demodft8/ft8demod.cpp b/plugins/channelrx/demodft8/ft8demod.cpp index dccdd3c31..185f8d485 100644 --- a/plugins/channelrx/demodft8/ft8demod.cpp +++ b/plugins/channelrx/demodft8/ft8demod.cpp @@ -697,7 +697,7 @@ void FT8Demod::sendChannelSettings( const FT8DemodSettings& settings, bool force) { - qDebug("FT8Demod::sendChannelSettings: %d pipes", pipes.size()); + qDebug("FT8Demod::sendChannelSettings: %d pipes", (int)pipes.size()); for (const auto& pipe : pipes) { diff --git a/plugins/channelrx/demodft8/ft8demodsettings.h b/plugins/channelrx/demodft8/ft8demodsettings.h index 8e4146f30..25a113eb1 100644 --- a/plugins/channelrx/demodft8/ft8demodsettings.h +++ b/plugins/channelrx/demodft8/ft8demodsettings.h @@ -51,8 +51,9 @@ struct FT8DemodBandPreset int m_channelOffset; }; -struct FT8DemodSettings +class FT8DemodSettings { +public: enum MessageCol { MESSAGE_COL_UTC, MESSAGE_COL_TYPE, diff --git a/plugins/channelrx/demodft8/ft8demodworker.cpp b/plugins/channelrx/demodft8/ft8demodworker.cpp index 8b1b1d797..2d63f0ee8 100644 --- a/plugins/channelrx/demodft8/ft8demodworker.cpp +++ b/plugins/channelrx/demodft8/ft8demodworker.cpp @@ -40,7 +40,6 @@ FT8DemodWorker::FT8Callback::FT8Callback( ) : m_packing(packing), m_periodTS(periodTS), - m_baseFrequency(baseFrequency), m_name(name), m_validCallsigns(nullptr) { @@ -226,7 +225,7 @@ void FT8DemodWorker::processBuffer(int16_t *buffer, QDateTime periodTS) m_ft8Decoder.wait(m_decoderTimeBudget + 1.0); // add one second to budget to force quit threads qDebug("FT8DemodWorker::processBuffer: done: at %6.3f %d messages", - m_baseFrequency / 1000000.0, ft8Callback.getReportMessage()->getFT8Messages().size()); + m_baseFrequency / 1000000.0, (int)ft8Callback.getReportMessage()->getFT8Messages().size()); if (m_reportingMessageQueue) { m_reportingMessageQueue->push(new MsgReportFT8Messages(*ft8Callback.getReportMessage())); diff --git a/plugins/channelrx/demodft8/ft8demodworker.h b/plugins/channelrx/demodft8/ft8demodworker.h index 95792646b..358f9e559 100644 --- a/plugins/channelrx/demodft8/ft8demodworker.h +++ b/plugins/channelrx/demodft8/ft8demodworker.h @@ -84,7 +84,6 @@ private: FT8::Packing& m_packing; MsgReportFT8Messages *m_msgReportFT8Messages; const QDateTime& m_periodTS; - qint64 m_baseFrequency; QString m_name; const QSet *m_validCallsigns; }; diff --git a/plugins/channelrx/demodils/ilsdemodgui.cpp b/plugins/channelrx/demodils/ilsdemodgui.cpp index 4d8baac7c..a912f5609 100644 --- a/plugins/channelrx/demodils/ilsdemodgui.cpp +++ b/plugins/channelrx/demodils/ilsdemodgui.cpp @@ -1432,7 +1432,6 @@ void ILSDemodGUI::scanAvailableChannels() MessagePipes& messagePipes = mainCore->getMessagePipes(); std::vector& deviceSets = mainCore->getDeviceSets(); m_availableChannels.clear(); - int deviceSetIndex = 0; for (const auto& deviceSet : deviceSets) { @@ -1465,7 +1464,6 @@ void ILSDemodGUI::scanAvailableChannels() } } } - deviceSetIndex++; } } diff --git a/plugins/channelrx/demodils/ilsdemodsink.cpp b/plugins/channelrx/demodils/ilsdemodsink.cpp index 30243f831..8bd2f2d1c 100644 --- a/plugins/channelrx/demodils/ilsdemodsink.cpp +++ b/plugins/channelrx/demodils/ilsdemodsink.cpp @@ -31,7 +31,6 @@ ILSDemodSink::ILSDemodSink(ILSDemod *ilsDemod) : m_spectrumSink(nullptr), m_scopeSink(nullptr), - m_ilsDemod(ilsDemod), m_channel(nullptr), m_channelSampleRate(ILSDemodSettings::ILSDEMOD_CHANNEL_SAMPLE_RATE), m_channelFrequencyOffset(0), @@ -51,6 +50,8 @@ ILSDemodSink::ILSDemodSink(ILSDemod *ilsDemod) : m_audioFifo(48000), m_sampleBufferIndex(0) { + (void)ilsDemod; + m_audioBuffer.resize(1<<14); m_audioBufferFill = 0; diff --git a/plugins/channelrx/demodils/ilsdemodsink.h b/plugins/channelrx/demodils/ilsdemodsink.h index 5e179d197..ebcef81f7 100644 --- a/plugins/channelrx/demodils/ilsdemodsink.h +++ b/plugins/channelrx/demodils/ilsdemodsink.h @@ -96,7 +96,6 @@ private: SpectrumVis* m_spectrumSink; ScopeVis* m_scopeSink; // Scope GUI to display baseband waveform - ILSDemod *m_ilsDemod; ILSDemodSettings m_settings; ChannelAPI *m_channel; int m_channelSampleRate; diff --git a/plugins/channelrx/demodnavtex/navtexdemodsink.cpp b/plugins/channelrx/demodnavtex/navtexdemodsink.cpp index f10c8e6ab..fb82db669 100644 --- a/plugins/channelrx/demodnavtex/navtexdemodsink.cpp +++ b/plugins/channelrx/demodnavtex/navtexdemodsink.cpp @@ -28,7 +28,6 @@ #include "navtexdemodsink.h" NavtexDemodSink::NavtexDemodSink(NavtexDemod *packetDemod) : - m_navtexDemod(packetDemod), m_channelSampleRate(NavtexDemodSettings::NAVTEXDEMOD_CHANNEL_SAMPLE_RATE), m_channelFrequencyOffset(0), m_magsqSum(0.0f), @@ -38,6 +37,7 @@ NavtexDemodSink::NavtexDemodSink(NavtexDemod *packetDemod) : m_exp(nullptr), m_sampleBufferIndex(0) { + (void)packetDemod; m_magsq = 0.0; m_sampleBuffer.resize(m_sampleBufferSize); diff --git a/plugins/channelrx/demodnavtex/navtexdemodsink.h b/plugins/channelrx/demodnavtex/navtexdemodsink.h index 4e243b681..8f3305dbf 100644 --- a/plugins/channelrx/demodnavtex/navtexdemodsink.h +++ b/plugins/channelrx/demodnavtex/navtexdemodsink.h @@ -83,7 +83,6 @@ private: }; ScopeVis* m_scopeSink; // Scope GUI to display baseband waveform - NavtexDemod *m_navtexDemod; NavtexDemodSettings m_settings; ChannelAPI *m_channel; int m_channelSampleRate; diff --git a/plugins/channelrx/demodpacket/packetdemodsink.cpp b/plugins/channelrx/demodpacket/packetdemodsink.cpp index 21a971a99..7aab705c9 100644 --- a/plugins/channelrx/demodpacket/packetdemodsink.cpp +++ b/plugins/channelrx/demodpacket/packetdemodsink.cpp @@ -88,8 +88,6 @@ void PacketDemodSink::feed(const SampleVector::const_iterator& begin, const Samp void PacketDemodSink::processOneSample(Complex &ci) { - Complex ca; - // FM demodulation double magsqRaw; Real deviation; diff --git a/plugins/channelrx/demodpager/pagerdemodsink.cpp b/plugins/channelrx/demodpager/pagerdemodsink.cpp index 71cb3a62e..7bbd92587 100644 --- a/plugins/channelrx/demodpager/pagerdemodsink.cpp +++ b/plugins/channelrx/demodpager/pagerdemodsink.cpp @@ -30,7 +30,6 @@ PagerDemodSink::PagerDemodSink(PagerDemod *pagerDemod) : m_scopeSink(nullptr), - m_pagerDemod(pagerDemod), m_channelSampleRate(PagerDemodSettings::m_channelSampleRate), m_channelFrequencyOffset(0), m_magsqSum(0.0f), @@ -50,6 +49,8 @@ PagerDemodSink::PagerDemodSink(PagerDemod *pagerDemod) : m_addressValid(0), m_sampleBufferIndex(0) { + (void)pagerDemod; + m_magsq = 0.0; m_demodBuffer.resize(1<<12); diff --git a/plugins/channelrx/demodpager/pagerdemodsink.h b/plugins/channelrx/demodpager/pagerdemodsink.h index 4a4f6a458..daee29625 100644 --- a/plugins/channelrx/demodpager/pagerdemodsink.h +++ b/plugins/channelrx/demodpager/pagerdemodsink.h @@ -88,7 +88,6 @@ private: }; ScopeVis* m_scopeSink; // Scope GUI to display debug waveforms - PagerDemod *m_pagerDemod; PagerDemodSettings m_settings; ChannelAPI *m_channel; int m_channelSampleRate; diff --git a/plugins/channelrx/demodrtty/rttydemodsink.cpp b/plugins/channelrx/demodrtty/rttydemodsink.cpp index f0864bcde..b39217296 100644 --- a/plugins/channelrx/demodrtty/rttydemodsink.cpp +++ b/plugins/channelrx/demodrtty/rttydemodsink.cpp @@ -29,7 +29,6 @@ #include "rttydemodsink.h" RttyDemodSink::RttyDemodSink(RttyDemod *packetDemod) : - m_rttyDemod(packetDemod), m_channelSampleRate(RttyDemodSettings::RTTYDEMOD_CHANNEL_SAMPLE_RATE), m_channelFrequencyOffset(0), m_magsqSum(0.0f), @@ -48,6 +47,8 @@ RttyDemodSink::RttyDemodSink(RttyDemod *packetDemod) : m_fftCounter(0), m_sampleBufferIndex(0) { + (void)packetDemod; + m_magsq = 0.0; m_sampleBuffer.resize(m_sampleBufferSize); diff --git a/plugins/channelrx/demodrtty/rttydemodsink.h b/plugins/channelrx/demodrtty/rttydemodsink.h index 31b4f44e7..ed5089225 100644 --- a/plugins/channelrx/demodrtty/rttydemodsink.h +++ b/plugins/channelrx/demodrtty/rttydemodsink.h @@ -83,7 +83,6 @@ private: }; ScopeVis* m_scopeSink; // Scope GUI to display baseband waveform - RttyDemod *m_rttyDemod; RttyDemodSettings m_settings; ChannelAPI *m_channel; int m_channelSampleRate; diff --git a/plugins/channelrx/demodssb/ssbdemod.cpp b/plugins/channelrx/demodssb/ssbdemod.cpp index 2a5b445b2..e4eb998da 100644 --- a/plugins/channelrx/demodssb/ssbdemod.cpp +++ b/plugins/channelrx/demodssb/ssbdemod.cpp @@ -752,7 +752,7 @@ void SSBDemod::sendChannelSettings( const SSBDemodSettings& settings, bool force) { - qDebug("SSBDemod::sendChannelSettings: %d pipes", pipes.size()); + qDebug("SSBDemod::sendChannelSettings: %d pipes", (int)pipes.size()); for (const auto& pipe : pipes) { diff --git a/plugins/channelrx/demodvor/vordemodsink.h b/plugins/channelrx/demodvor/vordemodsink.h index 92319bd28..6257bb848 100644 --- a/plugins/channelrx/demodvor/vordemodsink.h +++ b/plugins/channelrx/demodvor/vordemodsink.h @@ -105,7 +105,6 @@ private: MagSqLevelsStore m_magSqLevelStore; MessageQueue *m_messageQueueToChannel; - MessageQueue *m_messageQueueToGUI; MovingAverageUtil m_movingAverage; SimpleAGC<4800> m_volumeAGC; diff --git a/plugins/channelrx/filesink/filesinksink.h b/plugins/channelrx/filesink/filesinksink.h index d4a3777e9..529824c1e 100644 --- a/plugins/channelrx/filesink/filesinksink.h +++ b/plugins/channelrx/filesink/filesinksink.h @@ -73,7 +73,6 @@ private: unsigned int m_nbCaptures; SampleSimpleFifo m_preRecordBuffer; unsigned int m_preRecordFill; - float m_squelchLevel; SpectrumVis* m_spectrumSink; MessageQueue *m_msgQueueToGUI; bool m_recordEnabled; diff --git a/plugins/channelrx/freqscanner/freqscanner.h b/plugins/channelrx/freqscanner/freqscanner.h index a5ec4ff37..3d56c8bef 100644 --- a/plugins/channelrx/freqscanner/freqscanner.h +++ b/plugins/channelrx/freqscanner/freqscanner.h @@ -389,7 +389,6 @@ private: qint64 m_activeFrequency; QDateTime m_minFFTStartTime; int m_scannerSampleRate; - bool m_stepping; qint64 m_stepStartFrequency; qint64 m_stepStopFrequency; QList m_scanResults; diff --git a/plugins/channelrx/freqscanner/freqscannersink.cpp b/plugins/channelrx/freqscanner/freqscannersink.cpp index e38999f5b..cd90b35e7 100644 --- a/plugins/channelrx/freqscanner/freqscannersink.cpp +++ b/plugins/channelrx/freqscanner/freqscannersink.cpp @@ -27,7 +27,6 @@ #include "freqscannersink.h" FreqScannerSink::FreqScannerSink(FreqScanner *ilsDemod) : - m_freqScanner(ilsDemod), m_channel(nullptr), m_channelSampleRate(48000), m_channelFrequencyOffset(0), @@ -41,6 +40,8 @@ FreqScannerSink::FreqScannerSink(FreqScanner *ilsDemod) : m_binsPerChannel(16), m_averageCount(0) { + (void)ilsDemod; + applySettings(m_settings, QStringList(), true); applyChannelSettings(m_channelSampleRate, m_channelFrequencyOffset, 16, 4, true); } diff --git a/plugins/channelrx/freqscanner/freqscannersink.h b/plugins/channelrx/freqscanner/freqscannersink.h index 1bff72143..dcf311145 100644 --- a/plugins/channelrx/freqscanner/freqscannersink.h +++ b/plugins/channelrx/freqscanner/freqscannersink.h @@ -50,7 +50,6 @@ public: private: - FreqScanner *m_freqScanner; FreqScannerSettings m_settings; ChannelAPI *m_channel; int m_channelSampleRate; diff --git a/plugins/channelrx/heatmap/heatmapsink.cpp b/plugins/channelrx/heatmap/heatmapsink.cpp index 6502b9fce..bccf2408c 100644 --- a/plugins/channelrx/heatmap/heatmapsink.cpp +++ b/plugins/channelrx/heatmap/heatmapsink.cpp @@ -26,7 +26,6 @@ HeatMapSink::HeatMapSink(HeatMap *heatMap) : m_scopeSink(nullptr), - m_heatMap(heatMap), m_channelSampleRate(10000), m_channelFrequencyOffset(0), m_magsq(0.0), @@ -37,6 +36,8 @@ HeatMapSink::HeatMapSink(HeatMap *heatMap) : m_sampleBufferSize(1000), m_sampleBufferIndex(0) { + (void)heatMap; + resetMagLevels(); m_sampleBuffer.resize(m_sampleBufferSize); diff --git a/plugins/channelrx/heatmap/heatmapsink.h b/plugins/channelrx/heatmap/heatmapsink.h index 02588db6d..e20e57a21 100644 --- a/plugins/channelrx/heatmap/heatmapsink.h +++ b/plugins/channelrx/heatmap/heatmapsink.h @@ -106,12 +106,10 @@ private: }; ScopeVis* m_scopeSink; // Scope GUI to display filtered power - HeatMap *m_heatMap; HeatMapSettings m_settings; ChannelAPI *m_channel; int m_channelSampleRate; int m_channelFrequencyOffset; - int m_sinkSampleRate; NCO m_nco; Interpolator m_interpolator; diff --git a/plugins/channelrx/localsink/localsinksettings.cpp b/plugins/channelrx/localsink/localsinksettings.cpp index b6dd3074c..1e019ffe4 100644 --- a/plugins/channelrx/localsink/localsinksettings.cpp +++ b/plugins/channelrx/localsink/localsinksettings.cpp @@ -53,6 +53,7 @@ void LocalSinkSettings::resetToDefaults() m_reverseAPIChannelIndex = 0; m_workspaceIndex = 0; m_hidden = false; + m_maxFFTBands = 32; } QByteArray LocalSinkSettings::serialize() const @@ -94,7 +95,7 @@ QByteArray LocalSinkSettings::serialize() const s.writeBool(24, m_reverseFilter); s.writeU32(99, m_fftBands.size()); - int i = 0; + uint32_t i = 0; for (auto fftBand : m_fftBands) { diff --git a/plugins/channelrx/localsink/localsinksettings.h b/plugins/channelrx/localsink/localsinksettings.h index db0af6a70..990492144 100644 --- a/plugins/channelrx/localsink/localsinksettings.h +++ b/plugins/channelrx/localsink/localsinksettings.h @@ -42,7 +42,7 @@ struct LocalSinkSettings uint32_t m_log2FFT; FFTWindow::Function m_fftWindow; bool m_reverseFilter; - static const uint32_t m_maxFFTBands = 20; + uint32_t m_maxFFTBands; std::vector> m_fftBands; int m_streamIndex; //!< MIMO channel. Not relevant when connected to SI (single Rx). bool m_useReverseAPI; diff --git a/plugins/channelrx/noisefigure/noisefiguresink.cpp b/plugins/channelrx/noisefigure/noisefiguresink.cpp index 72d7b348c..62a381032 100644 --- a/plugins/channelrx/noisefigure/noisefiguresink.cpp +++ b/plugins/channelrx/noisefigure/noisefiguresink.cpp @@ -26,7 +26,6 @@ #include "noisefiguresink.h" NoiseFigureSink::NoiseFigureSink(NoiseFigure *noiseFigure) : - m_noiseFigure(noiseFigure), m_channelSampleRate(48000), m_fftSequence(-1), m_fft(nullptr), @@ -39,6 +38,8 @@ NoiseFigureSink::NoiseFigureSink(NoiseFigure *noiseFigure) : m_count(0), m_enabled(false) { + (void)noiseFigure; + m_magsq = 0.0; applySettings(m_settings, true); diff --git a/plugins/channelrx/noisefigure/noisefiguresink.h b/plugins/channelrx/noisefigure/noisefiguresink.h index 2bf11bb0f..007a1fbe7 100644 --- a/plugins/channelrx/noisefigure/noisefiguresink.h +++ b/plugins/channelrx/noisefigure/noisefiguresink.h @@ -81,7 +81,6 @@ private: double m_magsqPeak; }; - NoiseFigure *m_noiseFigure; NoiseFigureSettings m_settings; ChannelAPI *m_channel; int m_channelSampleRate; diff --git a/plugins/channelrx/radioastronomy/radioastronomygui.cpp b/plugins/channelrx/radioastronomy/radioastronomygui.cpp index 185bfd384..9c7192100 100644 --- a/plugins/channelrx/radioastronomy/radioastronomygui.cpp +++ b/plugins/channelrx/radioastronomy/radioastronomygui.cpp @@ -378,7 +378,7 @@ void RadioAstronomyGUI::addToPowerSeries(FFTMeasurement *fft, bool skipCalcs) && !((m_settings.m_powerYUnits == RadioAstronomySettings::PY_DBM) && (fft->m_tSys == 0.0f)) // dBm value not valid if temp is 0 ) { - qreal power; + qreal power = 0.0; switch (m_settings.m_powerYData) { case RadioAstronomySettings::PY_POWER: diff --git a/plugins/channelrx/radioclock/radioclocksink.cpp b/plugins/channelrx/radioclock/radioclocksink.cpp index 5b449c43b..9598249aa 100644 --- a/plugins/channelrx/radioclock/radioclocksink.cpp +++ b/plugins/channelrx/radioclock/radioclocksink.cpp @@ -28,7 +28,6 @@ RadioClockSink::RadioClockSink(RadioClock *radioClock) : m_scopeSink(nullptr), - m_radioClock(radioClock), m_channelSampleRate(RadioClockSettings::RADIOCLOCK_CHANNEL_SAMPLE_RATE), m_channelFrequencyOffset(0), m_magsq(0.0), @@ -49,6 +48,8 @@ RadioClockSink::RadioClockSink(RadioClock *radioClock) : m_sampleBufferIndex(0), m_gotMarker(false) { + (void)radioClock; + m_phaseDiscri.setFMScaling(RadioClockSettings::RADIOCLOCK_CHANNEL_SAMPLE_RATE / (2.0f * 20.0/M_PI)); applySettings(m_settings, true); applyChannelSettings(m_channelSampleRate, m_channelFrequencyOffset, true); diff --git a/plugins/channelrx/radioclock/radioclocksink.h b/plugins/channelrx/radioclock/radioclocksink.h index bbd18d39a..58fe8809a 100644 --- a/plugins/channelrx/radioclock/radioclocksink.h +++ b/plugins/channelrx/radioclock/radioclocksink.h @@ -86,7 +86,6 @@ private: }; ScopeVis* m_scopeSink; // Scope GUI to display debug waveforms - RadioClock *m_radioClock; RadioClockSettings m_settings; ChannelAPI *m_channel; int m_channelSampleRate; diff --git a/plugins/channelrx/remotesink/remotesink.h b/plugins/channelrx/remotesink/remotesink.h index 4fbc49e4d..5c4d2cdf1 100644 --- a/plugins/channelrx/remotesink/remotesink.h +++ b/plugins/channelrx/remotesink/remotesink.h @@ -132,7 +132,6 @@ private: bool m_running; RemoteSinkSettings m_settings; - uint64_t m_centerFrequency; int64_t m_frequencyOffset; int m_basebandSampleRate; diff --git a/plugins/channelrx/remotetcpsink/remotetcpsink.h b/plugins/channelrx/remotetcpsink/remotetcpsink.h index 4b5cf1108..9533053d3 100644 --- a/plugins/channelrx/remotetcpsink/remotetcpsink.h +++ b/plugins/channelrx/remotetcpsink/remotetcpsink.h @@ -178,7 +178,6 @@ private: RemoteTCPSinkBaseband *m_basebandSink; RemoteTCPSinkSettings m_settings; - uint64_t m_centerFrequency; int m_basebandSampleRate; QNetworkAccessManager *m_networkManager; diff --git a/plugins/channelrx/remotetcpsink/remotetcpsinkgui.cpp b/plugins/channelrx/remotetcpsink/remotetcpsinkgui.cpp index 17c1fde3f..5da31d488 100644 --- a/plugins/channelrx/remotetcpsink/remotetcpsinkgui.cpp +++ b/plugins/channelrx/remotetcpsink/remotetcpsinkgui.cpp @@ -88,13 +88,13 @@ QString RemoteTCPSinkGUI::displayScaledF(float value, char type, int precision, } else { - if (posValue < 1000) { + if (posValue < 1000.0f) { return tr("%1").arg(QString::number(value, type, precision)); - } else if (posValue < 1000000) { + } else if (posValue < 1000000.0f) { return tr("%1%2").arg(QString::number(value / 1000.0, type, precision)).arg(showMult ? "k" : ""); - } else if (posValue < 1000000000) { + } else if (posValue < 1000000000.0f) { return tr("%1%2").arg(QString::number(value / 1000000.0, type, precision)).arg(showMult ? "M" : ""); - } else if (posValue < 1000000000000) { + } else if (posValue < 1000000000000.0f) { return tr("%1%2").arg(QString::number(value / 1000000000.0, type, precision)).arg(showMult ? "G" : ""); } else { return tr("%1").arg(QString::number(value, 'e', precision)); diff --git a/plugins/channelrx/sigmffilesink/sigmffilesinksink.h b/plugins/channelrx/sigmffilesink/sigmffilesinksink.h index 444b5577a..e0675deaf 100644 --- a/plugins/channelrx/sigmffilesink/sigmffilesinksink.h +++ b/plugins/channelrx/sigmffilesink/sigmffilesinksink.h @@ -71,7 +71,6 @@ private: SigMFFileRecord m_fileSink; SampleSimpleFifo m_preRecordBuffer; unsigned int m_preRecordFill; - float m_squelchLevel; SpectrumVis* m_spectrumSink; MessageQueue *m_msgQueueToGUI; bool m_recordEnabled; diff --git a/plugins/channeltx/filesource/filesource.cpp b/plugins/channeltx/filesource/filesource.cpp index 846e07251..9ee6e78e6 100644 --- a/plugins/channeltx/filesource/filesource.cpp +++ b/plugins/channeltx/filesource/filesource.cpp @@ -54,8 +54,7 @@ FileSource::FileSource(DeviceAPI *deviceAPI) : ChannelAPI(m_channelIdURI, ChannelAPI::StreamSingleSource), m_deviceAPI(deviceAPI), m_frequencyOffset(0), - m_basebandSampleRate(0), - m_linearGain(0.0) + m_basebandSampleRate(0) { setObjectName(m_channelId); diff --git a/plugins/channeltx/filesource/filesource.h b/plugins/channeltx/filesource/filesource.h index bf89c4b69..c9d9cf6ef 100644 --- a/plugins/channeltx/filesource/filesource.h +++ b/plugins/channeltx/filesource/filesource.h @@ -235,7 +235,6 @@ private: QRecursiveMutex m_settingsMutex; uint64_t m_frequencyOffset; uint32_t m_basebandSampleRate; - double m_linearGain; QNetworkAccessManager *m_networkManager; QNetworkRequest m_networkRequest; diff --git a/plugins/channeltx/filesource/filesourcesource.cpp b/plugins/channeltx/filesource/filesourcesource.cpp index c0fe28f76..11d85ca18 100644 --- a/plugins/channeltx/filesource/filesourcesource.cpp +++ b/plugins/channeltx/filesource/filesourcesource.cpp @@ -37,11 +37,9 @@ FileSourceSource::FileSourceSource() : m_fileName("..."), m_sampleSize(0), m_centerFrequency(0), - m_frequencyOffset(0), m_fileSampleRate(0), m_samplesCount(0), m_sampleRate(0), - m_deviceSampleRate(0), m_recordLengthMuSec(0), m_startingTimeStamp(0), m_running(false), diff --git a/plugins/channeltx/filesource/filesourcesource.h b/plugins/channeltx/filesource/filesourcesource.h index 27801820c..c6ba48392 100644 --- a/plugins/channeltx/filesource/filesourcesource.h +++ b/plugins/channeltx/filesource/filesourcesource.h @@ -92,19 +92,15 @@ private: double m_magsqPeak; }; - int m_channelSampleRate; - int m_channelFrequencyOffset; FileSourceSettings m_settings; std::ifstream m_ifstream; QString m_fileName; quint32 m_sampleSize; quint64 m_centerFrequency; - int64_t m_frequencyOffset; uint32_t m_fileSampleRate; quint64 m_samplesCount; uint32_t m_sampleRate; - uint32_t m_deviceSampleRate; quint64 m_recordLengthMuSec; //!< record length in microseconds computed from file size quint64 m_startingTimeStamp; QTimer m_masterTimer; diff --git a/plugins/channeltx/moddatv/dvb-s2/DVB2.cpp b/plugins/channeltx/moddatv/dvb-s2/DVB2.cpp index bf12f2a3e..66b7c12ae 100644 --- a/plugins/channeltx/moddatv/dvb-s2/DVB2.cpp +++ b/plugins/channeltx/moddatv/dvb-s2/DVB2.cpp @@ -273,8 +273,6 @@ int DVB2::next_ts_frame_base( u8 *ts ) } DVB2::DVB2(void) { - // Clear the transport queue - m_tp_q.empty(); init_bb_randomiser(); bch_poly_build_tables(); build_crc8_table(); diff --git a/plugins/channeltx/modm17/m17modsource.cpp b/plugins/channeltx/modm17/m17modsource.cpp index 2146d0de0..db223cb76 100644 --- a/plugins/channeltx/modm17/m17modsource.cpp +++ b/plugins/channeltx/modm17/m17modsource.cpp @@ -130,7 +130,7 @@ void M17ModSource::pullOne(Sample& sample) void M17ModSource::prefetch(unsigned int nbSamples) { - if ((m_settings.m_m17Mode == M17ModSettings::M17ModeFMAudio)) + if (m_settings.m_m17Mode == M17ModSettings::M17ModeFMAudio) { unsigned int nbSamplesAudio = nbSamples * ((Real) m_audioSampleRate / (Real) m_channelSampleRate); pullAudio(nbSamplesAudio); diff --git a/plugins/channeltx/modnfm/nfmmoddcs.h b/plugins/channeltx/modnfm/nfmmoddcs.h index a7934aeb7..1b43095ac 100644 --- a/plugins/channeltx/modnfm/nfmmoddcs.h +++ b/plugins/channeltx/modnfm/nfmmoddcs.h @@ -33,7 +33,6 @@ public: int next(); //!< +1/-1 sample private: - int m_shift; //!< current frequency shift: -1 or 1 int m_dcsWord[23]; //!< current DCS word in transmit order including parity and filler 11 + 3 + 9 float m_step; bool m_positive; diff --git a/plugins/channeltx/modpacket/packetmod.cpp b/plugins/channeltx/modpacket/packetmod.cpp index 4e25fbf6f..5abc2b3ed 100644 --- a/plugins/channeltx/modpacket/packetmod.cpp +++ b/plugins/channeltx/modpacket/packetmod.cpp @@ -59,7 +59,6 @@ PacketMod::PacketMod(DeviceAPI *deviceAPI) : ChannelAPI(m_channelIdURI, ChannelAPI::StreamSingleSource), m_deviceAPI(deviceAPI), m_spectrumVis(SDR_TX_SCALEF), - m_sampleRate(48000), m_udpSocket(nullptr) { setObjectName(m_channelId); diff --git a/plugins/channeltx/modpacket/packetmod.h b/plugins/channeltx/modpacket/packetmod.h index 66bb7c4ee..74783e636 100644 --- a/plugins/channeltx/modpacket/packetmod.h +++ b/plugins/channeltx/modpacket/packetmod.h @@ -229,8 +229,6 @@ private: SampleVector m_sampleBuffer; QRecursiveMutex m_settingsMutex; - int m_sampleRate; - QNetworkAccessManager *m_networkManager; QNetworkRequest m_networkRequest; QUdpSocket *m_udpSocket; diff --git a/plugins/channeltx/modpsk31/psk31mod.cpp b/plugins/channeltx/modpsk31/psk31mod.cpp index 29538ced3..9e691a131 100644 --- a/plugins/channeltx/modpsk31/psk31mod.cpp +++ b/plugins/channeltx/modpsk31/psk31mod.cpp @@ -55,7 +55,6 @@ PSK31::PSK31(DeviceAPI *deviceAPI) : ChannelAPI(m_channelIdURI, ChannelAPI::StreamSingleSource), m_deviceAPI(deviceAPI), m_spectrumVis(SDR_TX_SCALEF), - m_sampleRate(48000), m_udpSocket(nullptr) { setObjectName(m_channelId); diff --git a/plugins/channeltx/modpsk31/psk31mod.h b/plugins/channeltx/modpsk31/psk31mod.h index 4b217ab88..fe149ea1d 100644 --- a/plugins/channeltx/modpsk31/psk31mod.h +++ b/plugins/channeltx/modpsk31/psk31mod.h @@ -214,8 +214,6 @@ private: SampleVector m_sampleBuffer; QRecursiveMutex m_settingsMutex; - int m_sampleRate; - QNetworkAccessManager *m_networkManager; QNetworkRequest m_networkRequest; QUdpSocket *m_udpSocket; diff --git a/plugins/channeltx/modrtty/rttymod.cpp b/plugins/channeltx/modrtty/rttymod.cpp index 140d62728..b22d30773 100644 --- a/plugins/channeltx/modrtty/rttymod.cpp +++ b/plugins/channeltx/modrtty/rttymod.cpp @@ -55,7 +55,6 @@ RttyMod::RttyMod(DeviceAPI *deviceAPI) : ChannelAPI(m_channelIdURI, ChannelAPI::StreamSingleSource), m_deviceAPI(deviceAPI), m_spectrumVis(SDR_TX_SCALEF), - m_sampleRate(48000), m_udpSocket(nullptr) { setObjectName(m_channelId); diff --git a/plugins/channeltx/modrtty/rttymod.h b/plugins/channeltx/modrtty/rttymod.h index ea332c678..5fbadb76a 100644 --- a/plugins/channeltx/modrtty/rttymod.h +++ b/plugins/channeltx/modrtty/rttymod.h @@ -214,8 +214,6 @@ private: SampleVector m_sampleBuffer; QRecursiveMutex m_settingsMutex; - int m_sampleRate; - QNetworkAccessManager *m_networkManager; QNetworkRequest m_networkRequest; QUdpSocket *m_udpSocket; diff --git a/plugins/feature/gs232controller/inputcontroller.cpp b/plugins/feature/gs232controller/inputcontroller.cpp index 102900988..07269e8ca 100644 --- a/plugins/feature/gs232controller/inputcontroller.cpp +++ b/plugins/feature/gs232controller/inputcontroller.cpp @@ -60,6 +60,7 @@ InputController* InputControllerManager::open(const QString& name) #ifdef QT_GAMEPAD_FOUND return GamepadInputController::open(name); #else + (void)name; return nullptr; #endif } diff --git a/plugins/feature/map/mapgui.cpp b/plugins/feature/map/mapgui.cpp index 8714b4884..b62565cdd 100644 --- a/plugins/feature/map/mapgui.cpp +++ b/plugins/feature/map/mapgui.cpp @@ -1824,6 +1824,7 @@ void MapGUI::applyMap3DSettings(bool reloadMap) m_imageMapModel.allUpdated(); m_polygonMapModel.allUpdated(); m_polylineMapModel.allUpdated(); + (void)reloadMap; #endif } diff --git a/plugins/feature/startracker/startracker.cpp b/plugins/feature/startracker/startracker.cpp index d7a156a27..1f33d784a 100644 --- a/plugins/feature/startracker/startracker.cpp +++ b/plugins/feature/startracker/startracker.cpp @@ -695,7 +695,6 @@ double StarTracker::applyBeam(const FITS *fits, double beamwidth, double ra, dou numberOfCoeffsV++; } double *beam = new double[numberOfCoeffsH*numberOfCoeffsV]; - double sum = 0.0; int y0 = numberOfCoeffsV/2; int x0 = numberOfCoeffsH/2; int nonZeroCount = 0; @@ -709,7 +708,6 @@ double StarTracker::applyBeam(const FITS *fits, double beamwidth, double ra, dou if (r < halfBeamwidth) { beam[y*numberOfCoeffsH+x] = pow(cos(Units::degreesToRadians(r)), p); - sum += beam[y*numberOfCoeffsH+x]; nonZeroCount++; } else diff --git a/plugins/samplemimo/audiocatsiso/audiocatsisosettings.h b/plugins/samplemimo/audiocatsiso/audiocatsisosettings.h index 10e55689c..d93b6d368 100644 --- a/plugins/samplemimo/audiocatsiso/audiocatsisosettings.h +++ b/plugins/samplemimo/audiocatsiso/audiocatsisosettings.h @@ -25,7 +25,8 @@ #include "audio/audiodeviceinfo.h" #include "util/message.h" -struct AudioCATSISOSettings { +class AudioCATSISOSettings{ +public: class MsgPTT : public Message { MESSAGE_CLASS_DECLARATION diff --git a/plugins/samplemimo/metismiso/metismisoudphandler.cpp b/plugins/samplemimo/metismiso/metismisoudphandler.cpp index 3b8741207..0beb168fb 100644 --- a/plugins/samplemimo/metismiso/metismisoudphandler.cpp +++ b/plugins/samplemimo/metismiso/metismisoudphandler.cpp @@ -483,7 +483,7 @@ void MetisMISOUDPHandler::processIQBuffer(unsigned char* buffer) { int b = 0; unsigned int r; - int sampleI, sampleQ, sampleMic; + int sampleI, sampleQ; if (buffer[b++]==0x7F && buffer[b++]==0x7F && buffer[b++]==0x7F) @@ -622,8 +622,9 @@ void MetisMISOUDPHandler::processIQBuffer(unsigned char* buffer) } } - sampleMic = (int)((signed char) buffer[b++]) << 8; - sampleMic += (int)((unsigned char)buffer[b++]); + // sampleMic + b+=2; + m_sampleTxCount++; if (m_sampleTxCount >= 63) // 63 samples per 512 byte Tx block diff --git a/plugins/samplesink/remoteoutput/remoteoutputworker.cpp b/plugins/samplesink/remoteoutput/remoteoutputworker.cpp index 5dab5876c..e2db10fbf 100644 --- a/plugins/samplesink/remoteoutput/remoteoutputworker.cpp +++ b/plugins/samplesink/remoteoutput/remoteoutputworker.cpp @@ -116,8 +116,6 @@ void RemoteOutputWorker::tick() m_throttleToggle = !m_throttleToggle; } - SampleVector::iterator readUntil; - SampleVector& data = m_sampleFifo->getData(); unsigned int iPart1Begin, iPart1End, iPart2Begin, iPart2End; m_sampleFifo->read(m_samplesChunkSize, iPart1Begin, iPart1End, iPart2Begin, iPart2End); diff --git a/plugins/samplesource/androidsdrdriverinput/androidsdrdriverinput.cpp b/plugins/samplesource/androidsdrdriverinput/androidsdrdriverinput.cpp index 350e4ac54..f14b5b882 100644 --- a/plugins/samplesource/androidsdrdriverinput/androidsdrdriverinput.cpp +++ b/plugins/samplesource/androidsdrdriverinput/androidsdrdriverinput.cpp @@ -35,6 +35,9 @@ #include "androidsdrdriverinput.h" #include "androidsdrdriverinputtcphandler.h" +#ifdef ANDROID +#include "util/android.h" +#endif MESSAGE_CLASS_DEFINITION(AndroidSDRDriverInput::MsgConfigureAndroidSDRDriverInput, Message) MESSAGE_CLASS_DEFINITION(AndroidSDRDriverInput::MsgStartStop, Message) diff --git a/plugins/samplesource/androidsdrdriverinput/androidsdrdriverinputtcphandler.h b/plugins/samplesource/androidsdrdriverinput/androidsdrdriverinputtcphandler.h index 4a65fc9eb..b856f2d28 100644 --- a/plugins/samplesource/androidsdrdriverinput/androidsdrdriverinputtcphandler.h +++ b/plugins/samplesource/androidsdrdriverinput/androidsdrdriverinputtcphandler.h @@ -27,6 +27,7 @@ #include #include "util/messagequeue.h" +#include "util/message.h" #include "androidsdrdriverinputsettings.h" #include "../../channelrx/remotetcpsink/remotetcpprotocol.h" diff --git a/plugins/samplesource/fcdproplus/fcdproplusplugin.cpp b/plugins/samplesource/fcdproplus/fcdproplusplugin.cpp index 37c71cc12..77381bf1d 100644 --- a/plugins/samplesource/fcdproplus/fcdproplusplugin.cpp +++ b/plugins/samplesource/fcdproplus/fcdproplusplugin.cpp @@ -40,8 +40,6 @@ const PluginDescriptor FCDProPlusPlugin::m_pluginDescriptor = { QStringLiteral("https://github.com/f4exb/sdrangel") }; -static constexpr const char* const m_deviceTypeID = FCDPROPLUS_DEVICE_TYPE_ID; - FCDProPlusPlugin::FCDProPlusPlugin(QObject* parent) : QObject(parent) { diff --git a/plugins/samplesource/fileinput/fileinputworker.h b/plugins/samplesource/fileinput/fileinputworker.h index 6e9cb4a33..985f1803c 100644 --- a/plugins/samplesource/fileinput/fileinputworker.h +++ b/plugins/samplesource/fileinput/fileinputworker.h @@ -27,6 +27,9 @@ #include #include #include +#ifdef ANDROID +#include +#endif #include "util/message.h" diff --git a/plugins/samplesource/sigmffileinput/sigmffiledata.h b/plugins/samplesource/sigmffileinput/sigmffiledata.h index 5d0c2495d..bc4fccd6b 100644 --- a/plugins/samplesource/sigmffileinput/sigmffiledata.h +++ b/plugins/samplesource/sigmffileinput/sigmffiledata.h @@ -64,8 +64,9 @@ struct SigMFFileDataType } }; -struct SigMFFileMetaInfo +class SigMFFileMetaInfo { +public: // core QString m_dataTypeStr; SigMFFileDataType m_dataType; @@ -153,8 +154,9 @@ struct SigMFFileMetaInfo } }; -struct SigMFFileCapture +class SigMFFileCapture { +public: uint64_t m_tsms; //!< Unix timestamp in milliseconds uint64_t m_centerFrequency; //!< Center frequency in Hz uint64_t m_sampleStart; //!< Sample index at which capture start diff --git a/plugins/samplesource/sigmffileinput/sigmffileinputworker.cpp b/plugins/samplesource/sigmffileinput/sigmffileinputworker.cpp index e04a708ea..ae8225c12 100644 --- a/plugins/samplesource/sigmffileinput/sigmffileinputworker.cpp +++ b/plugins/samplesource/sigmffileinput/sigmffileinputworker.cpp @@ -625,8 +625,8 @@ void SigMFFileInputWorker::writeToSampleFifoBAK(const quint8* buf, qint32 nbByte nbSamples = nbBytes / (2 * m_samplebytes); for (int is = 0; is < nbSamples; is++) { - convertBuf[2*is] = fileBuf[2*is] >> (SDR_RX_SAMP_SZ == 24) ? 8 : 16; - convertBuf[2*is+1] = fileBuf[2*is+1] >> (SDR_RX_SAMP_SZ == 24) ? 8 : 16; + convertBuf[2*is] = fileBuf[2*is] >> ((SDR_RX_SAMP_SZ == 24) ? 8 : 16); + convertBuf[2*is+1] = fileBuf[2*is+1] >> ((SDR_RX_SAMP_SZ == 24) ? 8 : 16); } } else @@ -634,7 +634,7 @@ void SigMFFileInputWorker::writeToSampleFifoBAK(const quint8* buf, qint32 nbByte nbSamples = nbBytes / m_samplebytes; for (int is = 0; is < nbSamples; is++) { - convertBuf[2*is] = fileBuf[is] >> (SDR_RX_SAMP_SZ == 24) ? 8 : 16; + convertBuf[2*is] = fileBuf[is] >> ((SDR_RX_SAMP_SZ == 24) ? 8 : 16); convertBuf[2*is+1] = 0; } } @@ -715,9 +715,9 @@ void SigMFFileInputWorker::writeToSampleFifoBAK(const quint8* buf, qint32 nbByte nbSamples = nbBytes / (2 * m_samplebytes); for (int is = 0; is < nbSamples; is++) { - convertBuf[2*is] = (fileBuf[2*is] >> (SDR_RX_SAMP_SZ == 24) ? 8 : 16) + convertBuf[2*is] = (fileBuf[2*is] >> ((SDR_RX_SAMP_SZ == 24) ? 8 : 16)) - ((SDR_RX_SAMP_SZ == 24) ? (1<<23) : (1<<15)); - convertBuf[2*is+1] = (fileBuf[2*is+1] >> (SDR_RX_SAMP_SZ == 24) ? 8 : 16) + convertBuf[2*is+1] = (fileBuf[2*is+1] >> ((SDR_RX_SAMP_SZ == 24) ? 8 : 16)) - ((SDR_RX_SAMP_SZ == 24) ? (1<<23) : (1<<15));; } } @@ -726,7 +726,7 @@ void SigMFFileInputWorker::writeToSampleFifoBAK(const quint8* buf, qint32 nbByte nbSamples = nbBytes / m_samplebytes; for (int is = 0; is < nbSamples; is++) { - convertBuf[2*is] = (fileBuf[is] >> (SDR_RX_SAMP_SZ == 24) ? 8 : 16) + convertBuf[2*is] = (fileBuf[is] >> ((SDR_RX_SAMP_SZ == 24) ? 8 : 16)) - ((SDR_RX_SAMP_SZ == 24) ? (1<<23) : (1<<15)); convertBuf[2*is+1] = 0; } diff --git a/qrtplib/rtprandom.cpp b/qrtplib/rtprandom.cpp index 9362649f5..c354e6aa7 100644 --- a/qrtplib/rtprandom.cpp +++ b/qrtplib/rtprandom.cpp @@ -66,7 +66,7 @@ uint32_t RTPRandom::PickSeed() #else x += (uint32_t)clock(); #endif - x ^= (uint32_t)((uint8_t *)this - (uint8_t *)0); + x ^= (uint32_t)(size_t)this; return x; } diff --git a/sdrbase/audio/audioinputdevice.cpp b/sdrbase/audio/audioinputdevice.cpp index 5ac907a90..955c644c0 100644 --- a/sdrbase/audio/audioinputdevice.cpp +++ b/sdrbase/audio/audioinputdevice.cpp @@ -143,7 +143,7 @@ bool AudioInputDevice::start(int device, int rate) if (m_audioInput->state() != QAudio::ActiveState) { qWarning("AudioInputDevice::start: cannot start"); } else { - qDebug("AudioInputDevice::start: started buffer: %d bytes", m_audioInput->bufferSize()); + qDebug("AudioInputDevice::start: started buffer: %d bytes", (int)m_audioInput->bufferSize()); } // } diff --git a/sdrbase/audio/audiooutputdevice.cpp b/sdrbase/audio/audiooutputdevice.cpp index c168b1f3c..cee5ad1d6 100644 --- a/sdrbase/audio/audiooutputdevice.cpp +++ b/sdrbase/audio/audiooutputdevice.cpp @@ -176,7 +176,7 @@ bool AudioOutputDevice::start(int deviceIndex, int sampleRate) if (m_audioOutput->state() != QAudio::ActiveState) { qWarning() << "AudioOutputDevice::start: cannot start - " << m_audioOutput->error(); } else { - qDebug("AudioOutputDevice::start: started buffer: %d bytes", m_audioOutput->bufferSize()); + qDebug("AudioOutputDevice::start: started buffer: %d bytes", (int)m_audioOutput->bufferSize()); } if (m_managerMessageQueue) { diff --git a/sdrbase/channel/channelapi.cpp b/sdrbase/channel/channelapi.cpp index 8141ddc4e..9e5770eee 100644 --- a/sdrbase/channel/channelapi.cpp +++ b/sdrbase/channel/channelapi.cpp @@ -22,6 +22,7 @@ #include "util/uid.h" #include "channelapi.h" +#include "util/message.h" ChannelAPI::ChannelAPI(const QString& uri, StreamType streamType) : m_guiMessageQueue(nullptr), diff --git a/sdrbase/maincore.cpp b/sdrbase/maincore.cpp index 742d2266c..b80407deb 100644 --- a/sdrbase/maincore.cpp +++ b/sdrbase/maincore.cpp @@ -423,7 +423,7 @@ void MainCore::positionError(QGeoPositionInfoSource::Error positioningError) void MainCore::updateWakeLock() { bool running = false; - for (int i = 0; i < m_deviceSets.size(); i++) + for (size_t i = 0; i < m_deviceSets.size(); i++) { if (m_deviceSets[i]->m_deviceAPI->state() == DeviceAPI::StRunning) { diff --git a/sdrbase/pipes/datafifostore.cpp b/sdrbase/pipes/datafifostore.cpp index d9248eca0..6a81e40b8 100644 --- a/sdrbase/pipes/datafifostore.cpp +++ b/sdrbase/pipes/datafifostore.cpp @@ -34,7 +34,7 @@ QObject *DataFifoStore::createElement() { DataFifo *fifo = new DataFifo(); m_dataFifos.push_back(fifo); - qDebug("DataFifoStore::createElement: %d added", m_dataFifos.size() - 1); + qDebug("DataFifoStore::createElement: %d added", (int)m_dataFifos.size() - 1); return fifo; } diff --git a/sdrbase/pipes/messagequeuestore.cpp b/sdrbase/pipes/messagequeuestore.cpp index f93e1283c..8e7c53d27 100644 --- a/sdrbase/pipes/messagequeuestore.cpp +++ b/sdrbase/pipes/messagequeuestore.cpp @@ -34,7 +34,7 @@ QObject *MessageQueueStore::createElement() { MessageQueue *messageQueue = new MessageQueue(); m_messageQueues.push_back(messageQueue); - qDebug("MessageQueueStore::createElement: %d added", m_messageQueues.size() - 1); + qDebug("MessageQueueStore::createElement: %d added", (int)m_messageQueues.size() - 1); return messageQueue; } diff --git a/sdrbase/util/iot/tplink.cpp b/sdrbase/util/iot/tplink.cpp index 453e1cdc4..31ce4a32c 100644 --- a/sdrbase/util/iot/tplink.cpp +++ b/sdrbase/util/iot/tplink.cpp @@ -519,7 +519,6 @@ void TPLinkDeviceDiscoverer::handleReply(QNetworkReply* reply) if (sysInfoObj.contains(QStringLiteral("child_num"))) { QJsonArray children = sysInfoObj.value(QStringLiteral("children")).toArray(); - int child = 1; for (auto childRef : children) { QJsonObject childObj = childRef.toObject(); @@ -530,7 +529,6 @@ void TPLinkDeviceDiscoverer::handleReply(QNetworkReply* reply) } controlInfo->m_type = DeviceDiscoverer::BOOL; info.m_controls.append(controlInfo); - child++; } } else if (sysInfoObj.contains(QStringLiteral("relay_state"))) diff --git a/sdrgui/gui/featurelayout.cpp b/sdrgui/gui/featurelayout.cpp index 98b9612ee..9b116fc3a 100644 --- a/sdrgui/gui/featurelayout.cpp +++ b/sdrgui/gui/featurelayout.cpp @@ -233,12 +233,6 @@ QSize FeatureLayout::doLayoutVertically(const QRect &rect, bool testOnly) const int lineHeight = 0; int spaceX = 0; int spaceY = 0; - - // Calculate space available for rows of widgets - int maxHeightForRows = effectiveRect.height(); - if (itemList.size() > 0) { - maxHeightForRows -= itemList[0]->minimumSize().height(); - } int minWidth = 0; int i = 0; diff --git a/sdrgui/gui/glscope.cpp b/sdrgui/gui/glscope.cpp index 47ba26f26..c2a1c0c9e 100644 --- a/sdrgui/gui/glscope.cpp +++ b/sdrgui/gui/glscope.cpp @@ -858,7 +858,6 @@ void GLScope::paintGL() void GLScope::drawMarkers() { QVector4D markerColor(1.0f, 1.0f, 1.0f, 0.3f); - QVector4D markerTextColor(1.0f, 1.0f, 1.0f, 0.8f); if ((m_markers1.size() > 0) && ((m_displayMode == DisplayX) || (m_displayMode == DisplayXYH) || (m_displayMode == DisplayXYV))) // Draw markers1 { @@ -2397,13 +2396,13 @@ QString GLScope::displayScaled(float value, char type, int precision) } else { - if (posValue < 1000) { + if (posValue < 1000.0f) { return tr("%1").arg(QString::number(value, type, precision)); - } else if (posValue < 1000000) { + } else if (posValue < 1000000.0f) { return tr("%1k").arg(QString::number(value / 1000.0, type, precision)); - } else if (posValue < 1000000000) { + } else if (posValue < 1000000000.0f) { return tr("%1M").arg(QString::number(value / 1000000.0, type, precision)); - } else if (posValue < 1000000000000) { + } else if (posValue < 1000000000000.0f) { return tr("%1G").arg(QString::number(value / 1000000000.0, type, precision)); } else { return tr("%1").arg(QString::number(value, 'e', precision)); diff --git a/sdrgui/mainwindow.cpp b/sdrgui/mainwindow.cpp index 3b905a7dd..ea187b4df 100644 --- a/sdrgui/mainwindow.cpp +++ b/sdrgui/mainwindow.cpp @@ -1350,9 +1350,9 @@ void MainWindow::loadConfiguration(const Configuration *configuration, bool from qDebug("MainWindow::loadConfiguration: configuration [%s | %s] %d workspace(s) - %d device set(s) - %d feature(s)", qPrintable(configuration->getGroup()), qPrintable(configuration->getDescription()), - configuration->getNumberOfWorkspaceGeometries(), - configuration->getDeviceSetPresets().size(), - configuration->getFeatureSetPreset().getFeatureCount() + (int)configuration->getNumberOfWorkspaceGeometries(), + (int)configuration->getDeviceSetPresets().size(), + (int)configuration->getFeatureSetPreset().getFeatureCount() ); QProgressDialog *waitBox = nullptr; @@ -1549,7 +1549,7 @@ void MainWindow::saveConfiguration(Configuration *configuration) qDebug("MainWindow::saveConfiguration: configuration [%s | %s] %d workspaces", qPrintable(configuration->getGroup()), qPrintable(configuration->getDescription()), - m_workspaces.size() + (int)m_workspaces.size() ); configuration->clearData(); diff --git a/wdsp/gain.hpp b/wdsp/gain.hpp index 5e6e2e3d0..1f29105a9 100644 --- a/wdsp/gain.hpp +++ b/wdsp/gain.hpp @@ -25,7 +25,7 @@ warren@wpratt.com */ -#ifndef wdso_gain_h +#ifndef wdsp_gain_h #define wdsp_gain_h #include "export.h"