activated compiler warnings

This commit is contained in:
f4exb 2017-05-25 20:13:34 +02:00
parent d6f62a69dd
commit 3a3d8e3dcb
157 changed files with 655 additions and 772 deletions

View File

@ -529,6 +529,9 @@ endif()
##############################################################################
# Compiler flags.
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Wextra -Werror -fmax-errors=10 -std=c++11 -O2 -ffast-math -ftree-vectorize ${EXTRA_FLAGS}")
set(sdrangel_SOURCES
app/main.cpp
)

View File

@ -6,7 +6,6 @@ if (BUILD_DEBIAN)
add_subdirectory(bladerf)
add_subdirectory(hackrf)
add_subdirectory(limesdr)
add_subdirectory(sdrdaemon)
else(BUILD_DEBIAN)
find_package(LibBLADERF)
if(LIBUSB_FOUND AND LIBBLADERF_FOUND)
@ -23,9 +22,4 @@ else(BUILD_DEBIAN)
add_subdirectory(limesdr)
endif(LIBUSB_FOUND AND LIMESUITE_FOUND)
find_package(CM256cc)
if(CM256CC_FOUND)
add_subdirectory(sdrdaemon)
endif(CM256CC_FOUND AND LIBNANOMSG_FOUND)
endif (BUILD_DEBIAN)

View File

@ -20,10 +20,9 @@
bool DeviceBladeRF::open_bladerf(struct bladerf **dev, const char *serial)
{
int res;
int fpga_loaded;
if ((*dev = open_bladerf_from_serial(0)) == 0)
if ((*dev = open_bladerf_from_serial(serial)) == 0)
{
fprintf(stderr, "DeviceBladeRF::open_bladerf: could not open BladeRF\n");
return false;

View File

@ -29,8 +29,8 @@
struct DeviceLimeSDRParams
{
lms_device_t *m_dev; //!< device handle
int m_nbRxChannels; //!< number of Rx channels (normally 2, we'll see if we really use it...)
int m_nbTxChannels; //!< number of Tx channels (normally 2, we'll see if we really use it...)
uint32_t m_nbRxChannels; //!< number of Rx channels (normally 2, we'll see if we really use it...)
uint32_t m_nbTxChannels; //!< number of Tx channels (normally 2, we'll see if we really use it...)
lms_range_t m_lpfRangeRx; //!< Low pass filter range information (Rx side)
lms_range_t m_lpfRangeTx; //!< Low pass filter range information (Tx side)
lms_range_t m_loRangeRx; //!< LO range for Rx

View File

@ -28,24 +28,24 @@ const int SDRdaemonFECBuffer::m_sampleSize = 2;
const int SDRdaemonFECBuffer::m_iqSampleSize = 2 * m_sampleSize;
SDRdaemonFECBuffer::SDRdaemonFECBuffer(uint32_t throttlems) :
m_frameHead(0),
m_decoderIndexHead(nbDecoderSlots/2),
m_frameHead(0),
m_curNbBlocks(0),
m_minNbBlocks(256),
m_curOriginalBlocks(0),
m_minOriginalBlocks(128),
m_curNbRecovery(0),
m_maxNbRecovery(0),
m_framesDecoded(true),
m_throttlemsNominal(throttlems),
m_readIndex(0),
m_throttlemsNominal(throttlems),
m_readBuffer(0),
m_readSize(0),
m_bufferLenSec(0.0f),
m_nbReads(0),
m_nbWrites(0),
m_balCorrection(0),
m_balCorrLimit(0),
m_curOriginalBlocks(0)
m_nbReads(0),
m_nbWrites(0),
m_balCorrection(0),
m_balCorrLimit(0)
{
m_currentMeta.init();
m_framesNbBytes = nbDecoderSlots * sizeof(BufferFrame);
@ -135,7 +135,7 @@ void SDRdaemonFECBuffer::rwCorrectionEstimate(int slotIndex)
{
int targetPivotSlot = (slotIndex + (nbDecoderSlots/2)) % nbDecoderSlots; // slot at half buffer opposite of current write slot
int targetPivotIndex = targetPivotSlot * sizeof(BufferFrame); // buffer index corresponding to start of above slot
int normalizedReadIndex = (m_readIndex < targetPivotIndex ? m_readIndex + nbDecoderSlots * sizeof(BufferFrame) : m_readIndex)
uint32_t normalizedReadIndex = (m_readIndex < targetPivotIndex ? m_readIndex + nbDecoderSlots * sizeof(BufferFrame) : m_readIndex)
- (targetPivotSlot * sizeof(BufferFrame)); // normalize read index so it is positive and zero at start of pivot slot
int dBytes;
int rwDelta = (m_nbReads * m_readNbBytes) - (m_nbWrites * sizeof(BufferFrame));
@ -157,8 +157,6 @@ void SDRdaemonFECBuffer::rwCorrectionEstimate(int slotIndex)
m_balCorrection = m_balCorrLimit;
}
float rwRatio = (float) (m_nbWrites * sizeof(BufferFrame)) / (float) (m_nbReads * m_readNbBytes);
m_nbReads = 0;
m_nbWrites = 0;
}
@ -189,7 +187,7 @@ void SDRdaemonFECBuffer::checkSlotData(int slotIndex)
}
}
void SDRdaemonFECBuffer::writeData(char *array, uint32_t length)
void SDRdaemonFECBuffer::writeData(char *array)
{
SuperBlock *superBlock = (SuperBlock *) array;
int frameIndex = superBlock->header.frameIndex;
@ -322,80 +320,7 @@ void SDRdaemonFECBuffer::writeData(char *array, uint32_t length)
} // decode
}
void SDRdaemonFECBuffer::writeData0(char *array, uint32_t length)
{
// Kept as comments for the out of sync blocks algorithms
// assert(length == m_udpPayloadSize);
//
// bool dataAvailable = false;
// SuperBlock *superBlock = (SuperBlock *) array;
// int frameIndex = superBlock->header.frameIndex;
// int decoderIndex = frameIndex % nbDecoderSlots;
// int blockIndex = superBlock->header.blockIndex;
//
//// qDebug() << "SDRdaemonFECBuffer::writeData:"
//// << " frameIndex: " << frameIndex
//// << " decoderIndex: " << decoderIndex
//// << " blockIndex: " << blockIndex;
//
// if (m_frameHead == -1) // initial state
// {
// m_decoderIndexHead = decoderIndex; // new decoder slot head
// m_frameHead = frameIndex;
// initReadIndex(); // reset read index
// initDecodeAllSlots(); // initialize all slots
// }
// else
// {
// int frameDelta = m_frameHead - frameIndex;
//
// if (frameDelta < 0)
// {
// if (-frameDelta < nbDecoderSlots) // new frame head not too new
// {
// //qDebug() << "SDRdaemonFECBuffer::writeData: new frame head (1): " << frameIndex << ":" << frameDelta << ":" << decoderIndex;
// m_decoderIndexHead = decoderIndex; // new decoder slot head
// m_frameHead = frameIndex;
// checkSlotData(decoderIndex);
// dataAvailable = true;
// initDecodeSlot(decoderIndex); // collect stats and re-initialize current slot
// }
// else if (-frameDelta <= 65536 - nbDecoderSlots) // loss of sync start over
// {
// //qDebug() << "SDRdaemonFECBuffer::writeData: loss of sync start over (1)" << frameIndex << ":" << frameDelta << ":" << decoderIndex;
// m_decoderIndexHead = decoderIndex; // new decoder slot head
// m_frameHead = frameIndex;
// initReadIndex(); // reset read index
// initDecodeAllSlots(); // re-initialize all slots
// }
// }
// else
// {
// if (frameDelta > 65536 - nbDecoderSlots) // new frame head not too new
// {
// //qDebug() << "SDRdaemonFECBuffer::writeData: new frame head (2): " << frameIndex << ":" << frameDelta << ":" << decoderIndex;
// m_decoderIndexHead = decoderIndex; // new decoder slot head
// m_frameHead = frameIndex;
// checkSlotData(decoderIndex);
// dataAvailable = true;
// initDecodeSlot(decoderIndex); // collect stats and re-initialize current slot
// }
// else if (frameDelta >= nbDecoderSlots) // loss of sync start over
// {
// //qDebug() << "SDRdaemonFECBuffer::writeData: loss of sync start over (2)" << frameIndex << ":" << frameDelta << ":" << decoderIndex;
// m_decoderIndexHead = decoderIndex; // new decoder slot head
// m_frameHead = frameIndex;
// initReadIndex(); // reset read index
// initDecodeAllSlots(); // re-initialize all slots
// }
// }
// }
//
// // decoderIndex should now be correctly set
//
}
uint8_t *SDRdaemonFECBuffer::readData(int32_t length)
uint8_t *SDRdaemonFECBuffer::readData(uint32_t length)
{
uint8_t *buffer = (uint8_t *) m_frames;
uint32_t readIndex = m_readIndex;

View File

@ -87,9 +87,8 @@ public:
~SDRdaemonFECBuffer();
// R/W operations
void writeData(char *array, uint32_t length); //!< Write data into buffer.
void writeData0(char *array, uint32_t length); //!< Write data into buffer.
uint8_t *readData(int32_t length); //!< Read data from buffer
void writeData(char *array); //!< Write data into buffer.
uint8_t *readData(uint32_t length); //!< Read data from buffer
// meta data
const MetaDataFEC& getCurrentMeta() const { return m_currentMeta; }
@ -148,7 +147,6 @@ public:
{
int32_t val = (m_wrDeltaEstimate * 100) / (int32_t) m_framesNbBytes;
int32_t ret = val < 0 ? -val - 50 : 50 -val;
int32_t rp = (m_readIndex * 100) / (int32_t) m_framesNbBytes;
return ret;
}
else
@ -189,7 +187,7 @@ private:
CM256::cm256_encoder_params m_paramsCM256; //!< CM256 decoder parameters block
DecoderSlot m_decoderSlots[nbDecoderSlots]; //!< CM256 decoding control/buffer slots
BufferFrame m_frames[nbDecoderSlots]; //!< Samples buffer
int m_framesNbBytes; //!< Number of bytes in samples buffer
uint32_t m_framesNbBytes; //!< Number of bytes in samples buffer
int m_decoderIndexHead; //!< index of the current head frame slot in decoding slots
int m_frameHead; //!< index of the current head frame sent
int m_curNbBlocks; //!< (stats) instantaneous number of blocks received

View File

@ -60,7 +60,7 @@ void ChannelAnalyzer::configure(MessageQueue* messageQueue,
messageQueue->push(cmd);
}
void ChannelAnalyzer::feed(const SampleVector::const_iterator& begin, const SampleVector::const_iterator& end, bool positiveOnly)
void ChannelAnalyzer::feed(const SampleVector::const_iterator& begin, const SampleVector::const_iterator& end, bool positiveOnly __attribute__((unused)))
{
fftfilt::cmplx *sideband;
int n_out;

View File

@ -14,14 +14,14 @@
// along with this program. If not, see <http://www.gnu.org/licenses/>. //
///////////////////////////////////////////////////////////////////////////////////
#include "../../channelrx/chanalyzer/chanalyzergui.h"
#include "chanalyzergui.h"
#include <device/devicesourceapi.h>
#include <dsp/downchannelizer.h>
#include <QDockWidget>
#include <QMainWindow>
#include "../../../sdrbase/dsp/threadedbasebandsamplesink.h"
#include "dsp/threadedbasebandsamplesink.h"
#include "ui_chanalyzergui.h"
#include "dsp/spectrumscopecombovis.h"
#include "dsp/spectrumvis.h"
@ -35,7 +35,7 @@
#include "dsp/dspengine.h"
#include "mainwindow.h"
#include "../../channelrx/chanalyzer/chanalyzer.h"
#include "chanalyzer.h"
const QString ChannelAnalyzerGUI::m_channelID = "org.f4exb.sdrangelove.channel.chanalyzer";
@ -154,7 +154,7 @@ bool ChannelAnalyzerGUI::deserialize(const QByteArray& data)
}
}
bool ChannelAnalyzerGUI::handleMessage(const Message& message)
bool ChannelAnalyzerGUI::handleMessage(const Message& message __attribute__((unused)))
{
return false;
}
@ -289,7 +289,7 @@ void ChannelAnalyzerGUI::on_ssb_toggled(bool checked)
}
}
void ChannelAnalyzerGUI::onWidgetRolled(QWidget* widget, bool rollDown)
void ChannelAnalyzerGUI::onWidgetRolled(QWidget* widget __attribute__((unused)), bool rollDown __attribute__((unused)))
{
/*
if((widget == ui->spectrumContainer) && (m_ssbDemod != NULL))

View File

@ -46,5 +46,5 @@ PluginGUI* ChannelAnalyzerPlugin::createRxChannel(const QString& channelName, De
void ChannelAnalyzerPlugin::createInstanceChannelAnalyzer(DeviceSourceAPI *deviceAPI)
{
ChannelAnalyzerGUI* gui = ChannelAnalyzerGUI::create(m_pluginAPI, deviceAPI);
ChannelAnalyzerGUI::create(m_pluginAPI, deviceAPI);
}

View File

@ -58,9 +58,9 @@ void ChannelAnalyzerNG::configure(MessageQueue* messageQueue,
messageQueue->push(cmd);
}
void ChannelAnalyzerNG::feed(const SampleVector::const_iterator& begin, const SampleVector::const_iterator& end, bool positiveOnly)
void ChannelAnalyzerNG::feed(const SampleVector::const_iterator& begin, const SampleVector::const_iterator& end, bool positiveOnly __attribute__((unused)))
{
fftfilt::cmplx *sideband;
fftfilt::cmplx *sideband = 0;
Complex ci;
m_settingsMutex.lock();
@ -104,8 +104,6 @@ void ChannelAnalyzerNG::stop()
bool ChannelAnalyzerNG::handleMessage(const Message& cmd)
{
float bandwidth, lowCutoff;
qDebug() << "ChannelAnalyzerNG::handleMessage: " << cmd.getIdentifier();
if (DownChannelizer::MsgChannelizerNotification::match(cmd))

View File

@ -157,7 +157,7 @@ bool ChannelAnalyzerNGGUI::deserialize(const QByteArray& data)
}
}
bool ChannelAnalyzerNGGUI::handleMessage(const Message& message)
bool ChannelAnalyzerNGGUI::handleMessage(const Message& message __attribute__((unused)))
{
return false;
}
@ -194,7 +194,7 @@ void ChannelAnalyzerNGGUI::on_channelSampleRate_changed(quint64 value)
}
}
void ChannelAnalyzerNGGUI::on_useRationalDownsampler_toggled(bool checked)
void ChannelAnalyzerNGGUI::on_useRationalDownsampler_toggled(bool checked __attribute__((unused)))
{
setNewFinalRate(m_spanLog2);
applySettings();
@ -313,7 +313,7 @@ void ChannelAnalyzerNGGUI::on_ssb_toggled(bool checked)
}
}
void ChannelAnalyzerNGGUI::onWidgetRolled(QWidget* widget, bool rollDown)
void ChannelAnalyzerNGGUI::onWidgetRolled(QWidget* widget __attribute__((unused)), bool rollDown __attribute__((unused)))
{
/*
if((widget == ui->spectrumContainer) && (m_ssbDemod != NULL))

View File

@ -61,5 +61,5 @@ PluginGUI* ChannelAnalyzerNGPlugin::createRxChannel(const QString& channelName,
void ChannelAnalyzerNGPlugin::createInstanceChannelAnalyzer(DeviceSourceAPI *deviceAPI)
{
ChannelAnalyzerNGGUI* gui = ChannelAnalyzerNGGUI::create(m_pluginAPI, deviceAPI);
ChannelAnalyzerNGGUI::create(m_pluginAPI, deviceAPI);
}

View File

@ -29,13 +29,13 @@ MESSAGE_CLASS_DEFINITION(AMDemod::MsgConfigureAMDemod, Message)
AMDemod::AMDemod() :
m_squelchOpen(false),
m_audioFifo(4, 48000),
m_settingsMutex(QMutex::Recursive),
m_magsqSum(0.0f),
m_magsqPeak(0.0f),
m_magsqCount(0),
m_movingAverage(40, 0),
m_volumeAGC(4800, 1.0)
m_volumeAGC(4800, 1.0),
m_audioFifo(4, 48000),
m_settingsMutex(QMutex::Recursive)
{
setObjectName("AMDemod");
@ -69,7 +69,7 @@ void AMDemod::configure(MessageQueue* messageQueue, Real rfBandwidth, Real volum
messageQueue->push(cmd);
}
void AMDemod::feed(const SampleVector::const_iterator& begin, const SampleVector::const_iterator& end, bool firstOfBurst)
void AMDemod::feed(const SampleVector::const_iterator& begin, const SampleVector::const_iterator& end, bool firstOfBurst __attribute__((unused)))
{
Complex ci;

View File

@ -129,7 +129,7 @@ private:
Real m_interpolatorDistanceRemain;
Real m_squelchLevel;
int m_squelchCount;
uint32_t m_squelchCount;
bool m_squelchOpen;
double m_magsq;
double m_magsqSum;

View File

@ -144,7 +144,7 @@ bool AMDemodGUI::deserialize(const QByteArray& data)
}
}
bool AMDemodGUI::handleMessage(const Message& message)
bool AMDemodGUI::handleMessage(const Message& message __attribute__((unused)))
{
return false;
}
@ -159,7 +159,7 @@ void AMDemodGUI::on_deltaFrequency_changed(qint64 value)
m_channelMarker.setCenterFrequency(value);
}
void AMDemodGUI::on_bandpassEnable_toggled(bool checked)
void AMDemodGUI::on_bandpassEnable_toggled(bool checked __attribute__((unused)))
{
applySettings();
}
@ -183,12 +183,12 @@ void AMDemodGUI::on_squelch_valueChanged(int value)
applySettings();
}
void AMDemodGUI::on_audioMute_toggled(bool checked)
void AMDemodGUI::on_audioMute_toggled(bool checked __attribute__((unused)))
{
applySettings();
}
void AMDemodGUI::onWidgetRolled(QWidget* widget, bool rollDown)
void AMDemodGUI::onWidgetRolled(QWidget* widget __attribute__((unused)), bool rollDown __attribute__((unused)))
{
/*
if((widget == ui->spectrumContainer) && (m_nfmDemod != NULL))

View File

@ -46,5 +46,5 @@ PluginGUI* AMDemodPlugin::createRxChannel(const QString& channelName, DeviceSour
void AMDemodPlugin::createInstanceDemodAM(DeviceSourceAPI *deviceAPI)
{
AMDemodGUI* gui = AMDemodGUI::create(m_pluginAPI, deviceAPI);
AMDemodGUI::create(m_pluginAPI, deviceAPI);
}

View File

@ -33,32 +33,32 @@ const int ATVDemod::m_ssbFftLen = 1024;
ATVDemod::ATVDemod(BasebandSampleSink* objScopeSink) :
m_objScopeSink(objScopeSink),
m_objSettingsMutex(QMutex::Recursive),
m_objRegisteredATVScreen(NULL),
m_intNumberSamplePerTop(0),
m_intImageIndex(0),
m_intColIndex(0),
m_intSampleIndex(0),
m_intRowIndex(0),
m_intLineIndex(0),
m_intSynchroPoints(0),
m_blnSynchroDetected(false),
m_blnVerticalSynchroDetected(false),
m_fltAmpLineAverage(0.0f),
m_fltEffMin(2000000000.0f),
m_fltEffMax(-2000000000.0f),
m_fltAmpMin(-2000000000.0f),
m_fltAmpMax(2000000000.0f),
m_fltAmpDelta(1.0),
m_fltAmpLineAverage(0.0f),
m_intNumberSamplePerTop(0),
m_intColIndex(0),
m_intSampleIndex(0),
m_intRowIndex(0),
m_intLineIndex(0),
m_objAvgColIndex(3),
m_objMagSqAverage(40, 0),
m_bfoPLL(200/1000000, 100/1000000, 0.01),
m_bfoFilter(200.0, 1000000.0, 0.9),
m_interpolatorDistanceRemain(0.0f),
m_interpolatorDistance(1.0f),
m_interpolatorDistanceRemain(0.0f),
m_DSBFilter(0),
m_DSBFilterBuffer(0),
m_DSBFilterBufferIndex(0),
m_objAvgColIndex(3),
m_objMagSqAverage(40, 0)
m_objSettingsMutex(QMutex::Recursive)
{
setObjectName("ATVDemod");
@ -143,26 +143,14 @@ void ATVDemod::configureRF(
objMessageQueue->push(msgCmd);
}
void ATVDemod::feed(const SampleVector::const_iterator& begin, const SampleVector::const_iterator& end, bool firstOfBurst)
void ATVDemod::feed(const SampleVector::const_iterator& begin, const SampleVector::const_iterator& end, bool firstOfBurst __attribute__((unused)))
{
float fltDivSynchroBlack = 1.0f - m_objRunning.m_fltVoltLevelSynchroBlack;
float fltI;
float fltQ;
float fltNormI;
float fltNormQ;
Complex ci;
float fltNorm=0.00f;
float fltVal;
int intVal;
qint16 * ptrBufferToRelease = 0;
bool blnComputeImage=false;
int intSynchroTimeSamples= (3 * m_objRunningPrivate.m_intNumberSamplePerLine) / 4;
float fltSynchroTrameLevel = 0.5f*((float)intSynchroTimeSamples) * m_objRunning.m_fltVoltLevelSynchroBlack;
//********** Let's rock and roll buddy ! **********
m_objSettingsMutex.lock();

View File

@ -140,7 +140,6 @@ bool ATVDemodGUI::deserialize(const QByteArray& arrData)
if (d.getVersion() == 1)
{
QByteArray bytetmp;
uint32_t u32tmp;
int tmp;
bool booltmp;
@ -252,7 +251,7 @@ void ATVDemodGUI::handleSourceMessages()
}
}
void ATVDemodGUI::onWidgetRolled(QWidget* widget, bool rollDown)
void ATVDemodGUI::onWidgetRolled(QWidget* widget __attribute__((unused)), bool rollDown __attribute__((unused)))
{
}
@ -276,8 +275,8 @@ ATVDemodGUI::ATVDemodGUI(PluginAPI* objPluginAPI, DeviceSourceAPI *objDeviceAPI,
m_objChannelMarker(this),
m_blnBasicSettingsShown(false),
m_blnDoApplySettings(true),
m_intTickCount(0),
m_objMagSqAverage(40, 0)
m_objMagSqAverage(40, 0),
m_intTickCount(0)
{
ui->setupUi(this);
setAttribute(Qt::WA_DeleteOnClose, true);
@ -548,31 +547,31 @@ void ATVDemodGUI::on_halfImage_clicked()
applySettings();
}
void ATVDemodGUI::on_nbLines_currentIndexChanged(int index)
void ATVDemodGUI::on_nbLines_currentIndexChanged(int index __attribute__((unused)))
{
lineTimeUpdate();
topTimeUpdate();
applySettings();
}
void ATVDemodGUI::on_fps_currentIndexChanged(int index)
void ATVDemodGUI::on_fps_currentIndexChanged(int index __attribute__((unused)))
{
lineTimeUpdate();
topTimeUpdate();
applySettings();
}
void ATVDemodGUI::on_standard_currentIndexChanged(int index)
void ATVDemodGUI::on_standard_currentIndexChanged(int index __attribute__((unused)))
{
applySettings();
}
void ATVDemodGUI::on_reset_clicked(bool checked)
void ATVDemodGUI::on_reset_clicked(bool checked __attribute__((unused)))
{
resetToDefaults();
}
void ATVDemodGUI::on_modulation_currentIndexChanged(int index)
void ATVDemodGUI::on_modulation_currentIndexChanged(int index __attribute__((unused)))
{
setRFFiltersSlidersRange(m_objATVDemod->getEffectiveSampleRate());
setChannelMarkerBandwidth();
@ -593,14 +592,14 @@ void ATVDemodGUI::on_rfOppBW_valueChanged(int value)
applyRFSettings();
}
void ATVDemodGUI::on_rfFiltering_toggled(bool checked)
void ATVDemodGUI::on_rfFiltering_toggled(bool checked __attribute__((unused)))
{
setRFFiltersSlidersRange(m_objATVDemod->getEffectiveSampleRate());
setChannelMarkerBandwidth();
applyRFSettings();
}
void ATVDemodGUI::on_decimatorEnable_toggled(bool checked)
void ATVDemodGUI::on_decimatorEnable_toggled(bool checked __attribute__((unused)))
{
setChannelMarkerBandwidth();
applyRFSettings();
@ -623,7 +622,7 @@ void ATVDemodGUI::on_fmDeviation_valueChanged(int value)
applyRFSettings();
}
void ATVDemodGUI::on_screenTabWidget_currentChanged(int index)
void ATVDemodGUI::on_screenTabWidget_currentChanged(int index __attribute__((unused)))
{
applySettings();
}

View File

@ -161,7 +161,7 @@ void ATVScreen::paintGL()
m_objMutex.unlock();
}
void ATVScreen::mousePressEvent(QMouseEvent* event)
void ATVScreen::mousePressEvent(QMouseEvent* event __attribute__((unused)))
{
}

View File

@ -36,10 +36,10 @@ const Real BFMDemod::default_deemphasis = 50.0; // 50 us
BFMDemod::BFMDemod(BasebandSampleSink* sampleSink, RDSParser *rdsParser) :
m_sampleSink(sampleSink),
m_rdsParser(rdsParser),
m_audioFifo(4, 250000),
m_settingsMutex(QMutex::Recursive),
m_pilotPLL(19000/384000, 50/384000, 0.01),
m_rdsParser(rdsParser),
m_deemphasisFilterX(default_deemphasis * 48000 * 1.0e-6),
m_deemphasisFilterY(default_deemphasis * 48000 * 1.0e-6),
m_fmExcursion(default_excursion)
@ -103,7 +103,7 @@ void BFMDemod::configure(MessageQueue* messageQueue,
messageQueue->push(cmd);
}
void BFMDemod::feed(const SampleVector::const_iterator& begin, const SampleVector::const_iterator& end, bool firstOfBurst)
void BFMDemod::feed(const SampleVector::const_iterator& begin, const SampleVector::const_iterator& end, bool firstOfBurst __attribute__((unused)))
{
Complex ci, cs, cr;
fftfilt::cmplx *rf;
@ -182,7 +182,7 @@ void BFMDemod::feed(const SampleVector::const_iterator& begin, const SampleVecto
}
}
Real sampleStereo;
Real sampleStereo = 0.0f;
// Process stereo if stereo mode is selected

View File

@ -131,7 +131,6 @@ bool BFMDemodGUI::deserialize(const QByteArray& data)
if (d.getVersion() == 1)
{
QByteArray bytetmp;
quint32 u32tmp;
qint32 tmp;
bool booltmp;
@ -183,7 +182,7 @@ bool BFMDemodGUI::deserialize(const QByteArray& data)
}
}
bool BFMDemodGUI::handleMessage(const Message& message)
bool BFMDemodGUI::handleMessage(const Message& message __attribute__((unused)))
{
return false;
}
@ -233,7 +232,7 @@ void BFMDemodGUI::on_audioStereo_toggled(bool stereo)
applySettings();
}
void BFMDemodGUI::on_lsbStereo_toggled(bool lsb)
void BFMDemodGUI::on_lsbStereo_toggled(bool lsb __attribute__((unused)))
{
applySettings();
}
@ -248,7 +247,7 @@ void BFMDemodGUI::on_rds_clicked()
applySettings();
}
void BFMDemodGUI::on_clearData_clicked(bool checked)
void BFMDemodGUI::on_clearData_clicked(bool checked __attribute__((unused)))
{
if (ui->rds->isChecked())
{
@ -266,8 +265,10 @@ void BFMDemodGUI::on_clearData_clicked(bool checked)
}
}
void BFMDemodGUI::on_g14ProgServiceNames_currentIndexChanged(int index)
void BFMDemodGUI::on_g14ProgServiceNames_currentIndexChanged(int _index)
{
uint32_t index = _index & 0x7FFFFFF;
if (index < m_g14ComboIndex.size())
{
unsigned int piKey = m_g14ComboIndex[index];
@ -309,26 +310,26 @@ void BFMDemodGUI::on_g14ProgServiceNames_currentIndexChanged(int index)
}
}
void BFMDemodGUI::on_g00AltFrequenciesBox_activated(int index)
void BFMDemodGUI::on_g00AltFrequenciesBox_activated(int index __attribute__((unused)))
{
qint64 f = (qint64) ((ui->g00AltFrequenciesBox->currentText()).toDouble() * 1e6);
changeFrequency(f);
}
void BFMDemodGUI::on_g14MappedFrequencies_activated(int index)
void BFMDemodGUI::on_g14MappedFrequencies_activated(int index __attribute__((unused)))
{
qint64 f = (qint64) ((ui->g14MappedFrequencies->currentText()).toDouble() * 1e6);
changeFrequency(f);
}
void BFMDemodGUI::on_g14AltFrequencies_activated(int index)
void BFMDemodGUI::on_g14AltFrequencies_activated(int index __attribute__((unused)))
{
qint64 f = (qint64) ((ui->g14AltFrequencies->currentText()).toDouble() * 1e6);
changeFrequency(f);
}
void BFMDemodGUI::onWidgetRolled(QWidget* widget, bool rollDown)
void BFMDemodGUI::onWidgetRolled(QWidget* widget __attribute__((unused)), bool rollDown __attribute__((unused)))
{
}

View File

@ -63,5 +63,5 @@ PluginGUI* BFMPlugin::createRxChannel(const QString& channelName, DeviceSourceAP
void BFMPlugin::createInstanceBFM(DeviceSourceAPI *deviceAPI)
{
BFMDemodGUI* gui = BFMDemodGUI::create(m_pluginAPI, deviceAPI);
BFMDemodGUI::create(m_pluginAPI, deviceAPI);
}

View File

@ -53,7 +53,7 @@ RDSDemod::~RDSDemod()
//delete m_socket;
}
void RDSDemod::setSampleRate(int srate) /// FIXME: fix rate for now
void RDSDemod::setSampleRate(int srate __attribute__((unused))) /// FIXME: fix rate for now
{
}

View File

@ -383,7 +383,6 @@ void RDSParser::parseGroup(unsigned int *group)
m_pi_program_type = (group[1] >> 5) & 0x1f; // "PTY"
m_pi_country_identification = (m_pi_program_identification >> 12) & 0xf;
m_pi_area_coverage_index = (m_pi_program_identification >> 8) & 0xf;
unsigned char pi_program_reference_number = m_pi_program_identification & 0xff;
/*
std::string pistring = str(boost::format("%04X") % m_pi_program_identification);
@ -466,7 +465,6 @@ void RDSParser::decode_type0(unsigned int *group, bool B)
unsigned int no_af = 0;
double af_1 = 0;
double af_2 = 0;
char flagstring[8] = "0000000";
m_g0_count++;
m_g0_updated = true;
@ -587,7 +585,6 @@ void RDSParser::decode_type0(unsigned int *group, bool B)
double RDSParser::decode_af(unsigned int af_code)
{
static unsigned int number_of_freqs = 0;
static bool vhf_or_lfmf = 0; // 0 = vhf, 1 = lf/mf
double alt_frequency = 0; // in kHz
@ -597,20 +594,17 @@ double RDSParser::decode_af(unsigned int af_code)
( af_code == 224) || // No AF exists
( af_code >= 251)) // not assigned
{
number_of_freqs = 0;
alt_frequency = 0;
}
if ((af_code >= 225) && (af_code <= 249)) // VHF frequencies follow
{
number_of_freqs = af_code - 224;
alt_frequency = 0;
vhf_or_lfmf = 1;
}
if (af_code == 250) // an LF/MF frequency follows
{
number_of_freqs = 1;
alt_frequency = 0;
vhf_or_lfmf = 0;
}
@ -755,13 +749,13 @@ void RDSParser::decode_type3(unsigned int *group, bool B)
if (variant_code == 0)
{
int ltn = (message >> 6) & 0x3f; // location table number
bool afi = (message >> 5) & 0x1; // alternative freq. indicator
bool M = (message >> 4) & 0x1; // mode of transmission
bool I = (message >> 3) & 0x1; // international
bool N = (message >> 2) & 0x1; // national
bool R = (message >> 1) & 0x1; // regional
bool U = message & 0x1; // urban
// int ltn = (message >> 6) & 0x3f; // location table number
// bool afi = (message >> 5) & 0x1; // alternative freq. indicator
// bool M = (message >> 4) & 0x1; // mode of transmission
// bool I = (message >> 3) & 0x1; // international
// bool N = (message >> 2) & 0x1; // national
// bool R = (message >> 1) & 0x1; // regional
// bool U = message & 0x1; // urban
/*
qDebug() << "RDSParser::decode_type3: location table: " << ltn << " - "
@ -775,9 +769,9 @@ void RDSParser::decode_type3(unsigned int *group, bool B)
}
else if (variant_code==1)
{
int G = (message >> 12) & 0x3; // gap
int sid = (message >> 6) & 0x3f; // service identifier
int gap_no[4] = {3, 5, 8, 11};
// int G = (message >> 12) & 0x3; // gap
// int sid = (message >> 6) & 0x3f; // service identifier
// int gap_no[4] = {3, 5, 8, 11};
/*
qDebug() << "RDSParser::decode_type3: gap: " << gap_no[G] << " groups, SID: "
<< sid << " ";*/
@ -829,19 +823,19 @@ void RDSParser::decode_type4(unsigned int *group, bool B)
//send_message(5,time);
}
void RDSParser::decode_type5(unsigned int *group, bool B) {
void RDSParser::decode_type5(unsigned int *group __attribute__((unused)), bool B __attribute__((unused))) {
qDebug() << "RDSParser::decode_type5: type5 not implemented yet";
m_g5_updated = true;
m_g5_count++;
}
void RDSParser::decode_type6(unsigned int *group, bool B) {
void RDSParser::decode_type6(unsigned int *group __attribute__((unused)), bool B __attribute__((unused))) {
qDebug() << "RDSParser::decode_type6: type 6 not implemented yet";
m_g6_updated = true;
m_g6_count++;
}
void RDSParser::decode_type7(unsigned int *group, bool B) {
void RDSParser::decode_type7(unsigned int *group __attribute__((unused)), bool B __attribute__((unused))) {
qDebug() << "RDSParser::decode_type7: type 7 not implemented yet";
m_g7_updated = true;
m_g7_count++;
@ -969,25 +963,29 @@ void RDSParser::decode_type9(unsigned int *group, bool B){
m_g9_count++;
}
void RDSParser::decode_type10(unsigned int *group, bool B){
void RDSParser::decode_type10(unsigned int *group __attribute__((unused)), bool B __attribute__((unused)))
{
qDebug() << "RDSParser::decode_type10: type 10 not implemented yet";
m_g10_updated = true;
m_g10_count++;
}
void RDSParser::decode_type11(unsigned int *group, bool B){
void RDSParser::decode_type11(unsigned int *group __attribute__((unused)), bool B __attribute__((unused)))
{
qDebug() << "RDSParser::decode_type11: type 11 not implemented yet";
m_g11_updated = true;
m_g11_count++;
}
void RDSParser::decode_type12(unsigned int *group, bool B){
void RDSParser::decode_type12(unsigned int *group __attribute__((unused)), bool B __attribute__((unused)))
{
qDebug() << "RDSParser::decode_type12: type 12 not implemented yet";
m_g12_updated = true;
m_g12_count++;
}
void RDSParser::decode_type13(unsigned int *group, bool B){
void RDSParser::decode_type13(unsigned int *group __attribute__((unused)), bool B __attribute__((unused)))
{
qDebug() << "RDSParser::decode_type13: type 13 not implemented yet";
m_g13_updated = true;
m_g13_count++;
@ -995,14 +993,11 @@ void RDSParser::decode_type13(unsigned int *group, bool B){
void RDSParser::decode_type14(unsigned int *group, bool B)
{
bool tp_on = (group[1] >> 4) & 0x01;
char variant_code = group[1] & 0x0f;
unsigned int information = group[2];
unsigned int pi_on = group[3];
char pty_on = 0;
bool ta_on = 0;
static char ps_on[8] = {' ',' ',' ',' ',' ',' ',' ',' '};
double af_1 = 0;
double af_2 = 0;
@ -1144,7 +1139,6 @@ void RDSParser::decode_type14(unsigned int *group, bool B)
case 13: // PTY(ON), TA(ON)
{
ta_on = information & 0x01;
pty_on = (information >> 11) & 0x1f;
//qDebug() << "RDSParser::decode_type14: PTY(ON):" << pty_table[int(pty_on)].c_str();
if(ta_on) {
qDebug() << "RDSParser::decode_type14: - TA";
@ -1178,7 +1172,8 @@ void RDSParser::decode_type14(unsigned int *group, bool B)
}*/
}
void RDSParser::decode_type15(unsigned int *group, bool B){
void RDSParser::decode_type15(unsigned int *group __attribute__((unused)), bool B __attribute__((unused)))
{
qDebug() << "RDSParser::decode_type5: type 15 not implemented yet";
m_g15_updated = true;
m_g15_count++;

View File

@ -34,14 +34,14 @@ DSDDemod::DSDDemod(BasebandSampleSink* sampleSink) :
m_sampleCount(0),
m_squelchCount(0),
m_squelchOpen(false),
m_movingAverage(40, 0),
m_fmExcursion(24),
m_audioFifo1(4, 48000),
m_audioFifo2(4, 48000),
m_fmExcursion(24),
m_settingsMutex(QMutex::Recursive),
m_scope(sampleSink),
m_scopeEnabled(true),
m_dsdDecoder(),
m_movingAverage(40, 0)
m_scopeEnabled(true),
m_dsdDecoder(),
m_settingsMutex(QMutex::Recursive)
{
setObjectName("DSDDemod");
@ -122,7 +122,7 @@ void DSDDemod::configureMyPosition(MessageQueue* messageQueue, float myLatitude,
messageQueue->push(cmd);
}
void DSDDemod::feed(const SampleVector::const_iterator& begin, const SampleVector::const_iterator& end, bool firstOfBurst)
void DSDDemod::feed(const SampleVector::const_iterator& begin, const SampleVector::const_iterator& end, bool firstOfBurst __attribute__((unused)))
{
Complex ci;
int samplesPerSymbol = m_dsdDecoder.getSamplesPerSymbol();
@ -276,7 +276,7 @@ void DSDDemod::feed(const SampleVector::const_iterator& begin, const SampleVecto
if (nbAudioSamples > 0)
{
if (!m_running.m_audioMute) {
uint res = m_audioFifo1.write((const quint8*) dsdAudio, nbAudioSamples, 10);
m_audioFifo1.write((const quint8*) dsdAudio, nbAudioSamples, 10);
}
m_dsdDecoder.resetAudio1();
@ -291,7 +291,7 @@ void DSDDemod::feed(const SampleVector::const_iterator& begin, const SampleVecto
if (nbAudioSamples > 0)
{
if (!m_running.m_audioMute) {
uint res = m_audioFifo2.write((const quint8*) dsdAudio, nbAudioSamples, 10);
m_audioFifo2.write((const quint8*) dsdAudio, nbAudioSamples, 10);
}
m_dsdDecoder.resetAudio2();

View File

@ -128,7 +128,6 @@ bool DSDDemodGUI::deserialize(const QByteArray& data)
QByteArray bytetmp;
quint32 u32tmp;
qint32 tmp;
bool boolTmp;
blockApplySettings(true);
m_channelMarker.blockSignals(true);
@ -177,7 +176,7 @@ bool DSDDemodGUI::deserialize(const QByteArray& data)
}
}
bool DSDDemodGUI::handleMessage(const Message& message)
bool DSDDemodGUI::handleMessage(const Message& message __attribute__((unused)))
{
return false;
}
@ -199,22 +198,22 @@ void DSDDemodGUI::on_rfBW_valueChanged(int value)
applySettings();
}
void DSDDemodGUI::on_demodGain_valueChanged(int value)
void DSDDemodGUI::on_demodGain_valueChanged(int value __attribute__((unused)))
{
applySettings();
}
void DSDDemodGUI::on_fmDeviation_valueChanged(int value)
void DSDDemodGUI::on_fmDeviation_valueChanged(int value __attribute__((unused)))
{
applySettings();
}
void DSDDemodGUI::on_volume_valueChanged(int value)
void DSDDemodGUI::on_volume_valueChanged(int value __attribute__((unused)))
{
applySettings();
}
void DSDDemodGUI::on_baudRate_currentIndexChanged(int index)
void DSDDemodGUI::on_baudRate_currentIndexChanged(int index __attribute__((unused)))
{
applySettings();
}
@ -249,7 +248,7 @@ void DSDDemodGUI::on_tdmaStereoSplit_toggled(bool checked)
applySettings();
}
void DSDDemodGUI::on_squelchGate_valueChanged(int value)
void DSDDemodGUI::on_squelchGate_valueChanged(int value __attribute__((unused)))
{
applySettings();
}
@ -276,7 +275,7 @@ void DSDDemodGUI::on_symbolPLLLock_toggled(bool checked)
applySettings();
}
void DSDDemodGUI::onWidgetRolled(QWidget* widget, bool rollDown)
void DSDDemodGUI::onWidgetRolled(QWidget* widget __attribute__((unused)), bool rollDown __attribute__((unused)))
{
/*
if((widget == ui->spectrumContainer) && (DSDDemodGUI != NULL))

View File

@ -63,5 +63,5 @@ PluginGUI* DSDDemodPlugin::createRxChannel(const QString& channelName, DeviceSou
void DSDDemodPlugin::createInstanceDSDDemod(DeviceSourceAPI *deviceAPI)
{
DSDDemodGUI* gui = DSDDemodGUI::create(m_pluginAPI, deviceAPI);
DSDDemodGUI::create(m_pluginAPI, deviceAPI);
}

View File

@ -236,7 +236,7 @@ int LoRaDemod::detect(Complex c, Complex a)
return m_result;
}
void LoRaDemod::feed(const SampleVector::const_iterator& begin, const SampleVector::const_iterator& end, bool pO)
void LoRaDemod::feed(const SampleVector::const_iterator& begin, const SampleVector::const_iterator& end, bool pO __attribute__((unused)))
{
int newangle;
Complex ci;

View File

@ -111,7 +111,7 @@ bool LoRaDemodGUI::deserialize(const QByteArray& data)
}
}
bool LoRaDemodGUI::handleMessage(const Message& message)
bool LoRaDemodGUI::handleMessage(const Message& message __attribute__((unused)))
{
return false;
}
@ -130,11 +130,11 @@ void LoRaDemodGUI::on_BW_valueChanged(int value)
applySettings();
}
void LoRaDemodGUI::on_Spread_valueChanged(int value)
void LoRaDemodGUI::on_Spread_valueChanged(int value __attribute__((unused)))
{
}
void LoRaDemodGUI::onWidgetRolled(QWidget* widget, bool rollDown)
void LoRaDemodGUI::onWidgetRolled(QWidget* widget __attribute__((unused)), bool rollDown __attribute__((unused)))
{
/*
if((widget == ui->spectrumContainer) && (m_LoRaDemod != NULL))

View File

@ -46,5 +46,5 @@ PluginGUI* LoRaPlugin::createRxChannel(const QString& channelName, DeviceSourceA
void LoRaPlugin::createInstanceLoRa(DeviceSourceAPI *deviceAPI)
{
LoRaDemodGUI* gui = LoRaDemodGUI::create(m_pluginAPI, deviceAPI);
LoRaDemodGUI::create(m_pluginAPI, deviceAPI);
}

View File

@ -43,12 +43,12 @@ NFMDemod::NFMDemod() :
m_magsqSum(0.0f),
m_magsqPeak(0.0f),
m_magsqCount(0),
m_afSquelch(2, afSqTones),
m_audioFifo(4, 48000),
m_fmExcursion(2400),
m_settingsMutex(QMutex::Recursive),
m_AGC(40, 0),
m_movingAverage(40, 0)
m_movingAverage(40, 0),
m_afSquelch(2, afSqTones),
m_fmExcursion(2400),
m_audioFifo(4, 48000),
m_settingsMutex(QMutex::Recursive)
{
setObjectName("NFMDemod");
@ -138,7 +138,7 @@ Real angleDist(Real a, Real b)
return dist;
}
void NFMDemod::feed(const SampleVector::const_iterator& begin, const SampleVector::const_iterator& end, bool firstOfBurst)
void NFMDemod::feed(const SampleVector::const_iterator& begin, const SampleVector::const_iterator& end, bool firstOfBurst __attribute__((unused)))
{
Complex ci;

View File

@ -153,7 +153,7 @@ bool NFMDemodGUI::deserialize(const QByteArray& data)
}
}
bool NFMDemodGUI::handleMessage(const Message& message)
bool NFMDemodGUI::handleMessage(const Message& message __attribute__((unused)))
{
return false;
}
@ -188,13 +188,13 @@ void NFMDemodGUI::on_volume_valueChanged(int value)
applySettings();
}
void NFMDemodGUI::on_squelchGate_valueChanged(int value)
void NFMDemodGUI::on_squelchGate_valueChanged(int value __attribute__((unused)))
{
ui->squelchGateText->setText(QString("%1").arg(ui->squelchGate->value() * 10.0f, 0, 'f', 0));
applySettings();
}
void NFMDemodGUI::on_deltaSquelch_toggled(bool checked)
void NFMDemodGUI::on_deltaSquelch_toggled(bool checked __attribute__((unused)))
{
if (ui->deltaSquelch->isChecked())
{
@ -246,7 +246,7 @@ void NFMDemodGUI::on_ctcss_currentIndexChanged(int index)
}
}
void NFMDemodGUI::onWidgetRolled(QWidget* widget, bool rollDown)
void NFMDemodGUI::onWidgetRolled(QWidget* widget __attribute__((unused)), bool rollDown __attribute__((unused)))
{
/*
if((widget == ui->spectrumContainer) && (m_nfmDemod != NULL))

View File

@ -45,5 +45,5 @@ PluginGUI* NFMPlugin::createRxChannel(const QString& channelName, DeviceSourceAP
void NFMPlugin::createInstanceNFM(DeviceSourceAPI *deviceAPI)
{
NFMDemodGUI* gui = NFMDemodGUI::create(m_pluginAPI, deviceAPI);
NFMDemodGUI::create(m_pluginAPI, deviceAPI);
}

View File

@ -28,13 +28,13 @@
MESSAGE_CLASS_DEFINITION(SSBDemod::MsgConfigureSSBDemod, Message)
SSBDemod::SSBDemod(BasebandSampleSink* sampleSink) :
m_sampleSink(sampleSink),
m_audioFifo(4, 24000),
m_settingsMutex(QMutex::Recursive),
m_audioBinaual(false),
m_audioFlipChannels(false),
m_audioMute(false),
m_dsb(false)
m_dsb(false),
m_audioMute(false),
m_sampleSink(sampleSink),
m_audioFifo(4, 24000),
m_settingsMutex(QMutex::Recursive)
{
setObjectName("SSBDemod");
@ -89,11 +89,10 @@ void SSBDemod::configure(MessageQueue* messageQueue,
messageQueue->push(cmd);
}
void SSBDemod::feed(const SampleVector::const_iterator& begin, const SampleVector::const_iterator& end, bool positiveOnly)
void SSBDemod::feed(const SampleVector::const_iterator& begin, const SampleVector::const_iterator& end, bool positiveOnly __attribute__((unused)))
{
Complex ci;
fftfilt::cmplx *sideband;
Real avg;
int n_out;
m_settingsMutex.lock();

View File

@ -136,7 +136,7 @@ bool SSBDemodGUI::deserialize(const QByteArray& data)
}
}
bool SSBDemodGUI::handleMessage(const Message& message)
bool SSBDemodGUI::handleMessage(const Message& message __attribute__((unused)))
{
return false;
}
@ -283,7 +283,7 @@ void SSBDemodGUI::on_spanLog2_valueChanged(int value)
}
void SSBDemodGUI::onWidgetRolled(QWidget* widget, bool rollDown)
void SSBDemodGUI::onWidgetRolled(QWidget* widget __attribute__((unused)), bool rollDown __attribute__((unused)))
{
/*
if((widget == ui->spectrumContainer) && (m_ssbDemod != NULL))
@ -313,8 +313,8 @@ SSBDemodGUI::SSBDemodGUI(PluginAPI* pluginAPI, DeviceSourceAPI *deviceAPI, QWidg
m_spanLog2(3),
m_audioBinaural(false),
m_audioFlipChannels(false),
m_audioMute(false),
m_dsb(false),
m_audioMute(false),
m_channelPowerDbAvg(20,0)
{
ui->setupUi(this);

View File

@ -46,5 +46,5 @@ PluginGUI* SSBPlugin::createRxChannel(const QString& channelName, DeviceSourceAP
void SSBPlugin::createInstanceSSB(DeviceSourceAPI *deviceAPI)
{
SSBDemodGUI* gui = SSBDemodGUI::create(m_pluginAPI, deviceAPI);
SSBDemodGUI::create(m_pluginAPI, deviceAPI);
}

View File

@ -29,15 +29,15 @@
MESSAGE_CLASS_DEFINITION(WFMDemod::MsgConfigureWFMDemod, Message)
WFMDemod::WFMDemod(BasebandSampleSink* sampleSink) :
m_sampleSink(sampleSink),
m_audioFifo(4, 250000),
m_settingsMutex(QMutex::Recursive),
m_squelchOpen(false),
m_magsq(0.0f),
m_magsqSum(0.0f),
m_magsqPeak(0.0f),
m_magsqCount(0),
m_movingAverage(40, 0)
m_movingAverage(40, 0),
m_sampleSink(sampleSink),
m_audioFifo(4, 250000),
m_settingsMutex(QMutex::Recursive)
{
setObjectName("WFMDemod");
@ -84,7 +84,7 @@ void WFMDemod::configure(
messageQueue->push(cmd);
}
void WFMDemod::feed(const SampleVector::const_iterator& begin, const SampleVector::const_iterator& end, bool firstOfBurst)
void WFMDemod::feed(const SampleVector::const_iterator& begin, const SampleVector::const_iterator& end, bool firstOfBurst __attribute__((unused)))
{
Complex ci;
fftfilt::cmplx *rf;

View File

@ -135,7 +135,7 @@ bool WFMDemodGUI::deserialize(const QByteArray& data)
}
}
bool WFMDemodGUI::handleMessage(const Message& message)
bool WFMDemodGUI::handleMessage(const Message& message __attribute__((unused)))
{
return false;
}
@ -180,7 +180,7 @@ void WFMDemodGUI::on_audioMute_toggled(bool checked)
applySettings();
}
void WFMDemodGUI::onWidgetRolled(QWidget* widget, bool rollDown)
void WFMDemodGUI::onWidgetRolled(QWidget* widget __attribute__((unused)), bool rollDown __attribute__((unused)))
{
}

View File

@ -46,5 +46,5 @@ PluginGUI* WFMPlugin::createRxChannel(const QString& channelName, DeviceSourceAP
void WFMPlugin::createInstanceWFM(DeviceSourceAPI *deviceAPI)
{
WFMDemodGUI* gui = WFMDemodGUI::create(m_pluginAPI, deviceAPI);
WFMDemodGUI::create(m_pluginAPI, deviceAPI);
}

View File

@ -391,7 +391,7 @@ void TCPSrc::processDeconnection()
}
}
void TCPSrc::onTcpServerError(QAbstractSocket::SocketError socketError)
void TCPSrc::onTcpServerError(QAbstractSocket::SocketError socketError __attribute__((unused)))
{
qDebug("TCPSrc::onTcpServerError: %s", qPrintable(m_tcpServer->errorString()));
}

View File

@ -337,22 +337,22 @@ void TCPSrcGUI::on_deltaFrequency_changed(qint64 value)
m_channelMarker.setCenterFrequency(value);
}
void TCPSrcGUI::on_sampleFormat_currentIndexChanged(int index)
void TCPSrcGUI::on_sampleFormat_currentIndexChanged(int index __attribute__((unused)))
{
ui->applyBtn->setEnabled(true);
}
void TCPSrcGUI::on_sampleRate_textEdited(const QString& arg1)
void TCPSrcGUI::on_sampleRate_textEdited(const QString& arg1 __attribute__((unused)))
{
ui->applyBtn->setEnabled(true);
}
void TCPSrcGUI::on_rfBandwidth_textEdited(const QString& arg1)
void TCPSrcGUI::on_rfBandwidth_textEdited(const QString& arg1 __attribute__((unused)))
{
ui->applyBtn->setEnabled(true);
}
void TCPSrcGUI::on_tcpPort_textEdited(const QString& arg1)
void TCPSrcGUI::on_tcpPort_textEdited(const QString& arg1 __attribute__((unused)))
{
ui->applyBtn->setEnabled(true);
}

View File

@ -48,7 +48,7 @@ PluginGUI* TCPSrcPlugin::createRxChannel(const QString& channelName, DeviceSourc
void TCPSrcPlugin::createInstanceTCPSrc(DeviceSourceAPI *deviceAPI)
{
TCPSrcGUI* gui = TCPSrcGUI::create(m_pluginAPI, deviceAPI);
TCPSrcGUI::create(m_pluginAPI, deviceAPI);
// deviceAPI->registerChannelInstance("sdrangel.channel.tcpsrc", gui);
// m_pluginAPI->addChannelRollup(gui);
}

View File

@ -29,13 +29,13 @@ MESSAGE_CLASS_DEFINITION(UDPSrc::MsgUDPSrcConfigureImmediate, Message)
MESSAGE_CLASS_DEFINITION(UDPSrc::MsgUDPSrcSpectrum, Message)
UDPSrc::UDPSrc(MessageQueue* uiMessageQueue, UDPSrcGUI* udpSrcGUI, BasebandSampleSink* spectrum) :
m_settingsMutex(QMutex::Recursive),
m_udpPort(9999),
m_audioFifo(4, 24000),
m_audioActive(false),
m_audioStereo(false),
m_volume(20),
m_fmDeviation(2500)
m_fmDeviation(2500),
m_audioFifo(4, 24000),
m_settingsMutex(QMutex::Recursive)
{
setObjectName("UDPSrc");

View File

@ -177,10 +177,10 @@ protected:
int boost,
int volume) :
Message(),
m_boost(boost),
m_volume(volume),
m_audioActive(audioActive),
m_audioStereo(audioStereo),
m_boost(boost),
m_volume(volume)
m_audioStereo(audioStereo)
{ }
};

View File

@ -202,7 +202,7 @@ bool UDPSrcGUI::deserialize(const QByteArray& data)
}
}
bool UDPSrcGUI::handleMessage(const Message& message)
bool UDPSrcGUI::handleMessage(const Message& message __attribute__((unused)))
{
qDebug() << "UDPSrcGUI::handleMessage";
return false;
@ -228,10 +228,10 @@ UDPSrcGUI::UDPSrcGUI(PluginAPI* pluginAPI, DeviceSourceAPI *deviceAPI, QWidget*
m_udpSrc(0),
m_channelMarker(this),
m_channelPowerDbAvg(40,0),
m_basicSettingsShown(false),
m_doApplySettings(true),
m_boost(1),
m_volume(20)
m_volume(20),
m_basicSettingsShown(false),
m_doApplySettings(true)
{
ui->setupUi(this);
connect(this, SIGNAL(widgetRolled(QWidget*,bool)), this, SLOT(onWidgetRolled(QWidget*,bool)));
@ -454,32 +454,32 @@ void UDPSrcGUI::on_sampleFormat_currentIndexChanged(int index)
ui->applyBtn->setEnabled(true);
}
void UDPSrcGUI::on_sampleRate_textEdited(const QString& arg1)
void UDPSrcGUI::on_sampleRate_textEdited(const QString& arg1 __attribute__((unused)))
{
ui->applyBtn->setEnabled(true);
}
void UDPSrcGUI::on_rfBandwidth_textEdited(const QString& arg1)
void UDPSrcGUI::on_rfBandwidth_textEdited(const QString& arg1 __attribute__((unused)))
{
ui->applyBtn->setEnabled(true);
}
void UDPSrcGUI::on_fmDeviation_textEdited(const QString& arg1)
void UDPSrcGUI::on_fmDeviation_textEdited(const QString& arg1 __attribute__((unused)))
{
ui->applyBtn->setEnabled(true);
}
void UDPSrcGUI::on_udpAddress_textEdited(const QString& arg1)
void UDPSrcGUI::on_udpAddress_textEdited(const QString& arg1 __attribute__((unused)))
{
ui->applyBtn->setEnabled(true);
}
void UDPSrcGUI::on_udpPort_textEdited(const QString& arg1)
void UDPSrcGUI::on_udpPort_textEdited(const QString& arg1 __attribute__((unused)))
{
ui->applyBtn->setEnabled(true);
}
void UDPSrcGUI::on_audioPort_textEdited(const QString& arg1)
void UDPSrcGUI::on_audioPort_textEdited(const QString& arg1 __attribute__((unused)))
{
ui->applyBtn->setEnabled(true);
}
@ -489,12 +489,12 @@ void UDPSrcGUI::on_applyBtn_clicked()
applySettings();
}
void UDPSrcGUI::on_audioActive_toggled(bool active)
void UDPSrcGUI::on_audioActive_toggled(bool active __attribute__((unused)))
{
applySettingsImmediate();
}
void UDPSrcGUI::on_audioStereo_toggled(bool stereo)
void UDPSrcGUI::on_audioStereo_toggled(bool stereo __attribute__((unused)))
{
applySettingsImmediate();
}

View File

@ -65,7 +65,7 @@ PluginGUI* UDPSrcPlugin::createRxChannel(const QString& channelName, DeviceSourc
void UDPSrcPlugin::createInstanceUDPSrc(DeviceSourceAPI *deviceAPI)
{
UDPSrcGUI* gui = UDPSrcGUI::create(m_pluginAPI, deviceAPI);
UDPSrcGUI::create(m_pluginAPI, deviceAPI);
// deviceAPI->registerChannelInstance("sdrangel.channel.udpsrc", gui);
// m_pluginAPI->addChannelRollup(gui);
}

View File

@ -36,6 +36,8 @@ MESSAGE_CLASS_DEFINITION(AMMod::MsgReportFileSourceStreamTiming, Message)
const int AMMod::m_levelNbSamples = 480; // every 10ms
AMMod::AMMod() :
m_movingAverage(40, 0),
m_volumeAGC(40, 0),
m_audioFifo(4, 48000),
m_settingsMutex(QMutex::Recursive),
m_fileSize(0),
@ -44,9 +46,7 @@ AMMod::AMMod() :
m_afInput(AMModInputNone),
m_levelCalcCount(0),
m_peakLevel(0.0f),
m_levelSum(0.0f),
m_movingAverage(40, 0),
m_volumeAGC(40, 0)
m_levelSum(0.0f)
{
setObjectName("AMMod");
@ -141,7 +141,7 @@ void AMMod::pull(Sample& sample)
void AMMod::pullAudio(int nbSamples)
{
// qDebug("AMMod::pullAudio: %d", nbSamples);
int nbAudioSamples = nbSamples * m_interpolatorDistance;
unsigned int nbAudioSamples = nbSamples * m_interpolatorDistance;
if (nbAudioSamples > m_audioBuffer.size())
{

View File

@ -218,12 +218,12 @@ void AMModGUI::on_toneFrequency_valueChanged(int value)
}
void AMModGUI::on_channelMute_toggled(bool checked)
void AMModGUI::on_channelMute_toggled(bool checked __attribute__((unused)))
{
applySettings();
}
void AMModGUI::on_playLoop_toggled(bool checked)
void AMModGUI::on_playLoop_toggled(bool checked __attribute__((unused)))
{
applySettings();
}
@ -283,7 +283,7 @@ void AMModGUI::on_navTimeSlider_valueChanged(int value)
}
}
void AMModGUI::on_showFileDialog_clicked(bool checked)
void AMModGUI::on_showFileDialog_clicked(bool checked __attribute__((unused)))
{
QString fileName = QFileDialog::getOpenFileName(this,
tr("Open raw audio file"), ".", tr("Raw audio Files (*.raw)"));
@ -304,7 +304,7 @@ void AMModGUI::configureFileName()
m_amMod->getInputMessageQueue()->push(message);
}
void AMModGUI::onWidgetRolled(QWidget* widget, bool rollDown)
void AMModGUI::onWidgetRolled(QWidget* widget __attribute__((unused)), bool rollDown __attribute__((unused)))
{
}

View File

@ -62,5 +62,5 @@ PluginGUI* AMModPlugin::createTxChannel(const QString& channelName, DeviceSinkAP
void AMModPlugin::createInstanceModAM(DeviceSinkAPI *deviceAPI)
{
AMModGUI* gui = AMModGUI::create(m_pluginAPI, deviceAPI);
AMModGUI::create(m_pluginAPI, deviceAPI);
}

View File

@ -45,11 +45,12 @@ const int ATVMod::m_ssbFftLen = 1024;
ATVMod::ATVMod() :
m_modPhasor(0.0f),
m_evenImage(true),
m_tvSampleRate(1000000),
m_evenImage(true),
m_settingsMutex(QMutex::Recursive),
m_horizontalCount(0),
m_lineCount(0),
m_movingAverage(40, 0),
m_imageOK(false),
m_videoFPSq(1.0f),
m_videoFPSCount(0.0f),
@ -59,12 +60,11 @@ ATVMod::ATVMod() :
m_cameraIndex(-1),
m_showOverlayText(false),
m_SSBFilter(0),
m_DSBFilter(0),
m_SSBFilterBuffer(0),
m_DSBFilterBuffer(0),
m_SSBFilterBufferIndex(0),
m_DSBFilterBufferIndex(0),
m_movingAverage(40, 0)
m_DSBFilter(0),
m_DSBFilterBuffer(0),
m_DSBFilterBufferIndex(0)
{
setObjectName("ATVMod");
scanCameras();
@ -137,7 +137,7 @@ void ATVMod::configure(MessageQueue* messageQueue,
messageQueue->push(cmd);
}
void ATVMod::pullAudio(int nbSamples)
void ATVMod::pullAudio(int nbSamples __attribute__((unused)))
{
}
@ -329,7 +329,7 @@ void ATVMod::pullVideo(Real& sample)
if ((m_running.m_atvModInput == ATVModInputVideo) && m_videoOK && (m_running.m_videoPlay) && !m_videoEOF)
{
int grabOK;
int grabOK = 0;
int fpsIncrement = (int) m_videoFPSCount - m_videoPrevFPSCount;
// move a number of frames according to increment
@ -610,7 +610,7 @@ bool ATVMod::handleMessage(const Message& cmd)
else if (MsgConfigureCameraIndex::match(cmd))
{
MsgConfigureCameraIndex& cfg = (MsgConfigureCameraIndex&) cmd;
int index = cfg.getIndex();
uint32_t index = cfg.getIndex() & 0x7FFFFFF;
if (index < m_cameras.size())
{
@ -632,7 +632,7 @@ bool ATVMod::handleMessage(const Message& cmd)
else if (MsgConfigureCameraData::match(cmd))
{
MsgConfigureCameraData& cfg = (MsgConfigureCameraData&) cmd;
int index = cfg.getIndex();
uint32_t index = cfg.getIndex() & 0x7FFFFFF;
float mnaualFPS = cfg.getManualFPS();
bool manualFPSEnable = cfg.getManualFPSEnable();
@ -1134,7 +1134,7 @@ void ATVMod::mixImageAndText(cv::Mat& image)
int thickness = image.cols / 160;
int baseline=0;
fontScale < 8.0f ? 8.0f : fontScale; // minimum size
fontScale = fontScale < 8.0f ? 8.0f : fontScale; // minimum size
cv::Size textSize = cv::getTextSize(m_overlayText, fontFace, fontScale, thickness, &baseline);
baseline += thickness;

View File

@ -621,27 +621,27 @@ private:
Real m_interpolatorDistanceRemain;
int m_tvSampleRate; //!< sample rate for generating signal
uint32_t m_pointsPerLine; //!< Number of points per full line
uint32_t m_pointsPerSync; //!< number of line points for the horizontal sync
uint32_t m_pointsPerBP; //!< number of line points for the back porch
uint32_t m_pointsPerImgLine; //!< number of line points for the image line
int m_pointsPerSync; //!< number of line points for the horizontal sync
int m_pointsPerBP; //!< number of line points for the back porch
int m_pointsPerImgLine; //!< number of line points for the image line
uint32_t m_pointsPerFP; //!< number of line points for the front porch
uint32_t m_pointsPerFSync; //!< number of line points for the field first sync
int m_pointsPerFSync; //!< number of line points for the field first sync
uint32_t m_pointsPerHBar; //!< number of line points for a bar of the bar chart
uint32_t m_linesPerVBar; //!< number of lines for a bar of the bar chart
uint32_t m_pointsPerTU; //!< number of line points per time unit
uint32_t m_nbLines; //!< number of lines per complete frame
uint32_t m_nbLines2; //!< same number as above (non interlaced) or half the number above (interlaced)
int m_nbLines; //!< number of lines per complete frame
int m_nbLines2; //!< same number as above (non interlaced) or half the number above (interlaced)
uint32_t m_nbImageLines; //!< number of image lines excluding synchronization lines
uint32_t m_nbImageLines2; //!< same number as above (non interlaced) or half the number above (interlaced)
uint32_t m_nbHorizPoints; //!< number of line points per horizontal line
uint32_t m_nbSyncLinesHeadE; //!< number of header sync lines on even frame
uint32_t m_nbSyncLinesHeadO; //!< number of header sync lines on odd frame
uint32_t m_nbSyncLinesBottom;//!< number of sync lines at bottom
uint32_t m_nbLongSyncLines; //!< number of whole long sync lines for vertical synchronization
uint32_t m_nbHalfLongSync; //!< number of half long sync / equalization lines
uint32_t m_nbWholeEqLines; //!< number of whole equalizing lines
int m_nbHorizPoints; //!< number of line points per horizontal line
int m_nbSyncLinesHeadE; //!< number of header sync lines on even frame
int m_nbSyncLinesHeadO; //!< number of header sync lines on odd frame
int m_nbSyncLinesBottom;//!< number of sync lines at bottom
int m_nbLongSyncLines; //!< number of whole long sync lines for vertical synchronization
int m_nbHalfLongSync; //!< number of half long sync / equalization lines
int m_nbWholeEqLines; //!< number of whole equalizing lines
bool m_singleLongSync; //!< single or double long sync per long sync line
uint32_t m_nbBlankLines; //!< number of lines in a frame (full or half) that are blanked (black) at the top of the image
int m_nbBlankLines; //!< number of lines in a frame (full or half) that are blanked (black) at the top of the image
float m_blankLineLvel; //!< video level of blank lines
float m_hBarIncrement; //!< video level increment at each horizontal bar increment
float m_vBarIncrement; //!< video level increment at each vertical bar increment

View File

@ -377,7 +377,7 @@ void ATVModGUI::on_deltaFrequency_changed(qint64 value)
m_channelMarker.setCenterFrequency(value);
}
void ATVModGUI::on_modulation_currentIndexChanged(int index)
void ATVModGUI::on_modulation_currentIndexChanged(int index __attribute__((unused)))
{
setRFFiltersSlidersRange(m_atvMod->getEffectiveSampleRate());
setChannelMarkerBandwidth();
@ -441,18 +441,18 @@ void ATVModGUI::setChannelMarkerBandwidth()
}
}
void ATVModGUI::on_nbLines_currentIndexChanged(int index)
void ATVModGUI::on_nbLines_currentIndexChanged(int index __attribute__((unused)))
{
applySettings();
}
void ATVModGUI::on_fps_currentIndexChanged(int index)
void ATVModGUI::on_fps_currentIndexChanged(int index __attribute__((unused)))
{
applySettings();
}
void ATVModGUI::on_standard_currentIndexChanged(int index)
void ATVModGUI::on_standard_currentIndexChanged(int index __attribute__((unused)))
{
applySettings();
}
@ -468,22 +468,22 @@ void ATVModGUI::on_invertVideo_clicked()
applySettings();
}
void ATVModGUI::on_inputSelect_currentIndexChanged(int index)
void ATVModGUI::on_inputSelect_currentIndexChanged(int index __attribute__((unused)))
{
applySettings();
}
void ATVModGUI::on_channelMute_toggled(bool checked)
void ATVModGUI::on_channelMute_toggled(bool checked __attribute__((unused)))
{
applySettings();
}
void ATVModGUI::on_forceDecimator_toggled(bool checked)
void ATVModGUI::on_forceDecimator_toggled(bool checked __attribute__((unused)))
{
applySettings();
}
void ATVModGUI::on_imageFileDialog_clicked(bool checked)
void ATVModGUI::on_imageFileDialog_clicked(bool checked __attribute__((unused)))
{
QString fileName = QFileDialog::getOpenFileName(this,
tr("Open image file"), ".", tr("Image Files (*.png *.jpg *.bmp *.gif *.tiff)"));
@ -496,7 +496,7 @@ void ATVModGUI::on_imageFileDialog_clicked(bool checked)
}
}
void ATVModGUI::on_videoFileDialog_clicked(bool checked)
void ATVModGUI::on_videoFileDialog_clicked(bool checked __attribute__((unused)))
{
QString fileName = QFileDialog::getOpenFileName(this,
tr("Open video file"), ".", tr("Video Files (*.avi *.mpg *.mp4 *.mov *.m4v *.mkv *.vob *.wmv)"));
@ -509,7 +509,7 @@ void ATVModGUI::on_videoFileDialog_clicked(bool checked)
}
}
void ATVModGUI::on_playLoop_toggled(bool checked)
void ATVModGUI::on_playLoop_toggled(bool checked __attribute__((unused)))
{
applySettings();
}
@ -525,13 +525,12 @@ void ATVModGUI::on_navTimeSlider_valueChanged(int value)
{
if (m_enableNavTime && ((value >= 0) && (value <= 100)))
{
int seekFame = (m_videoLength * value) / 100;
ATVMod::MsgConfigureVideoFileSourceSeek* message = ATVMod::MsgConfigureVideoFileSourceSeek::create(value);
m_atvMod->getInputMessageQueue()->push(message);
}
}
void ATVModGUI::on_playCamera_toggled(bool checked)
void ATVModGUI::on_playCamera_toggled(bool checked __attribute__((unused)))
{
applySettings();
}
@ -567,7 +566,7 @@ void ATVModGUI::on_overlayTextShow_toggled(bool checked)
m_atvMod->getInputMessageQueue()->push(message);
}
void ATVModGUI::on_overlayText_textEdited(const QString& arg1)
void ATVModGUI::on_overlayText_textEdited(const QString& arg1 __attribute__((unused)))
{
ATVMod::MsgConfigureOverlayText* message = ATVMod::MsgConfigureOverlayText::create(ui->overlayText->text());
m_atvMod->getInputMessageQueue()->push(message);
@ -587,7 +586,7 @@ void ATVModGUI::configureVideoFileName()
m_atvMod->getInputMessageQueue()->push(message);
}
void ATVModGUI::onWidgetRolled(QWidget* widget, bool rollDown)
void ATVModGUI::onWidgetRolled(QWidget* widget __attribute__((unused)), bool rollDown __attribute__((unused)))
{
}

View File

@ -62,7 +62,7 @@ PluginGUI* ATVModPlugin::createTxChannel(const QString& channelName, DeviceSinkA
void ATVModPlugin::createInstanceModATV(DeviceSinkAPI *deviceAPI)
{
ATVModGUI* gui = ATVModGUI::create(m_pluginAPI, deviceAPI);
ATVModGUI::create(m_pluginAPI, deviceAPI);
}

View File

@ -37,6 +37,8 @@ const int NFMMod::m_levelNbSamples = 480; // every 10ms
NFMMod::NFMMod() :
m_modPhasor(0.0f),
m_movingAverage(40, 0),
m_volumeAGC(40, 0),
m_audioFifo(4, 48000),
m_settingsMutex(QMutex::Recursive),
m_fileSize(0),
@ -45,9 +47,7 @@ NFMMod::NFMMod() :
m_afInput(NFMModInputNone),
m_levelCalcCount(0),
m_peakLevel(0.0f),
m_levelSum(0.0f),
m_movingAverage(40, 0),
m_volumeAGC(40, 0)
m_levelSum(0.0f)
{
setObjectName("NFMod");
@ -117,7 +117,6 @@ void NFMMod::pull(Sample& sample)
}
Complex ci;
Real t;
m_settingsMutex.lock();
@ -155,7 +154,7 @@ void NFMMod::pull(Sample& sample)
void NFMMod::pullAudio(int nbSamples)
{
int nbSamplesAudio = nbSamples * m_interpolatorDistance;
unsigned int nbSamplesAudio = nbSamples * m_interpolatorDistance;
if (nbSamplesAudio > m_audioBuffer.size())
{

View File

@ -246,12 +246,12 @@ void NFMModGUI::on_toneFrequency_valueChanged(int value)
applySettings();
}
void NFMModGUI::on_channelMute_toggled(bool checked)
void NFMModGUI::on_channelMute_toggled(bool checked __attribute__((unused)))
{
applySettings();
}
void NFMModGUI::on_playLoop_toggled(bool checked)
void NFMModGUI::on_playLoop_toggled(bool checked __attribute__((unused)))
{
applySettings();
}
@ -311,7 +311,7 @@ void NFMModGUI::on_navTimeSlider_valueChanged(int value)
}
}
void NFMModGUI::on_showFileDialog_clicked(bool checked)
void NFMModGUI::on_showFileDialog_clicked(bool checked __attribute__((unused)))
{
QString fileName = QFileDialog::getOpenFileName(this,
tr("Open raw audio file"), ".", tr("Raw audio Files (*.raw)"));
@ -325,12 +325,12 @@ void NFMModGUI::on_showFileDialog_clicked(bool checked)
}
}
void NFMModGUI::on_ctcss_currentIndexChanged(int index)
void NFMModGUI::on_ctcss_currentIndexChanged(int index __attribute__((unused)))
{
applySettings();
}
void NFMModGUI::on_ctcssOn_toggled(bool checked)
void NFMModGUI::on_ctcssOn_toggled(bool checked __attribute__((unused)))
{
applySettings();
}
@ -343,7 +343,7 @@ void NFMModGUI::configureFileName()
m_nfmMod->getInputMessageQueue()->push(message);
}
void NFMModGUI::onWidgetRolled(QWidget* widget, bool rollDown)
void NFMModGUI::onWidgetRolled(QWidget* widget __attribute__((unused)), bool rollDown __attribute__((unused)))
{
}

View File

@ -62,5 +62,5 @@ PluginGUI* NFMModPlugin::createTxChannel(const QString& channelName, DeviceSinkA
void NFMModPlugin::createInstanceModNFM(DeviceSinkAPI *deviceAPI)
{
NFMModGUI* gui = NFMModGUI::create(m_pluginAPI, deviceAPI);
NFMModGUI::create(m_pluginAPI, deviceAPI);
}

View File

@ -37,13 +37,15 @@ const int SSBMod::m_levelNbSamples = 480; // every 10ms
const int SSBMod::m_ssbFftLen = 1024;
SSBMod::SSBMod(BasebandSampleSink* sampleSink) :
m_sampleSink(sampleSink),
m_SSBFilter(0),
m_DSBFilter(0),
m_SSBFilterBuffer(0),
m_DSBFilterBuffer(0),
m_SSBFilterBufferIndex(0),
m_DSBFilterBufferIndex(0),
m_sampleSink(sampleSink),
m_movingAverage(40, 0),
m_volumeAGC(40, 0),
m_audioFifo(4, 48000),
m_settingsMutex(QMutex::Recursive),
m_fileSize(0),
@ -52,9 +54,7 @@ SSBMod::SSBMod(BasebandSampleSink* sampleSink) :
m_afInput(SSBModInputNone),
m_levelCalcCount(0),
m_peakLevel(0.0f),
m_levelSum(0.0f),
m_movingAverage(40, 0),
m_volumeAGC(40, 0)
m_levelSum(0.0f)
{
setObjectName("SSBMod");
@ -186,7 +186,7 @@ void SSBMod::pull(Sample& sample)
void SSBMod::pullAudio(int nbSamples)
{
int nbSamplesAudio = nbSamples * m_interpolatorDistance;
unsigned int nbSamplesAudio = nbSamples * m_interpolatorDistance;
if (nbSamplesAudio > m_audioBuffer.size())
{

View File

@ -249,12 +249,12 @@ void SSBModGUI::on_dsb_toggled(bool checked)
setNewRate(m_spanLog2);
}
void SSBModGUI::on_audioBinaural_toggled(bool checked)
void SSBModGUI::on_audioBinaural_toggled(bool checked __attribute__((unused)))
{
applySettings();
}
void SSBModGUI::on_audioFlipChannels_toggled(bool checked)
void SSBModGUI::on_audioFlipChannels_toggled(bool checked __attribute__((unused)))
{
applySettings();
}
@ -337,7 +337,7 @@ void SSBModGUI::on_audioMute_toggled(bool checked)
applySettings();
}
void SSBModGUI::on_playLoop_toggled(bool checked)
void SSBModGUI::on_playLoop_toggled(bool checked __attribute__((unused)))
{
applySettings();
}
@ -397,7 +397,7 @@ void SSBModGUI::on_navTimeSlider_valueChanged(int value)
}
}
void SSBModGUI::on_showFileDialog_clicked(bool checked)
void SSBModGUI::on_showFileDialog_clicked(bool checked __attribute__((unused)))
{
QString fileName = QFileDialog::getOpenFileName(this,
tr("Open raw audio file"), ".", tr("Raw audio Files (*.raw)"));
@ -418,7 +418,7 @@ void SSBModGUI::configureFileName()
m_ssbMod->getInputMessageQueue()->push(message);
}
void SSBModGUI::onWidgetRolled(QWidget* widget, bool rollDown)
void SSBModGUI::onWidgetRolled(QWidget* widget __attribute__((unused)), bool rollDown __attribute__((unused)))
{
}

View File

@ -62,5 +62,5 @@ PluginGUI* SSBModPlugin::createTxChannel(const QString& channelName, DeviceSinkA
void SSBModPlugin::createInstanceModSSB(DeviceSinkAPI *deviceAPI)
{
SSBModGUI* gui = SSBModGUI::create(m_pluginAPI, deviceAPI);
SSBModGUI::create(m_pluginAPI, deviceAPI);
}

View File

@ -38,17 +38,17 @@ const int WFMMod::m_rfFilterFFTLength = 1024;
WFMMod::WFMMod() :
m_modPhasor(0.0f),
m_movingAverage(40, 0),
m_volumeAGC(40, 0),
m_audioFifo(4, 48000),
m_settingsMutex(QMutex::Recursive),
m_fileSize(0),
m_fileSize(0),
m_recordLength(0),
m_sampleRate(48000),
m_afInput(WFMModInputNone),
m_levelCalcCount(0),
m_peakLevel(0.0f),
m_levelSum(0.0f),
m_movingAverage(40, 0),
m_volumeAGC(40, 0)
m_levelSum(0.0f)
{
setObjectName("WFMod");
@ -117,7 +117,6 @@ void WFMMod::pull(Sample& sample)
}
Complex ci, ri;
Real t;
fftfilt::cmplx *rf;
int rf_out;
@ -169,7 +168,7 @@ void WFMMod::pull(Sample& sample)
void WFMMod::pullAudio(int nbSamples)
{
int nbSamplesAudio = nbSamples * m_interpolatorDistance;
unsigned int nbSamplesAudio = nbSamples * m_interpolatorDistance;
if (nbSamplesAudio > m_audioBuffer.size())
{

View File

@ -227,12 +227,12 @@ void WFMModGUI::on_toneFrequency_valueChanged(int value)
applySettings();
}
void WFMModGUI::on_channelMute_toggled(bool checked)
void WFMModGUI::on_channelMute_toggled(bool checked __attribute__((unused)))
{
applySettings();
}
void WFMModGUI::on_playLoop_toggled(bool checked)
void WFMModGUI::on_playLoop_toggled(bool checked __attribute__((unused)))
{
applySettings();
}
@ -292,7 +292,7 @@ void WFMModGUI::on_navTimeSlider_valueChanged(int value)
}
}
void WFMModGUI::on_showFileDialog_clicked(bool checked)
void WFMModGUI::on_showFileDialog_clicked(bool checked __attribute__((unused)))
{
QString fileName = QFileDialog::getOpenFileName(this,
tr("Open raw audio file"), ".", tr("Raw audio Files (*.raw)"));
@ -313,7 +313,7 @@ void WFMModGUI::configureFileName()
m_wfmMod->getInputMessageQueue()->push(message);
}
void WFMModGUI::onWidgetRolled(QWidget* widget, bool rollDown)
void WFMModGUI::onWidgetRolled(QWidget* widget __attribute__((unused)), bool rollDown __attribute__((unused)))
{
}

View File

@ -62,5 +62,5 @@ PluginGUI* WFMModPlugin::createTxChannel(const QString& channelName, DeviceSinkA
void WFMModPlugin::createInstanceModWFM(DeviceSinkAPI *deviceAPI)
{
WFMModGUI* gui = WFMModGUI::create(m_pluginAPI, deviceAPI);
WFMModGUI::create(m_pluginAPI, deviceAPI);
}

View File

@ -311,7 +311,6 @@ bool BladerfOutput::applySettings(const BladeRFOutputSettings& settings, bool fo
if (m_deviceAPI->getSourceBuddies().size() > 0)
{
DeviceSourceAPI *buddy = m_deviceAPI->getSourceBuddies()[0];
DeviceBladeRFParams *buddySharedParams = (DeviceBladeRFParams *) buddy->getBuddySharedPtr();
if (buddy->getDeviceSourceEngine()->state() == DSPDeviceSourceEngine::StRunning) // Tx side running
{

View File

@ -49,7 +49,8 @@ BladerfOutputGui::BladerfOutputGui(DeviceSinkAPI *deviceAPI, QWidget* parent) :
ui->sampleRate->setValueRange(8, BLADERF_SAMPLERATE_MIN, BLADERF_SAMPLERATE_REC_MAX);
ui->bandwidth->clear();
for (int i = 0; i < BladerfBandwidths::getNbBandwidths(); i++)
for (unsigned int i = 0; i < BladerfBandwidths::getNbBandwidths(); i++)
{
ui->bandwidth->addItem(QString::number(BladerfBandwidths::getBandwidth(i)));
}

View File

@ -39,10 +39,10 @@ FileSinkGui::FileSinkGui(DeviceSinkAPI *deviceAPI, QWidget* parent) :
ui(new Ui::FileSinkGui),
m_deviceAPI(deviceAPI),
m_settings(),
m_deviceSampleSink(0),
m_sampleRate(0),
m_generation(false),
m_fileName("./test.sdriq"),
m_deviceSampleSink(0),
m_sampleRate(0),
m_generation(false),
m_startingTimeStamp(0),
m_samplesCount(0),
m_tickCount(0),
@ -285,7 +285,7 @@ void FileSinkGui::on_startStop_toggled(bool checked)
}
}
void FileSinkGui::on_showFileDialog_clicked(bool checked)
void FileSinkGui::on_showFileDialog_clicked(bool checked __attribute__((unused)))
{
QString fileName = QFileDialog::getSaveFileName(this,
tr("Save I/Q record file"), ".", tr("SDR I/Q Files (*.sdriq)"));

View File

@ -51,7 +51,6 @@ bool FileSinkSettings::deserialize(const QByteArray& data)
if (d.getVersion() == 1)
{
int intval;
d.readU64(1, &m_sampleRate, 48000);
d.readU32(2, &m_log2Interp, 0);
return true;

View File

@ -34,9 +34,9 @@ FileSinkThread::FileSinkThread(std::ofstream *samplesStream, SampleSourceFifo* s
m_samplerate(0),
m_log2Interpolation(0),
m_throttlems(FILESINK_THROTTLE_MS),
m_maxThrottlems(50),
m_throttleToggle(false),
m_buf(0),
m_maxThrottlems(50)
m_buf(0)
{
assert(m_ofstream != 0);
}
@ -147,8 +147,6 @@ void FileSinkThread::setLog2Interpolation(int log2Interpolation)
void FileSinkThread::run()
{
int res;
m_running = true;
m_startWaiter.wakeAll();

View File

@ -182,11 +182,11 @@ void HackRFOutputGui::displaySettings()
void HackRFOutputGui::displayBandwidths()
{
int savedIndex = HackRFBandwidths::getBandwidthIndex(m_settings.m_bandwidth/1000);
unsigned int savedIndex = HackRFBandwidths::getBandwidthIndex(m_settings.m_bandwidth/1000);
ui->bbFilter->blockSignals(true);
ui->bbFilter->clear();
for (int i = 0; i < HackRFBandwidths::m_nb_bw; i++)
for (unsigned int i = 0; i < HackRFBandwidths::m_nb_bw; i++)
{
ui->bbFilter->addItem(QString("%1M").arg(QString::number(HackRFBandwidths::m_bw_k[i]/1000.0, 'f', 2)));
}

View File

@ -90,7 +90,7 @@ PluginInterface::SamplingDevices HackRFOutputPlugin::enumSampleSinks()
uint32_t serial_lsb = read_partid_serialno.serial_no[3];
QString serial_str = QString::number(serial_msb, 16) + QString::number(serial_lsb, 16);
uint64_t serial_num = (((uint64_t) serial_msb)<<32) + serial_lsb;
//uint64_t serial_num = (((uint64_t) serial_msb)<<32) + serial_lsb;
QString displayedName(QString("HackRF[%1] %2").arg(i).arg(serial_str));
result.append(SamplingDevice(displayedName,

View File

@ -64,8 +64,6 @@ bool HackRFOutputSettings::deserialize(const QByteArray& data)
if (d.getVersion() == 1)
{
int intval;
d.readS32(1, &m_LOppmTenths, 0);
d.readBool(3, &m_biasT, false);
d.readU32(4, &m_log2Interp, 0);

View File

@ -93,7 +93,7 @@ bool LimeSDROutput::openDevice()
char *busyChannels = new char[deviceParams->m_nbTxChannels];
memset(busyChannels, 0, deviceParams->m_nbTxChannels);
for (int i = 0; i < m_deviceAPI->getSinkBuddies().size(); i++)
for (unsigned int i = 0; i < m_deviceAPI->getSinkBuddies().size(); i++)
{
DeviceSinkAPI *buddy = m_deviceAPI->getSinkBuddies()[i];
DeviceLimeSDRShared *buddyShared = (DeviceLimeSDRShared *) buddy->getBuddySharedPtr();
@ -186,7 +186,7 @@ void LimeSDROutput::suspendBuddies()
{
// suspend Tx buddy's threads
for (int i = 0; i < m_deviceAPI->getSinkBuddies().size(); i++)
for (unsigned int i = 0; i < m_deviceAPI->getSinkBuddies().size(); i++)
{
DeviceSinkAPI *buddy = m_deviceAPI->getSinkBuddies()[i];
DeviceLimeSDRShared *buddyShared = (DeviceLimeSDRShared *) buddy->getBuddySharedPtr();
@ -198,7 +198,7 @@ void LimeSDROutput::suspendBuddies()
// suspend Rx buddy's threads
for (int i = 0; i < m_deviceAPI->getSourceBuddies().size(); i++)
for (unsigned int i = 0; i < m_deviceAPI->getSourceBuddies().size(); i++)
{
DeviceSourceAPI *buddy = m_deviceAPI->getSourceBuddies()[i];
DeviceLimeSDRShared *buddyShared = (DeviceLimeSDRShared *) buddy->getBuddySharedPtr();
@ -213,7 +213,7 @@ void LimeSDROutput::resumeBuddies()
{
// resume Tx buddy's threads
for (int i = 0; i < m_deviceAPI->getSinkBuddies().size(); i++)
for (unsigned int i = 0; i < m_deviceAPI->getSinkBuddies().size(); i++)
{
DeviceSinkAPI *buddy = m_deviceAPI->getSinkBuddies()[i];
DeviceLimeSDRShared *buddyShared = (DeviceLimeSDRShared *) buddy->getBuddySharedPtr();
@ -225,7 +225,7 @@ void LimeSDROutput::resumeBuddies()
// resume Rx buddy's threads
for (int i = 0; i < m_deviceAPI->getSourceBuddies().size(); i++)
for (unsigned int i = 0; i < m_deviceAPI->getSourceBuddies().size(); i++)
{
DeviceSourceAPI *buddy = m_deviceAPI->getSourceBuddies()[i];
DeviceLimeSDRShared *buddyShared = (DeviceLimeSDRShared *) buddy->getBuddySharedPtr();

View File

@ -141,7 +141,7 @@ bool LimeSDROutputGUI::deserialize(const QByteArray& data)
}
}
bool LimeSDROutputGUI::handleMessage(const Message& message) // TODO: does not seem to be really useful in any of the source (+sink?) plugins
bool LimeSDROutputGUI::handleMessage(const Message& message __attribute__((unused))) // TODO: does not seem to be really useful in any of the source (+sink?) plugins
{
return false;
}
@ -373,7 +373,7 @@ void LimeSDROutputGUI::on_ncoEnable_toggled(bool checked)
sendSettings();
}
void LimeSDROutputGUI::on_ncoReset_clicked(bool checked)
void LimeSDROutputGUI::on_ncoReset_clicked(bool checked __attribute__((unused)))
{
m_settings.m_ncoFrequency = 0;
ui->ncoFrequency->setValue(m_settings.m_centerFrequency/1000);

View File

@ -67,8 +67,9 @@ void LimeSDROutputThread::setFcPos(int fcPos)
void LimeSDROutputThread::run()
{
int res, count, msleep, mdelta;
lms_stream_status_t streamStatus;
//int count, msleep, mdelta;
int res;
//lms_stream_status_t streamStatus;
lms_stream_meta_t metadata; //Use metadata for additional control over sample receive function behaviour
metadata.flushPartialPacket = false; //Do not discard data remainder when read size differs from packet size
@ -83,7 +84,7 @@ void LimeSDROutputThread::run()
qDebug("LimeSDROutputThread::run: stream started");
}
count = 0;
// count = 0;
// msleep = LIMESDROUTPUT_BLOCKSIZE/(m_sampleRate/1e6f);
// mdelta = msleep/100;
// msleep = (3*msleep)/4; // to start faster

View File

@ -62,14 +62,14 @@ CSocket::CSocket( int sockDesc )
m_sockDesc = sockDesc;
}
CSocket::CSocket( const CSocket &sock )
CSocket::CSocket(const CSocket &sock)
{
m_sockDesc = sock.m_sockDesc;
}
void CSocket::operator=( const CSocket &sock )
void CSocket::operator=(const CSocket &sock)
{
m_sockDesc = sock.m_sockDesc;
}
std::string CSocket::GetLocalAddress() throw(CSocketException)

View File

@ -53,7 +53,7 @@ SDRdaemonSinkGui::SDRdaemonSinkGui(DeviceSinkAPI *deviceAPI, QWidget* parent) :
m_nnSender = nn_socket(AF_SP, NN_PAIR);
assert(m_nnSender != -1);
int millis = 500;
int rc = nn_setsockopt (m_nnSender, NN_SOL_SOCKET, NN_SNDTIMEO, &millis, sizeof (millis));
nn_setsockopt (m_nnSender, NN_SOL_SOCKET, NN_SNDTIMEO, &millis, sizeof (millis));
assert (rc == 0);
ui->setupUi(this);
@ -262,7 +262,6 @@ void SDRdaemonSinkGui::sendControl(bool force)
std::ostringstream os;
int nbArgs = 0;
bool ok;
if ((m_settings.m_centerFrequency != m_controlSettings.m_centerFrequency) || force)
{
@ -455,11 +454,11 @@ void SDRdaemonSinkGui::on_specificParms_returnPressed()
sendControl();
}
void on_applyButton_clicked(bool checked)
void on_applyButton_clicked(bool checked __attribute__((unused)))
{
}
void on_sendButton_clicked(bool checked)
void on_sendButton_clicked(bool checked __attribute__((unused)))
{
}

View File

@ -37,10 +37,10 @@ MESSAGE_CLASS_DEFINITION(SDRdaemonSinkOutput::MsgReportSDRdaemonSinkStreamTiming
SDRdaemonSinkOutput::SDRdaemonSinkOutput(DeviceSinkAPI *deviceAPI, const QTimer& masterTimer) :
m_deviceAPI(deviceAPI),
m_settings(),
m_sdrDaemonSinkThread(0),
m_deviceDescription("SDRdaemonSink"),
m_startingTimeStamp(0),
m_masterTimer(masterTimer),
m_sdrDaemonSinkThread(0)
m_startingTimeStamp(0),
m_masterTimer(masterTimer)
{
}

View File

@ -63,7 +63,6 @@ bool SDRdaemonSinkSettings::deserialize(const QByteArray& data)
if (d.getVersion() == 1)
{
int intval;
quint32 uintval;
d.readU64(1, &m_sampleRate, 48000);
d.readU32(2, &m_log2Interp, 0);

View File

@ -31,8 +31,8 @@ SDRdaemonSinkThread::SDRdaemonSinkThread(SampleSourceFifo* sampleFifo, QObject*
m_samplesCount(0),
m_samplerate(0),
m_throttlems(SDRDAEMONSINK_THROTTLE_MS),
m_throttleToggle(false),
m_maxThrottlems(50)
m_maxThrottlems(50),
m_throttleToggle(false)
{
}
@ -94,8 +94,6 @@ void SDRdaemonSinkThread::setSamplerate(int samplerate)
void SDRdaemonSinkThread::run()
{
int res;
m_running = true;
m_startWaiter.wakeAll();

View File

@ -91,7 +91,6 @@ void UDPSinkFEC::write(const SampleVector::iterator& begin, uint32_t sampleChunk
while (it != end)
{
int inSamplesIndex = it - begin;
int inRemainingSamples = end - it;
if (m_txBlockIndex == 0) // Tx block index 0 is a block with only meta data
@ -266,7 +265,7 @@ void UDPSinkFECWorker::encodeAndTransmit(UDPSinkFEC::SuperBlock *txBlockx, uint1
{
qDebug("UDPSinkFECWorker::encodeAndTransmit: transmit frame without FEC to %s:%d", m_remoteAddress.toStdString().c_str(), m_remotePort);
for (int i = 0; i < UDPSinkFEC::m_nbOriginalBlocks; i++)
for (unsigned int i = 0; i < UDPSinkFEC::m_nbOriginalBlocks; i++)
{
m_socket.SendDataGram((const void *) &txBlockx[i], (int) UDPSinkFEC::m_udpSize, m_remoteAddress.toStdString(), (uint32_t) m_remotePort);
//m_udpSocket->writeDatagram((const char *) &txBlockx[i], (int) UDPSinkFEC::m_udpSize, m_remoteAddress, m_remotePort);

View File

@ -122,7 +122,7 @@ bool AirspyGui::deserialize(const QByteArray& data)
}
}
bool AirspyGui::handleMessage(const Message& message)
bool AirspyGui::handleMessage(const Message& message __attribute__((unused)))
{
return false;
// if (AirspyInput::MsgReportAirspy::match(message))
@ -214,14 +214,14 @@ void AirspyGui::displaySettings()
void AirspyGui::displaySampleRates()
{
int savedIndex = m_settings.m_devSampleRateIndex;
unsigned int savedIndex = m_settings.m_devSampleRateIndex;
ui->sampleRate->blockSignals(true);
if (m_rates.size() > 0)
{
ui->sampleRate->clear();
for (int i = 0; i < m_rates.size(); i++)
for (unsigned int i = 0; i < m_rates.size(); i++)
{
ui->sampleRate->addItem(QString("%1").arg(QString::number(m_rates[i]/1000000.0, 'f', 1)));
}

View File

@ -99,7 +99,7 @@ bool AirspyInput::openDevice()
m_sampleRates.clear();
for (int i=0; i<nbSampleRates; i++)
for (unsigned int i=0; i<nbSampleRates; i++)
{
m_sampleRates.push_back(sampleRates[i]);
qDebug("AirspyInput::start: sampleRates[%d] = %u Hz", i, sampleRates[i]);
@ -248,7 +248,7 @@ bool AirspyInput::applySettings(const AirspySettings& settings, bool force)
QMutexLocker mutexLocker(&m_mutex);
bool forwardChange = false;
airspy_error rc;
airspy_error rc = AIRSPY_ERROR_OTHER;
qDebug() << "AirspyInput::applySettings";
@ -486,12 +486,8 @@ bool AirspyInput::applySettings(const AirspySettings& settings, bool force)
struct airspy_device *AirspyInput::open_airspy_from_sequence(int sequence)
{
airspy_read_partid_serialno_t read_partid_serialno;
struct airspy_device *devinfo, *retdev = 0;
uint32_t serial_msb = 0;
uint32_t serial_lsb = 0;
airspy_error rc;
int i;
struct airspy_device *devinfo;
airspy_error rc = AIRSPY_ERROR_OTHER;
for (int i = 0; i < AIRSPY_MAX_DEVICE; i++)
{

View File

@ -92,7 +92,7 @@ PluginInterface::SamplingDevices AirspyPlugin::enumSampleSources()
serial_lsb = read_partid_serialno.serial_no[3];
QString serial_str = QString::number(serial_msb, 16) + QString::number(serial_lsb, 16);
uint64_t serial_num = (((uint64_t) serial_msb)<<32) + serial_lsb;
//uint64_t serial_num = (((uint64_t) serial_msb)<<32) + serial_lsb;
QString displayedName(QString("Airspy[%1] %2").arg(i).arg(serial_str));
result.append(SamplingDevice(displayedName,

View File

@ -300,7 +300,6 @@ bool BladerfInput::applySettings(const BladeRFInputSettings& settings, bool forc
if (m_deviceAPI->getSinkBuddies().size() > 0)
{
DeviceSinkAPI *buddy = m_deviceAPI->getSinkBuddies()[0];
DeviceBladeRFParams *buddySharedParams = (DeviceBladeRFParams *) buddy->getBuddySharedPtr();
if (buddy->getDeviceSinkEngine()->state() == DSPDeviceSinkEngine::StRunning) // Tx side running
{

View File

@ -50,7 +50,7 @@ BladerfInputGui::BladerfInputGui(DeviceSourceAPI *deviceAPI, QWidget* parent) :
ui->sampleRate->setValueRange(8, 330000U, BLADERF_SAMPLERATE_REC_MAX);
ui->bandwidth->clear();
for (int i = 0; i < BladerfBandwidths::getNbBandwidths(); i++)
for (unsigned int i = 0; i < BladerfBandwidths::getNbBandwidths(); i++)
{
ui->bandwidth->addItem(QString::number(BladerfBandwidths::getBandwidth(i)));
}
@ -128,7 +128,7 @@ bool BladerfInputGui::deserialize(const QByteArray& data)
}
}
bool BladerfInputGui::handleMessage(const Message& message)
bool BladerfInputGui::handleMessage(const Message& message __attribute__((unused)))
{
return false;
}

View File

@ -213,7 +213,7 @@ bool FCDProGui::deserialize(const QByteArray& data)
}
}
bool FCDProGui::handleMessage(const Message& message)
bool FCDProGui::handleMessage(const Message& message __attribute__((unused)))
{
return false;
}
@ -400,7 +400,7 @@ void FCDProGui::on_gain6_currentIndexChanged(int index)
sendSettings();
}
void FCDProGui::on_setDefaults_clicked(bool checked)
void FCDProGui::on_setDefaults_clicked(bool checked __attribute__((unused)))
{
m_settings.m_lnaGainIndex = 8; // +15 dB
//m_settings.rfFilterIndex = 0;

View File

@ -387,9 +387,9 @@ void FCDProInput::set_center_freq(double freq)
}
void FCDProInput::set_bias_t(bool on)
void FCDProInput::set_bias_t(bool on __attribute__((unused)))
{
quint8 cmd = on ? 1 : 0;
//quint8 cmd = on ? 1 : 0;
// TODO: use FCD Pro controls
//fcdAppSetParam(m_dev, FCD_CMD_APP_SET_BIAS_TEE, &cmd, 1);

View File

@ -86,8 +86,6 @@ bool FCDProSettings::deserialize(const QByteArray& data)
if (d.getVersion() == 1)
{
int intval;
d.readBool(1, &m_dcBlock, false);
d.readBool(2, &m_iqCorrection, false);
d.readS32(3, &m_LOppmTenths, 0);

View File

@ -131,7 +131,7 @@ bool FCDProPlusGui::deserialize(const QByteArray& data)
}
}
bool FCDProPlusGui::handleMessage(const Message& message)
bool FCDProPlusGui::handleMessage(const Message& message __attribute__((unused)))
{
return false;
}

View File

@ -66,8 +66,6 @@ bool FCDProPlusSettings::deserialize(const QByteArray& data)
if (d.getVersion() == 1)
{
int intval;
d.readBool(1, &m_biasT, false);
d.readBool(2, &m_rangeLow, false);
d.readBool(3, &m_mixGain, true);

View File

@ -209,7 +209,7 @@ void FileSourceGui::sendSettings()
{
}
void FileSourceGui::on_playLoop_toggled(bool checked)
void FileSourceGui::on_playLoop_toggled(bool checked __attribute__((unused)))
{
// TODO: do something about it!
}
@ -281,7 +281,7 @@ void FileSourceGui::on_navTimeSlider_valueChanged(int value)
}
}
void FileSourceGui::on_showFileDialog_clicked(bool checked)
void FileSourceGui::on_showFileDialog_clicked(bool checked __attribute__((unused)))
{
QString fileName = QFileDialog::getOpenFileName(this,
tr("Open I/Q record file"), ".", tr("SDR I/Q Files (*.sdriq)"));

View File

@ -64,7 +64,6 @@ bool FileSourceInput::Settings::deserialize(const QByteArray& data)
}
if(d.getVersion() == 1) {
int intval;
d.readString(1, &m_fileName, "./test.sdriq");
return true;
} else {

View File

@ -125,8 +125,6 @@ void FileSourceThread::setBuffer(std::size_t chunksize)
void FileSourceThread::run()
{
int res;
m_running = true;
m_startWaiter.wakeAll();

View File

@ -202,11 +202,11 @@ void HackRFInputGui::displaySettings()
void HackRFInputGui::displayBandwidths()
{
int savedIndex = HackRFBandwidths::getBandwidthIndex(m_settings.m_bandwidth/1000);
unsigned int savedIndex = HackRFBandwidths::getBandwidthIndex(m_settings.m_bandwidth/1000);
ui->bbFilter->blockSignals(true);
ui->bbFilter->clear();
for (int i = 0; i < HackRFBandwidths::m_nb_bw; i++)
for (unsigned int i = 0; i < HackRFBandwidths::m_nb_bw; i++)
{
ui->bbFilter->addItem(QString("%1M").arg(QString::number(HackRFBandwidths::m_bw_k[i]/1000.0, 'f', 2)));
}

View File

@ -90,7 +90,7 @@ PluginInterface::SamplingDevices HackRFInputPlugin::enumSampleSources()
uint32_t serial_lsb = read_partid_serialno.serial_no[3];
QString serial_str = QString::number(serial_msb, 16) + QString::number(serial_lsb, 16);
uint64_t serial_num = (((uint64_t) serial_msb)<<32) + serial_lsb;
//uint64_t serial_num = (((uint64_t) serial_msb)<<32) + serial_lsb;
QString displayedName(QString("HackRF[%1] %2").arg(i).arg(serial_str));
result.append(SamplingDevice(displayedName,

View File

@ -104,7 +104,7 @@ bool LimeSDRInput::openDevice()
char *busyChannels = new char[deviceParams->m_nbRxChannels];
memset(busyChannels, 0, deviceParams->m_nbRxChannels);
for (int i = 0; i < m_deviceAPI->getSourceBuddies().size(); i++)
for (unsigned int i = 0; i < m_deviceAPI->getSourceBuddies().size(); i++)
{
DeviceSourceAPI *buddy = m_deviceAPI->getSourceBuddies()[i];
DeviceLimeSDRShared *buddyShared = (DeviceLimeSDRShared *) buddy->getBuddySharedPtr();
@ -197,7 +197,7 @@ void LimeSDRInput::suspendBuddies()
{
// suspend Rx buddy's threads
for (int i = 0; i < m_deviceAPI->getSourceBuddies().size(); i++)
for (unsigned int i = 0; i < m_deviceAPI->getSourceBuddies().size(); i++)
{
DeviceSourceAPI *buddy = m_deviceAPI->getSourceBuddies()[i];
DeviceLimeSDRShared *buddyShared = (DeviceLimeSDRShared *) buddy->getBuddySharedPtr();
@ -209,7 +209,7 @@ void LimeSDRInput::suspendBuddies()
// suspend Tx buddy's threads
for (int i = 0; i < m_deviceAPI->getSinkBuddies().size(); i++)
for (unsigned int i = 0; i < m_deviceAPI->getSinkBuddies().size(); i++)
{
DeviceSinkAPI *buddy = m_deviceAPI->getSinkBuddies()[i];
DeviceLimeSDRShared *buddyShared = (DeviceLimeSDRShared *) buddy->getBuddySharedPtr();
@ -224,7 +224,7 @@ void LimeSDRInput::resumeBuddies()
{
// resume Rx buddy's threads
for (int i = 0; i < m_deviceAPI->getSourceBuddies().size(); i++)
for (unsigned int i = 0; i < m_deviceAPI->getSourceBuddies().size(); i++)
{
DeviceSourceAPI *buddy = m_deviceAPI->getSourceBuddies()[i];
DeviceLimeSDRShared *buddyShared = (DeviceLimeSDRShared *) buddy->getBuddySharedPtr();
@ -236,7 +236,7 @@ void LimeSDRInput::resumeBuddies()
// resume Tx buddy's threads
for (int i = 0; i < m_deviceAPI->getSinkBuddies().size(); i++)
for (unsigned int i = 0; i < m_deviceAPI->getSinkBuddies().size(); i++)
{
DeviceSinkAPI *buddy = m_deviceAPI->getSinkBuddies()[i];
DeviceLimeSDRShared *buddyShared = (DeviceLimeSDRShared *) buddy->getBuddySharedPtr();

View File

@ -144,7 +144,7 @@ bool LimeSDRInputGUI::deserialize(const QByteArray& data)
}
}
bool LimeSDRInputGUI::handleMessage(const Message& message) // TODO: does not seem to be really useful in any of the source (+sink?) plugins
bool LimeSDRInputGUI::handleMessage(const Message& message __attribute__((unused))) // TODO: does not seem to be really useful in any of the source (+sink?) plugins
{
return false;
}
@ -393,7 +393,7 @@ void LimeSDRInputGUI::on_ncoEnable_toggled(bool checked)
sendSettings();
}
void LimeSDRInputGUI::on_ncoReset_clicked(bool checked)
void LimeSDRInputGUI::on_ncoReset_clicked(bool checked __attribute__((unused)))
{
m_settings.m_ncoFrequency = 0;
ui->ncoFrequency->setValue(m_settings.m_centerFrequency/1000);

View File

@ -39,7 +39,7 @@ public:
virtual void startWork();
virtual void stopWork();
virtual void setDeviceSampleRate(int sampleRate) {}
virtual void setDeviceSampleRate(int sampleRate __attribute__((unused))) {}
void setLog2Decimation(unsigned int log2_decim);
void setFcPos(int fcPos);

View File

@ -306,7 +306,7 @@ void RTLSDRGui::on_gain_valueChanged(int value)
sendSettings();
}
void RTLSDRGui::on_sampleRate_currentIndexChanged(int index)
void RTLSDRGui::on_sampleRate_currentIndexChanged(int index __attribute__((unused)))
{
}

View File

@ -238,7 +238,7 @@ bool RTLSDRInput::handleMessage(const Message& message)
}
else if (MsgQueryRTLSDR::match(message))
{
MsgQueryRTLSDR& conf = (MsgQueryRTLSDR&) message;
//MsgQueryRTLSDR& conf = (MsgQueryRTLSDR&) message;
qDebug() << "RTLSDRInput::handleMessage: MsgQueryRTLSDR";
MsgReportRTLSDR *message = MsgReportRTLSDR::create(m_gains);

View File

@ -95,7 +95,7 @@ SDRdaemonBuffer::~SDRdaemonBuffer()
void SDRdaemonBuffer::updateBufferSize(uint32_t sampleRate)
{
uint32_t rawSize = sampleRate * m_iqSampleSize * m_rawBufferLengthSeconds; // store worth of this seconds of samples at this sample rate
int rawSize = sampleRate * m_iqSampleSize * m_rawBufferLengthSeconds; // store worth of this seconds of samples at this sample rate
if ((m_frameSize > 0) && (rawSize / m_frameSize < m_rawBufferMinNbFrames))
{
@ -148,9 +148,8 @@ void SDRdaemonBuffer::updateReadBufferSize(uint32_t length)
m_readBuffer = new uint8_t[length];
}
bool SDRdaemonBuffer::readMeta(char *array, uint32_t length)
bool SDRdaemonBuffer::readMeta(char *array)
{
assert(length >= sizeof(MetaData) + 8);
MetaData *metaData = (MetaData *) array;
if (m_crc64.calculate_crc((uint8_t *) array, sizeof(MetaData) - 8) == metaData->m_crc)
@ -183,7 +182,7 @@ bool SDRdaemonBuffer::readMeta(char *array, uint32_t length)
{
m_sampleBytes = metaData->m_sampleBytes & 0x0F;
uint32_t frameSize = m_iqSampleSize * metaData->m_nbSamples * metaData->m_nbBlocks;
int sampleRate = metaData->m_sampleRate;
uint32_t sampleRate = metaData->m_sampleRate;
if (sampleRate != m_sampleRateStream) // change of nominal stream sample rate
{
@ -337,7 +336,7 @@ uint8_t *SDRdaemonBuffer::readData(int32_t length)
}
}
void SDRdaemonBuffer::writeDataLZ4(const char *array, uint32_t length)
void SDRdaemonBuffer::writeDataLZ4(const char *array, int length)
{
if (m_lz4InCount + length < m_lz4InSize)
{
@ -394,7 +393,7 @@ void SDRdaemonBuffer::writeToRawBufferLZ4()
}
}
void SDRdaemonBuffer::writeToRawBufferUncompressed(const char *array, uint32_t length)
void SDRdaemonBuffer::writeToRawBufferUncompressed(const char *array, int length)
{
// TODO: handle the 1 byte per I or Q sample
if (m_writeIndex + length < m_rawSize)

Some files were not shown because too many files have changed in this diff Show More