Corrections to comments

pull/16/merge
boblark 2 years ago
parent fd31e3974e
commit 8be3167537
  1. 6
      analyze_fft1024_F32.cpp
  2. 2
      radioCESSBtransmit_F32.h

@ -45,7 +45,7 @@ static void copy_to_fft_buffer(void *destination, const void *source) {
} }
static void apply_window_to_fft_buffer(void *buffer, const void *window) { static void apply_window_to_fft_buffer(void *buffer, const void *window) {
float *buf = (float *)buffer; float *buf = (float *)buffer;
const float *win = (float *)window; const float *win = (float *)window;
for(int i=0; i<NFFT; i++) for(int i=0; i<NFFT; i++)
@ -87,7 +87,7 @@ void AudioAnalyzeFFT1024_F32::update(void) {
if(i>0) { if(i>0) {
float rns = 0.5f*(fft_buffer[2*i] + fft_buffer[NFFT-2*i]); float rns = 0.5f*(fft_buffer[2*i] + fft_buffer[NFFT-2*i]);
float ins = 0.5f*(fft_buffer[2*i+1] + fft_buffer[NFFT-2*i+1]); float ins = 0.5f*(fft_buffer[2*i+1] + fft_buffer[NFFT-2*i+1]);
float rnd = 0.5f*(fft_buffer[2*i] - fft_buffer[NFFT-2*i]); float rnd = 0.5f*(fft_buffer[2*i] - fft_buffer[NFFT-2*i]);
float ind = 0.5f*(fft_buffer[2*i+1] - fft_buffer[NFFT-2*i+1]); float ind = 0.5f*(fft_buffer[2*i+1] - fft_buffer[NFFT-2*i+1]);
float xr = rns + cosN[i]*ins - sinN[i]*rnd; float xr = rns + cosN[i]*ins - sinN[i]*rnd;
@ -106,7 +106,7 @@ void AudioAnalyzeFFT1024_F32::update(void) {
if (count >= nAverage) { // Average is finished if (count >= nAverage) { // Average is finished
// Set outputflag false here to minimize reads of output[] data // Set outputflag false here to minimize reads of output[] data
// when it is being updated. // when it is being updated.
outputflag = false; outputflag = false;
count = 0; count = 0;
float inAf = 1.0f/(float)nAverage; float inAf = 1.0f/(float)nAverage;

@ -217,7 +217,7 @@ public:
{ {
levelData.pwr0 = powerSum0/(2.975f*(float32_t)countPower0); // WHY???? levelData.pwr0 = powerSum0/(2.975f*(float32_t)countPower0); // WHY????
levelData.peak0 = maxMag0; levelData.peak0 = maxMag0;
levelData.pwr1 = powerSum1/(float32_t)countPower1; levelData.pwr1 = powerSum1/(float32_t)countPower1;
levelData.peak1 = maxMag1; levelData.peak1 = maxMag1;
levelData.countP = countPower0; levelData.countP = countPower0;

Loading…
Cancel
Save