Analog input ADC, STM32F103, newbie question
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2015-06-10 5:00 PM
Posted on June 11, 2015 at 02:00
hello,
I'm discovering how the analog works input in STM32F103. There is something I still didn't find in the datasheet. I understood all the mode and register configuration, but where is the information to know with wich port is linked to wich ADCx? For exemple, I need to fullfil the ADCx->SQRx with each number channel I want convert. But where can I find the information that ADCx_INx is Portx? Is ADC1 is ¨PORTA and ADC2 is PORTB? Thanks,
This discussion is locked. Please start a new topic to ask your question.
4 REPLIES 4
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2015-06-10 5:36 PM
Posted on June 11, 2015 at 02:36
In the datasheet you look for things like ADC123_IN8 or ADC3_IN9, I made those up, the ADC digits would refer to which units they work on, INx is the channel#
Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
Up vote any posts that you find helpful, it shows what's working..
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2015-06-10 6:25 PM
Posted on June 11, 2015 at 03:25
hello,
I'm sorry but I do not understand you. I have the STM32F103 LQFP64 pins. So I have ADC1 and ADC2 and physically, I have pins PAx, PBx (x=0-15) You said ''the ADC digits would refer to which units they work on, INx is the channel#'' I'm ok about that, but for example IN3 is which physically pin (and which ADC)? or with another words, when I configure : GPIOA->CRL to have PA0 as analog input, how I know which ADCx and which INx channel is? I miss something easy and surely trivial but that's what I don't understand. Can you help me to make clear my mind? ThanksOptions
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2015-06-10 9:46 PM
Posted on June 11, 2015 at 06:46 I finnaly got it. It's in device datasheet, there is alternative name on some pin where we can find the ADCxINx pin. I knew that it was silly question, sorry.
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2015-06-11 6:07 AM
Posted on June 11, 2015 at 15:07 Incidentally, ''ADC123_INx'' means that a pin can be connected to any of the the three ADCs, ADC12_INx means that the pin can connect to ADC1 and / or ADC2, but not ADC3. Similarly, ADC3_INx connects only to ADC3.
