How do I find out the pin and channel correspondence on the Due? I have looked through the "component_adc" file as well as the datasheet, but cannot seem to find this information. I want to know how to enable A10 and A11. I have seen commonly that A0 enable requires us to write code to enable Ch7, i.e,
ADC->ADC_CHER = ADC_CHER_CH7
How to do similarly for other Channels from A1 (Ch6) to A15?
Just try and use 10 or 11 with an analogRead call.
Thank you for replying. I used it that way for simpler tasks and that was alright, but I want to activate only certain lines and work with those. 1 way I could think of doing this was write the binary bit to the entire set of registers like writing
ADC->ADC_CHER = 0x3CFF, but I would still like to know where to find this information about channel mapping.
That is not how code works, if you don’t want to work with a line don’t include it in your code. It only activates when you use it.
I see, I have looked at this pinout diagram many times, but I did not realize that those signified the channel numbers ADx. Thank you very much! Just what I needed to know!
This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.