diff --git a/src/dsd_ncurses.c b/src/dsd_ncurses.c index 9e7a86b..0a715a0 100644 --- a/src/dsd_ncurses.c +++ b/src/dsd_ncurses.c @@ -2552,7 +2552,8 @@ ncursesPrinter (dsd_opts * opts, dsd_state * state) if (opts->mod_gfsk == 1) printw ("[GFSK]"); printw ( "[%d] \n", (48000*opts->wav_interpolator)/state->samplesPerSymbol); if (opts->m17encoder == 1) printw ("| Encoding: [%s] ", opts->output_name); - if (opts->m17encoder == 1) printw ("(\\) \n"); + if (opts->m17encoder == 1) printw (" Toggle (\\); "); + if (opts->m17encoder == 1) printw (" Mic Gain (/|*): %02.0f%% \n", opts->audio_gainA); printw ("| Decoding: [%s] ", opts->output_name); if (opts->aggressive_framesync == 0) printw ("CRC/(RAS) "); //debug -- troubleshoot voice tuning after grant on DMR CC, subsequent grant may not tune because tuner isn't available diff --git a/src/m17.c b/src/m17.c index 3ed065c..729c170 100644 --- a/src/m17.c +++ b/src/m17.c @@ -1844,14 +1844,6 @@ void encodeM17STR(dsd_opts * opts, dsd_state * state) if (opts->audio_in_type == 3) opts->rtl_rms = rtl_return_rms(); else opts->rtl_rms = raw_rms(voice1, nsam, 1) / 2; //dividing by two so mic isn't so sensitive on vox - //decimate audio input (default 100% on mic is WAY TOO LOUD for the encoder, fine tune in volume control) - for (i = 0; i < 160; i++) - { - //NOTE: Use + and - in ncurses to fine tune manually - voice1[i] *= (float)state->aout_gain/ (float)25.0f; - voice2[i] *= (float)state->aout_gain/ (float)25.0f; - } - //run hpf if from the dongle, mic input doesn't need it, and if using SDR++, use the high pass filter there instead if (opts->audio_in_type == 3) { @@ -1861,6 +1853,10 @@ void encodeM17STR(dsd_opts * opts, dsd_state * state) pbf (state, voice2, 160); } + //manual adjustment to gain, after filtering them + analog_gain (opts, state, voice1, 160); + analog_gain (opts, state, voice2, 160); + //NOTE: Similar to EDACS analog, if calculating raw rms here after filtering, //anytime the walkie-talkie is held open but no voice, the center spike is removed, //and counts against the squelch hits making vox mode inconsistent