2024-01-08 08:56 AM - edited 2024-01-08 09:00 AM
I was unable to configure ADC1 to measure a "4 channel sequence" and then generate an interrupt.
I am using the injected result registers to read the values in the ISR.
Adc_Value[0]= ADC1->JDR1;
Adc_Value[1]= ADC1->JDR2;
Adc_Value[2]= ADC1->JDR3;
Adc_Value[3]= ADC1->JDR4;
All values show zero!
Can anyone provide an example code for reading injected results + interrupt?
Alternatively the DMA may be used, but when I try to use regular/non injected results via DMA, I am not able to generate an interrupt anymore!
The sequence is triggered by TIM1 at every 15.8 uS.
2024-01-16 12:21 PM
Is this configuration setting both regular and injected results?
But the regular conversion has only one result register!
Which result register do I read my 4 results from?
2024-01-16 12:44 PM
read again ... i edit -> start injected . :)
regular is set : disabled.