ADC External Channels Usage in MPC746C

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

ADC External Channels Usage in MPC746C

984 Views
kavithakakarla
Contributor II

For MPC5746C, I would like to know how to use the external channels of ADC with an example code.

I understand 4 External MUX (ADCn_X[0],ADCn_X[1], ADCn_X[2], ADCn_X[3]) can be used with this and 3 select lines MA[0], MA[1], MA[2] are used to toggle the outputs.

But I would like to have some example code explaining how the external channels to be configured and how to read the Converted Data from the ADC_CDRn register after changing the select lines.

0 Kudos
1 Reply

726 Views
davidtosenovjan
NXP TechSupport
NXP TechSupport

Hi, ADCn_MA[n] are outputs and these are control signals for external multiplexer if used. For illustration, see picture below showing its connection. Please be aware it is related to different device and different sort of ADC module, but principle of external multiplexer connection is basically the same.

 pastedImage_1.png

Documentation of MPC5748G is not too much descriptive in this case but the feature is there as there are some mentions:

1) Section 32.4 Features

  • external channels:
  • 64 to 95 (ADC0—10 bit)
  • 64 to 95 (ADC1—12 bit)
  • External decode signals available for (8 × 1) configuration (external channels only)

 

2) 32.5.31 Decode Signals Delay Register (ADCx_DSDR)

 

3) Section 32.6.8 External Decode signals Delay

The ADC provides three external decode signals to be used to select one channel out of eight channels in external Analog multiplexers. There can be a maximum of four such multiplexers that are used for the 32 external channels to be converted. In order to take into account the control of switching time of the external analog mux, a Decode Signals Delay (DSD) register is provided. This register allows you to program the delay between the decoding signal selection and the actual start of conversion.

If presampling is enabled then the DSD delay starts after the presample phase (presampling time is same as sample time).

 

To sum it up:

If you configures mentioned ADC pins for ADCn_MA[n] functionality and converted channel is 64 to 95, ADCn_MA[n] acts as control signal for external multiplexer.

 

One yet note, general example for ADC conversion you may find here, section 2.8:

http://www.nxp.com/assets/documents/data/en/application-notes/AN4830.pdf

Hope it helps a bit

0 Kudos