AnsweredAssumed Answered

SPC560D40L1 - ADC does not finish sampling

Question asked by StefanP on Apr 3, 2014
Latest reply on Apr 10, 2014 by Erwan Y
I'm trying to setup an analog conversion on SPC560D40L1. I activated the ADC in HAL configuration, defined a adc-conversion-group that consists of channel 0 (ADC1_P[0] on Pin PB4).

The ADC does not finish the sample. The ADCD2 state is ADC_ACTIVE and the ADC_MSR.ADCSTATUS is 0x4(Sample). The values in the buffer stay unchanged.

My Settings for the conversion group "Precision":
- Linear, Max Sequential: 4
- Watchdog functions are all disabled
- Channel Settings: Inital: 0, Number of channels: 1
- Timing: CTR0_INPLATCH = 1, OFFSHIFT = 0, INPCMP = 2, INPSAMP = 9, CTR1,2 the same
- No callbacks are used

In the eDMA_MUX_Settings, ADC uses DMA2.

My Programm looks like this:

int main(void)
    uint16_t adcBuffer[4];
    adcStart(&ADCD2, NULL);
    adcStartConversion(&ADCD2, &adc1_group_precision, &adcBuffer[0], 4);

The registers of ADC and eDMA seems to be right, the Clock Settings should be right, I can't find register ME_PCLT33 in the PLS-Debugger (32 and 44 are there).

Thanks for help.

By the way, ADC-Channel 44 can not be selected in the Conversion Group Setup.