mirror of
https://github.com/g4klx/MMDVM.git
synced 2026-08-21 14:36:21 +02:00
Convert the Goertzel algorithm to Q15 and Q31.
This commit is contained in:
+5
-5
@@ -27,16 +27,16 @@ public:
|
||||
|
||||
uint8_t setParams(uint8_t frequency, uint8_t threshold);
|
||||
|
||||
bool process(q15_t* samples, uint8_t length);
|
||||
bool process(const q15_t* samples, uint8_t length);
|
||||
|
||||
void reset();
|
||||
|
||||
private:
|
||||
float32_t m_coeff;
|
||||
float32_t m_threshold;
|
||||
q31_t m_coeffDivTwo;
|
||||
uint16_t m_threshold;
|
||||
uint16_t m_count;
|
||||
float m_q0;
|
||||
float m_q1;
|
||||
q31_t m_q0;
|
||||
q31_t m_q1;
|
||||
bool m_result;
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user