MK22FN256 AtoD Single-ended and Differential Measurement (ADC1)

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

MK22FN256 AtoD Single-ended and Differential Measurement (ADC1)

542 Views
briancavanagh
Contributor III

Hi, I'm using ADC1 (MK22FN256) to make a Single-ended and Differential Measurement.

What's not clear to me is how to write code that will retrieve measurementss from Channel-0 (ADC1_SE5b) and Channel-1 (ADC1_DP0 and ADC1_DM0) separately. 

Initially, I added had two components from the 'Components Library' (ADC_LDD).  One for the single-ended and the other for the differential measurements.  I would always get an error message stating "A/D converter is already used by ..." 

After further researching on the support page I figured out I can use Channel-0 and Channel-1 using the same ADC1.

Can someone help me understand how to make a call to Channel-0 and Channel-1 separately?

Thanks,

Brian

 

pastedImage_1.png

pastedImage_2.png

0 Kudos
1 Reply

434 Views
Robin_Shen
NXP TechSupport
NXP TechSupport

Hi brian,

Please try to use the SelectSampleGroup function.

SelectSampleGroup.jpg

Best Regards,

Robin

 

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 Kudos