|
|
|
|
@ -2271,6 +2271,8 @@ void init_adc()
|
|
|
|
|
|
|
|
|
|
void read_adc_process(int sig_num)
|
|
|
|
|
{
|
|
|
|
|
fprintf(stderr,"read_adc_process starting\n");
|
|
|
|
|
|
|
|
|
|
if(sig_num == SIGALRM)
|
|
|
|
|
{
|
|
|
|
|
// read ADC
|
|
|
|
|
@ -2289,7 +2291,7 @@ void read_adc_process(int sig_num)
|
|
|
|
|
adc_buffer[wav_position] = data[0];
|
|
|
|
|
|
|
|
|
|
// Output data to screen
|
|
|
|
|
printf("Digital value of analog input: %d in %d us\n", data[0], micros() - time_start); // millis() - time_start);
|
|
|
|
|
fprintf(stderr, "Digital value of analog input: %d in %d us\n", data[0], micros() - time_start); // millis() - time_start);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
wav_position++;
|
|
|
|
|
|