examples/adc: Fix g_adcstate.count initialization.
This commit is contained in:
parent
928443e385
commit
98fb74b82c
@ -257,13 +257,14 @@ int adc_main(int argc, char *argv[])
|
|||||||
|
|
||||||
adc_devpath(&g_adcstate, CONFIG_EXAMPLES_ADC_DEVPATH);
|
adc_devpath(&g_adcstate, CONFIG_EXAMPLES_ADC_DEVPATH);
|
||||||
|
|
||||||
|
g_adcstate.initialized = true;
|
||||||
|
}
|
||||||
|
|
||||||
#if CONFIG_EXAMPLES_ADC_NSAMPLES > 0
|
#if CONFIG_EXAMPLES_ADC_NSAMPLES > 0
|
||||||
g_adcstate.count = CONFIG_EXAMPLES_ADC_NSAMPLES;
|
g_adcstate.count = CONFIG_EXAMPLES_ADC_NSAMPLES;
|
||||||
#else
|
#else
|
||||||
g_adcstate.count = 1;
|
g_adcstate.count = 1;
|
||||||
#endif
|
#endif
|
||||||
g_adcstate.initialized = true;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Parse the command line */
|
/* Parse the command line */
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user