Hello, dear working staffs and others,
I'm currently using the MPC5748G DEVKIT and I want to convert the analog signal from the peripheral potentiometer. I've checked several examples, but they are all using the Potentiometer on the board (ADC0 CH9).
Thus, I want to ask about the possibility to include the analog signal in PG13 and convert the signal using ADC1
And if possible, how should I know the corresponding channel number since I want to enable the channel but I can't find the information about the channel number.
ADC_DRV_EnableChannel(INST_ADCONV1, ADC_CONV_CHAIN_NORMAL, ADC_CHAN_NUM);
Best regards,
Zhengkun
Solved! Go to Solution.
Hello,
Simply connect your analog signal to pin header J14 pin 1.
Next you need to check internal routing of ADCs: In this case it is channel35
as you can see from routing table:
Last thing you need to se it APC bit in SUIL unit for corresponding MCSR register. Which is in this case MCSR 109.
After setting this you are ready for measurement of PG[13] channel via ADC1 channel 35.
Best regards,
Peter
Thank you, this answer solved my problem perfectly
Hello,
Simply connect your analog signal to pin header J14 pin 1.
Next you need to check internal routing of ADCs: In this case it is channel35
as you can see from routing table:
Last thing you need to se it APC bit in SUIL unit for corresponding MCSR register. Which is in this case MCSR 109.
After setting this you are ready for measurement of PG[13] channel via ADC1 channel 35.
Best regards,
Peter
Thank you for your reply, now I got the ADC running.
But I still have some questions. According to the reference manual, the ADC1 should be a 12 bits ADC, but the conversion result I got is only 8 bits result. The input ranges from 0 volts to 3,3 volts.
Did I make the configuration wrong or the input voltage signal is not high enough? Could you please give me a hint?
Best regards!