mirror of
https://github.com/portapack-mayhem/mayhem-firmware.git
synced 2025-08-15 00:57:41 +00:00
Move AudioOutput back to inside audio processor classes.
Was wasting precious RAM making it static. I lose 400 bytes of .text, not sure why, but I think the trade is worth it.
This commit is contained in:
@@ -98,5 +98,3 @@ void AudioOutput::feed_audio_stats(const buffer_f32_t& audio) {
|
|||||||
}
|
}
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
AudioOutput audio_output;
|
|
||||||
|
@@ -55,6 +55,4 @@ private:
|
|||||||
void feed_audio_stats(const buffer_f32_t& audio);
|
void feed_audio_stats(const buffer_f32_t& audio);
|
||||||
};
|
};
|
||||||
|
|
||||||
extern AudioOutput audio_output;
|
|
||||||
|
|
||||||
#endif/*__AUDIO_OUTPUT_H__*/
|
#endif/*__AUDIO_OUTPUT_H__*/
|
||||||
|
@@ -27,6 +27,7 @@
|
|||||||
#include "dsp_decimate.hpp"
|
#include "dsp_decimate.hpp"
|
||||||
#include "dsp_demodulate.hpp"
|
#include "dsp_demodulate.hpp"
|
||||||
|
|
||||||
|
#include "audio_output.hpp"
|
||||||
#include "spectrum_collector.hpp"
|
#include "spectrum_collector.hpp"
|
||||||
|
|
||||||
#include <cstdint>
|
#include <cstdint>
|
||||||
@@ -56,6 +57,8 @@ private:
|
|||||||
|
|
||||||
dsp::demodulate::AM demod;
|
dsp::demodulate::AM demod;
|
||||||
|
|
||||||
|
AudioOutput audio_output;
|
||||||
|
|
||||||
SpectrumCollector channel_spectrum;
|
SpectrumCollector channel_spectrum;
|
||||||
|
|
||||||
bool configured { false };
|
bool configured { false };
|
||||||
|
@@ -27,6 +27,7 @@
|
|||||||
#include "dsp_decimate.hpp"
|
#include "dsp_decimate.hpp"
|
||||||
#include "dsp_demodulate.hpp"
|
#include "dsp_demodulate.hpp"
|
||||||
|
|
||||||
|
#include "audio_output.hpp"
|
||||||
#include "spectrum_collector.hpp"
|
#include "spectrum_collector.hpp"
|
||||||
|
|
||||||
class NarrowbandFMAudio : public BasebandProcessor {
|
class NarrowbandFMAudio : public BasebandProcessor {
|
||||||
@@ -55,6 +56,8 @@ private:
|
|||||||
|
|
||||||
dsp::demodulate::FM demod;
|
dsp::demodulate::FM demod;
|
||||||
|
|
||||||
|
AudioOutput audio_output;
|
||||||
|
|
||||||
SpectrumCollector channel_spectrum;
|
SpectrumCollector channel_spectrum;
|
||||||
|
|
||||||
bool configured { false };
|
bool configured { false };
|
||||||
|
@@ -27,6 +27,7 @@
|
|||||||
#include "dsp_decimate.hpp"
|
#include "dsp_decimate.hpp"
|
||||||
#include "dsp_demodulate.hpp"
|
#include "dsp_demodulate.hpp"
|
||||||
|
|
||||||
|
#include "audio_output.hpp"
|
||||||
#include "spectrum_collector.hpp"
|
#include "spectrum_collector.hpp"
|
||||||
|
|
||||||
class WidebandFMAudio : public BasebandProcessor {
|
class WidebandFMAudio : public BasebandProcessor {
|
||||||
@@ -56,6 +57,8 @@ private:
|
|||||||
dsp::decimate::DecimateBy2CIC4Real audio_dec_2;
|
dsp::decimate::DecimateBy2CIC4Real audio_dec_2;
|
||||||
dsp::decimate::FIR64AndDecimateBy2Real audio_filter;
|
dsp::decimate::FIR64AndDecimateBy2Real audio_filter;
|
||||||
|
|
||||||
|
AudioOutput audio_output;
|
||||||
|
|
||||||
SpectrumCollector channel_spectrum;
|
SpectrumCollector channel_spectrum;
|
||||||
size_t spectrum_interval_samples = 0;
|
size_t spectrum_interval_samples = 0;
|
||||||
size_t spectrum_samples = 0;
|
size_t spectrum_samples = 0;
|
||||||
|
Reference in New Issue
Block a user