Part Number: TMS570LS0432
Other Parts Discussed in Thread: HALCOGEN
Tool/software: TI C/C++ Compiler
Hello
When I use the timer interrupt to set the ADC sampling .timer 50us once.
code:
uint16_t Amplitude_value[COLLECT_POINTS];
interrupt function
{
adcStartConversion(adcREG1,adcGROUP1);
while((adcIsConversionComplete(adcREG1,adcGROUP1))==0);
adcGetData(adcREG1, adcGROUP1,&adc_data[0]);
Amplitude_value[AD_COUNT]=adc_data[0].value;
}
I found that this interrupt function sometimes responds more than 50us.so affect the effect.
please. Can I set it only sample the interrupt function ,and perform the ADC conversion function in the main program so that it will not affect the interrupt function.
Or there are other ways to reduce the code as in the interrupt function, but it must be sampled once every 50us.