Fix baseband thread init order bug for all procs. (#1293)

This commit is contained in:
Kyle Reed
2023-07-22 23:54:17 -07:00
committed by GitHub
parent 828eb67a52
commit 7bd370b5bc
46 changed files with 226 additions and 174 deletions

View File

@@ -67,9 +67,6 @@ class ERTProcessor : public BasebandProcessor {
const size_t samples_per_symbol = channel_sampling_rate / symbol_rate;
const float clock_recovery_rate = symbol_rate * 2;
BasebandThread baseband_thread{baseband_sampling_rate, this, NORMALPRIO + 20, baseband::Direction::Receive};
RSSIThread rssi_thread{NORMALPRIO + 10};
clock_recovery::ClockRecovery<clock_recovery::FixedErrorFilter> clock_recovery{
clock_recovery_rate,
symbol_rate,
@@ -116,6 +113,10 @@ class ERTProcessor : public BasebandProcessor {
float offset_i{0.0f};
float offset_q{0.0f};
/* NB: Threads should be the last members in the class definition. */
BasebandThread baseband_thread{baseband_sampling_rate, this, baseband::Direction::Receive};
RSSIThread rssi_thread{};
float abs(const complex8_t& v);
};