Skip to main content
MÇeli.2
Associate II
June 6, 2022
Solved

Nucleo-F072RB Multi-channel ADC Problem

  • June 6, 2022
  • 4 replies
  • 2255 views

Hello. I want to read multi-channel analog data (four channels) with my Nucleo-F072RB. I previously worked with Nucleo F411RE and I did not have any problems. But with F072RB, I'm so confused. When I open my board on CubeMX, I can select multi ADC1 channels (for example IN1, IN2..) but in ADC configuration I can not see "Number of Conversions" or "Rank" properties. So I can not configure the multichannel ADC. I thought maybe this board had only one configuration and so it had not allowed configuring ADCs...But when I coded two potentiometer ADC reading codes, I saw it was not working. Can you help me with this problem? Thanks in advance.

This topic has been closed for replies.
Best answer by KiptonM

I just got a similar issue in my question. It may be the same issue.

It is a known issue with the MX program, they are working to fix it.

The suggestion that worked for me was to deselect all the ADC pins.

Then I generated code. And got out of the IDE.

I restarted the IDE, and and reconfigured the ADC like before. And it worked this time.

See my question "In CubeMX program for the ADC I want 4 ADC channels, but the MX program only lets me enter data for 3. How do I put in data for Rank 1?"

Hope it helps.

4 replies

gbm
Super User
June 6, 2022

AFAIK, the F0 series Reference Manual is available. Just read it - the ADC section.

My STM32 stuff on github - compact USB device stack and more: https://github.com/gbm-ii/gbmUSBdevice
MÇeli.2
MÇeli.2Author
Associate II
June 6, 2022

Thank you for your cute answer but it is not in Reference Manuel, it is about CubeMX Parameter Settings of ADC. In the picture below you can see Nucleo-F411RE ADC parameter settings when choosing multichannel ADC.

0693W00000NrGBmQAN.pngBut when you use Nucleo-F072 board, you can not choose "Number of Conversion" and "Rank". Is it normal or caused by CubeMX error?

0693W00000NrGBrQAN.png

KiptonM
KiptonMBest answer
Senior III
June 6, 2022

I just got a similar issue in my question. It may be the same issue.

It is a known issue with the MX program, they are working to fix it.

The suggestion that worked for me was to deselect all the ADC pins.

Then I generated code. And got out of the IDE.

I restarted the IDE, and and reconfigured the ADC like before. And it worked this time.

See my question "In CubeMX program for the ADC I want 4 ADC channels, but the MX program only lets me enter data for 3. How do I put in data for Rank 1?"

Hope it helps.

MÇeli.2
MÇeli.2Author
Associate II
July 22, 2022

Thank you KiptonM! It worked!