mirror of
https://github.com/eried/portapack-mayhem.git
synced 2025-02-03 10:00:12 -05:00
Reduce type size for int16_t squared values.
This commit is contained in:
parent
ef37bbd851
commit
9fb22dfd1f
@ -33,9 +33,9 @@ bool FMSquelch::execute(buffer_s16_t audio) {
|
||||
};
|
||||
non_audio_hpf.execute(audio, squelch_energy);
|
||||
|
||||
uint64_t max_squared = 0;
|
||||
uint32_t max_squared = 0;
|
||||
for(const auto sample : squelch_energy_buffer) {
|
||||
const uint64_t sample_squared = sample * sample;
|
||||
const uint32_t sample_squared = sample * sample;
|
||||
if( sample_squared > max_squared ) {
|
||||
max_squared = sample_squared;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user