- refactored

git-svn-id: http://moon:8086/svn/software/trunk/libsrc/cpp@979 b431acfa-c32f-4a4a-93f1-934dc6c82436
This commit is contained in:
2022-06-15 10:40:20 +00:00
parent 4192bc92aa
commit b5fa2c41c2
4 changed files with 87 additions and 67 deletions
+49
View File
@@ -0,0 +1,49 @@
#include "TimingGenerator.hpp"
#include <iostream>
namespace Radio
{
namespace Interpolation
{
TimingGenerator::TimingGenerator()
: m_omega(1)
, m_mu(0)
, m_adv(0)
{
}
TimingGenerator::~TimingGenerator()
{
}
void TimingGenerator::setOmega(radio_float_t omega)
{
m_omega = omega;
}
void TimingGenerator::process(ComplexScalar const &iq)
{
(void)iq;
update();
}
void TimingGenerator::update()
{
m_mu += m_omega;
m_adv = (size_t)m_mu;
m_mu -= m_adv;
}
radio_float_t TimingGenerator::getMu() const
{
return m_mu;
}
size_t TimingGenerator::getAdv() const
{
return m_adv;
}
} // Interpolation
} // Radio