rtl_fm: add a new option to select 2nd direct sampling mode

This commit is contained in:
Doug Hammond 2021-07-29 18:27:17 +01:00 committed by Steve Markgraf
parent 3163b8817f
commit a4eab76c8c
1 changed files with 9 additions and 6 deletions

View File

@ -204,7 +204,8 @@ void usage(void)
"\t edge: enable lower edge tuning\n"
"\t dc: enable dc blocking filter\n"
"\t deemp: enable de-emphasis filter\n"
"\t direct: enable direct sampling\n"
"\t direct: enable direct sampling 1 (usually I)\n"
"\t direct2: enable direct sampling 2 (usually Q)\n"
"\t offset: enable offset tuning\n"
"\tfilename ('-' means stdout)\n"
"\t omitting the filename also uses stdout\n\n"
@ -892,7 +893,7 @@ static void *controller_thread_fn(void *arg)
/* set up primary channel */
optimal_settings(s->freqs[0], demod.rate_in);
if (dongle.direct_sampling) {
verbose_direct_sampling(dongle.dev, 1);}
verbose_direct_sampling(dongle.dev, dongle.direct_sampling);}
if (dongle.offset_tuning) {
verbose_offset_tuning(dongle.dev);}
@ -1119,6 +1120,8 @@ int main(int argc, char **argv)
demod.deemph = 1;}
if (strcmp("direct", optarg) == 0) {
dongle.direct_sampling = 1;}
if (strcmp("direct2", optarg) == 0) {
dongle.direct_sampling = 2;}
if (strcmp("offset", optarg) == 0) {
dongle.offset_tuning = 1;}
break;