mirror of
https://github.com/f4exb/sdrangel.git
synced 2024-11-15 21:01:45 -05:00
Fixed -Wunused-but-set-variable warnings
This commit is contained in:
parent
3f2f1fcd7f
commit
4e2978f7ea
@ -811,44 +811,44 @@ void ADSBDemodGUI::handleADSB(
|
|||||||
}
|
}
|
||||||
else if ((movement >= 2) && (movement <= 123))
|
else if ((movement >= 2) && (movement <= 123))
|
||||||
{
|
{
|
||||||
float base, step; // In knts
|
// float base, step; // In knts
|
||||||
int adjust;
|
// int adjust;
|
||||||
if ((movement >= 2) && (movement <= 8))
|
// if ((movement >= 2) && (movement <= 8))
|
||||||
{
|
// {
|
||||||
base = 0.125f;
|
// base = 0.125f;
|
||||||
step = 0.125f;
|
// step = 0.125f;
|
||||||
adjust = 2;
|
// adjust = 2;
|
||||||
}
|
// }
|
||||||
else if ((movement >= 9) && (movement <= 12))
|
// else if ((movement >= 9) && (movement <= 12))
|
||||||
{
|
// {
|
||||||
base = 1.0f;
|
// base = 1.0f;
|
||||||
step = 0.25f;
|
// step = 0.25f;
|
||||||
adjust = 9;
|
// adjust = 9;
|
||||||
}
|
// }
|
||||||
else if ((movement >= 13) && (movement <= 38))
|
// else if ((movement >= 13) && (movement <= 38))
|
||||||
{
|
// {
|
||||||
base = 2.0f;
|
// base = 2.0f;
|
||||||
step = 0.5f;
|
// step = 0.5f;
|
||||||
adjust = 13;
|
// adjust = 13;
|
||||||
}
|
// }
|
||||||
else if ((movement >= 39) && (movement <= 93))
|
// else if ((movement >= 39) && (movement <= 93))
|
||||||
{
|
// {
|
||||||
base = 15.0f;
|
// base = 15.0f;
|
||||||
step = 1.0f;
|
// step = 1.0f;
|
||||||
adjust = 39;
|
// adjust = 39;
|
||||||
}
|
// }
|
||||||
else if ((movement >= 94) && (movement <= 108))
|
// else if ((movement >= 94) && (movement <= 108))
|
||||||
{
|
// {
|
||||||
base = 70.0f;
|
// base = 70.0f;
|
||||||
step = 2.0f;
|
// step = 2.0f;
|
||||||
adjust = 94;
|
// adjust = 94;
|
||||||
}
|
// }
|
||||||
else
|
// else
|
||||||
{
|
// {
|
||||||
base = 100.0f;
|
// base = 100.0f;
|
||||||
step = 5.0f;
|
// step = 5.0f;
|
||||||
adjust = 109;
|
// adjust = 109;
|
||||||
}
|
// }
|
||||||
aircraft->m_speedType = Aircraft::GS;
|
aircraft->m_speedType = Aircraft::GS;
|
||||||
aircraft->m_speedValid = true;
|
aircraft->m_speedValid = true;
|
||||||
aircraft->m_speedItem->setData(Qt::DisplayRole, m_settings.m_siUnits ? knotsToKPHInt(aircraft->m_speed) : (int)std::round(aircraft->m_speed));
|
aircraft->m_speedItem->setData(Qt::DisplayRole, m_settings.m_siUnits ? knotsToKPHInt(aircraft->m_speed) : (int)std::round(aircraft->m_speed));
|
||||||
|
@ -802,7 +802,7 @@ bool LimeSDRMIMO::applySettings(const LimeSDRMIMOSettings& settings, bool force)
|
|||||||
}
|
}
|
||||||
|
|
||||||
if ((m_settings.m_ncoFrequencyRx != settings.m_ncoFrequencyRx) ||
|
if ((m_settings.m_ncoFrequencyRx != settings.m_ncoFrequencyRx) ||
|
||||||
(m_settings.m_ncoEnableRx != settings.m_ncoEnableRx) || force)
|
(m_settings.m_ncoEnableRx != settings.m_ncoEnableRx) || force || forceRxNCOFrequency)
|
||||||
{
|
{
|
||||||
forwardChangeRxDSP = true;
|
forwardChangeRxDSP = true;
|
||||||
applyRxNCOFrequency(0, settings.m_ncoEnableRx, settings.m_ncoFrequencyRx);
|
applyRxNCOFrequency(0, settings.m_ncoEnableRx, settings.m_ncoFrequencyRx);
|
||||||
|
@ -382,6 +382,10 @@ void XTRXOutput::stop()
|
|||||||
// remove old thread address from buddies (reset in all buddies)
|
// remove old thread address from buddies (reset in all buddies)
|
||||||
const std::vector<DeviceAPI*>& sinkBuddies = m_deviceAPI->getSinkBuddies();
|
const std::vector<DeviceAPI*>& sinkBuddies = m_deviceAPI->getSinkBuddies();
|
||||||
std::vector<DeviceAPI*>::const_iterator it = sinkBuddies.begin();
|
std::vector<DeviceAPI*>::const_iterator it = sinkBuddies.begin();
|
||||||
|
|
||||||
|
for (; it != sinkBuddies.end(); ++it) {
|
||||||
|
((DeviceXTRXShared*) (*it)->getBuddySharedPtr())->m_sink->setThread(nullptr);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else if (nbOriginalChannels == 2) // Reduce from MO to SO by deleting and re-creating the thread
|
else if (nbOriginalChannels == 2) // Reduce from MO to SO by deleting and re-creating the thread
|
||||||
{
|
{
|
||||||
@ -398,6 +402,11 @@ void XTRXOutput::stop()
|
|||||||
// remove old thread address from buddies (reset in all buddies). The address being held only in the owning source.
|
// remove old thread address from buddies (reset in all buddies). The address being held only in the owning source.
|
||||||
const std::vector<DeviceAPI*>& sinkBuddies = m_deviceAPI->getSinkBuddies();
|
const std::vector<DeviceAPI*>& sinkBuddies = m_deviceAPI->getSinkBuddies();
|
||||||
std::vector<DeviceAPI*>::const_iterator it = sinkBuddies.begin();
|
std::vector<DeviceAPI*>::const_iterator it = sinkBuddies.begin();
|
||||||
|
|
||||||
|
for (; it != sinkBuddies.end(); ++it) {
|
||||||
|
((DeviceXTRXShared*) (*it)->getBuddySharedPtr())->m_sink->setThread(nullptr);
|
||||||
|
}
|
||||||
|
|
||||||
applySettings(m_settings, true);
|
applySettings(m_settings, true);
|
||||||
xtrxOutputThread->startWork();
|
xtrxOutputThread->startWork();
|
||||||
}
|
}
|
||||||
|
@ -392,6 +392,10 @@ void XTRXInput::stop()
|
|||||||
// remove old thread address from buddies (reset in all buddies)
|
// remove old thread address from buddies (reset in all buddies)
|
||||||
const std::vector<DeviceAPI*>& sourceBuddies = m_deviceAPI->getSourceBuddies();
|
const std::vector<DeviceAPI*>& sourceBuddies = m_deviceAPI->getSourceBuddies();
|
||||||
std::vector<DeviceAPI*>::const_iterator it = sourceBuddies.begin();
|
std::vector<DeviceAPI*>::const_iterator it = sourceBuddies.begin();
|
||||||
|
|
||||||
|
for (; it != sourceBuddies.end(); ++it) {
|
||||||
|
((DeviceXTRXShared*) (*it)->getBuddySharedPtr())->m_source->setThread(nullptr);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else if (nbOriginalChannels == 2) // Reduce from MI to SI by deleting and re-creating the thread
|
else if (nbOriginalChannels == 2) // Reduce from MI to SI by deleting and re-creating the thread
|
||||||
{
|
{
|
||||||
@ -409,6 +413,11 @@ void XTRXInput::stop()
|
|||||||
// remove old thread address from buddies (reset in all buddies). The address being held only in the owning source.
|
// remove old thread address from buddies (reset in all buddies). The address being held only in the owning source.
|
||||||
const std::vector<DeviceAPI*>& sourceBuddies = m_deviceAPI->getSourceBuddies();
|
const std::vector<DeviceAPI*>& sourceBuddies = m_deviceAPI->getSourceBuddies();
|
||||||
std::vector<DeviceAPI*>::const_iterator it = sourceBuddies.begin();
|
std::vector<DeviceAPI*>::const_iterator it = sourceBuddies.begin();
|
||||||
|
|
||||||
|
for (; it != sourceBuddies.end(); ++it) {
|
||||||
|
((DeviceXTRXShared*) (*it)->getBuddySharedPtr())->m_source->setThread(nullptr);
|
||||||
|
}
|
||||||
|
|
||||||
applySettings(m_settings, true);
|
applySettings(m_settings, true);
|
||||||
xtrxInputThread->startWork();
|
xtrxInputThread->startWork();
|
||||||
}
|
}
|
||||||
|
@ -157,7 +157,6 @@ void SampleMIFifo::readSync(
|
|||||||
}
|
}
|
||||||
|
|
||||||
QMutexLocker mutexLocker(&m_mutex);
|
QMutexLocker mutexLocker(&m_mutex);
|
||||||
std::vector<SampleVector>::iterator dataIt = m_data.begin();
|
|
||||||
vpart1Begin.resize(m_nbStreams);
|
vpart1Begin.resize(m_nbStreams);
|
||||||
vpart1End.resize(m_nbStreams);
|
vpart1End.resize(m_nbStreams);
|
||||||
vpart2Begin.resize(m_nbStreams);
|
vpart2Begin.resize(m_nbStreams);
|
||||||
@ -197,7 +196,6 @@ void SampleMIFifo::readSync(
|
|||||||
}
|
}
|
||||||
|
|
||||||
QMutexLocker mutexLocker(&m_mutex);
|
QMutexLocker mutexLocker(&m_mutex);
|
||||||
std::vector<SampleVector>::iterator dataIt = m_data.begin();
|
|
||||||
vpart1Begin.resize(m_nbStreams);
|
vpart1Begin.resize(m_nbStreams);
|
||||||
vpart1End.resize(m_nbStreams);
|
vpart1End.resize(m_nbStreams);
|
||||||
vpart2Begin.resize(m_nbStreams);
|
vpart2Begin.resize(m_nbStreams);
|
||||||
|
Loading…
Reference in New Issue
Block a user