-
Notifications
You must be signed in to change notification settings - Fork 2
/
PLL.h
38 lines (27 loc) · 846 Bytes
/
PLL.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
//---------------------------------------------------------------------------
#ifndef PLLH
#define PLLH
#include "DelayLine.h"
class PLL
{
public:
int n_steps; // number of steps to divide the symbol
int current_step; // current step
int step_clock; // hiresolution step (in 1000th)
float *amp_buf; // averaged amplitude of the symbol (symbol shape)
float amp_delay; // IIR factor for step average
int last_peak_pos; // position in the array of the last peak detected
DelayLine *AVF;
int Peak_Pos;
int New_Peak_Pos;
int *half_table;
PLL();
~PLL();
void SetSize(int nsteps);
void SetDelay(int delay);
void Reset();
bool SymbolSynch(float ampl);
bool SymbolSynchAVF(float ampl);
bool SymbolSynch_simple(float ampl);
};
#endif