- initial version
git-svn-id: http://moon:8086/svn/software/trunk/projects/mpsk_rx_gui@14 b431acfa-c32f-4a4a-93f1-934dc6c82436
This commit is contained in:
@@ -193,6 +193,9 @@ void GraphComponent::setGraphBounds(float minX, float maxX, float minY, float ma
|
||||
|
||||
float GraphComponent::getScreenCoordX(float x)
|
||||
{
|
||||
if (isnan(x) || isinf(x))
|
||||
return 0;
|
||||
|
||||
if ((x > m_graphMaxX) || (x < m_graphMinX))
|
||||
return 0;
|
||||
|
||||
@@ -201,6 +204,9 @@ float GraphComponent::getScreenCoordX(float x)
|
||||
|
||||
float GraphComponent::getScreenCoordY(float y)
|
||||
{
|
||||
if (isnan(y) || isinf(y))
|
||||
return 0;
|
||||
|
||||
if ((y > m_graphMaxY) || (y < m_graphMinY))
|
||||
return 0;
|
||||
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
|
||||
//[Headers] You can add your own extra header files here...
|
||||
//[/Headers]
|
||||
|
||||
#include <cmath>
|
||||
#include "IQPlaneComponent.h"
|
||||
|
||||
|
||||
@@ -158,6 +158,9 @@ void IQPlaneComponent::pointAdd(sym_err_t *pPoint, uint32_t numPoints)
|
||||
|
||||
float IQPlaneComponent::getScreenCoordX(float x)
|
||||
{
|
||||
if (isnan(x) || isinf(x))
|
||||
return 0;
|
||||
|
||||
if ((x > 1.0) || (x < -1.0))
|
||||
return 0;
|
||||
|
||||
@@ -166,6 +169,9 @@ float IQPlaneComponent::getScreenCoordX(float x)
|
||||
|
||||
float IQPlaneComponent::getScreenCoordY(float y)
|
||||
{
|
||||
if (isnan(y) || isinf(y))
|
||||
return 0;
|
||||
|
||||
if ((y > 1.0) || (y < -1.0))
|
||||
return 0;
|
||||
|
||||
|
||||
@@ -1003,9 +1003,26 @@ void Receiver::processPassband(float *pRF, uint32_t len)
|
||||
const ScopedLock sl (m_lock);
|
||||
|
||||
uint32_t len_down;
|
||||
float test4normal;
|
||||
|
||||
if (!m_ReceiverEnable)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
test4normal = 0;
|
||||
for (uint32_t i=0; i < len; i++)
|
||||
{
|
||||
test4normal += pRF[i];
|
||||
}
|
||||
if (isnan(test4normal))
|
||||
{
|
||||
return;
|
||||
}
|
||||
if (dabs(test4normal/len) > 10)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
SlidingVarProcessV(&m_statistics.RF, pRF, len);
|
||||
|
||||
|
||||
@@ -209,6 +209,8 @@ private:
|
||||
void setSamplerate(float samplerate_hz) override
|
||||
{
|
||||
m_samplerate = samplerate_hz;
|
||||
m_carrierFreq = samplerate_hz/4;
|
||||
m_symbolrate = samplerate_hz/4;
|
||||
paramChanged();
|
||||
}
|
||||
void setCarrierFrequency(float frequency_hz) override
|
||||
|
||||
Reference in New Issue
Block a user