Confusion with SAR ADC for MPC574xR

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Confusion with SAR ADC for MPC574xR

845 Views
raghurajappa
Contributor IV

While looking through the SDK code, I am quite often getting confused with the usage of terms. This is also because, my knowledge of ADC is limited. 

  1. What is the difference between "group" and "chain" in terms of ADC? I see code with "Normal conversion chain" which is used for a single channel (why the keyword chain if it's only for a single channel?) and then I see code with "configure normal chain" where the configuration includes a group of channels that can be configured and used as a group. 
  2. What is the difference between "SW triggered" and "Injected mode"? I assume injected mode can be sw or hardware triggered. But I am not sure of this answer.
  3. I also want to clarify my understanding of the ADC structure so far. There are 4 SAR ADC Instances for the microcontroller. Each ADC instance can consist of upto 96 channels (not sure). These 96 channels can be grouped into three group (0-31, 32-63, 64-95)? Each individual channel or a group of channels can be used in a single shot conversion or continuous conversion mode. If it's a single shot conversion, this can be triggered either through SW, HW (CTU, BCTU, external, etc). The conversion can be monitored either by polling or through the interrupt flag. 
  4. If I configure a group of channels to be converted, is there a drop in performance as compared to triggered each channel to convert? I assume the answer is that a group conversion is faster than individual channels (of same number) because the multiplexing is hardware driven with little to no overhead. Please correct me if this understanding is wrong. 

Thank you for your time and effort. :smileyhappy:

Labels (1)
1 Reply

707 Views
petervlna
NXP TechSupport
NXP TechSupport

Hello,

What is the difference between "group" and "chain" in terms of ADC? I see code with "Normal conversion chain" which is used for a single channel (why the keyword chain if it's only for a single channel?) and then I see code with "configure normal chain" where the configuration includes a group of channels that can be configured and used as a group. 

pastedImage_3.png

Group is a term for channels concentrated in group (usually in some configuration interface like S32 or MCAL)

Chain is a chain conversion of enabled channels for ADC conversion.

why the keyword chain if it's only for a single channel?

I expect that is for unification of terms. But, yes, it is weird.

What is the difference between "SW triggered" and "Injected mode"? I assume injected mode can be sw or hardware triggered. But I am not sure of this answer.

SW triggered - Is conversion triggered by SW and it waits for ongoing conversion to complete.

Injected - interrupt ongoing conversion and convert injected channel data. Once it is done then interrupted conversion is continuing.

I also want to clarify my understanding of the ADC structure so far. There are 4 SAR ADC Instances for the microcontroller. Each ADC instance can consist of up to 96 channels (not sure).

Four separate 12 bit SAR analog converters with following channels:

pastedImage_17.png

These 96 channels can be grouped into three group (0-31, 32-63, 64-95)?

Actually they are in 4 groups as table 35-2 represents and SARADC3 also have multiplexed channels.

Refer to table Table 35-3.  SAR ADC channel map i n reference manual.

If I configure a group of channels to be converted, is there a drop in performance as compared to triggered each channel to convert? I assume the answer is that a group conversion is faster than individual channels (of same number) because the multiplexing is hardware driven with little to no overhead. Please correct me if this understanding is wrong. 

Yes, the group channel conversion is faster than multiple single shot conversions of same channels.

regards,

Peter