2024-11-08 08:14 AM - edited 2024-11-08 08:14 AM
Hi All,
I want to read all ADC channels from the nucleo c031C6 using DMA all channels should be read continuously. For example 1k samples per seccond. I have tried to configure lots of different approaches in the CubeMX, but I can not figure it out.
Can anyone give me a hint on how to set ADC and DMA settings in CubeMX?
Cheers
2024-11-08 12:39 PM
Hello @stm32user2 and welcome to the community,
You need to show what you have done at this stage: share your code, your ioc file etc.. to let others guide you to the solution.
Tips on posting a thread.
Thank you.
2024-11-14 02:29 AM
Hello,
I am sending simple example which periodically (1kHz) read all analog inputs and each values writes to memory by DMA and periodically print read values from memory to usart.
ADC was configured:
- All inputs except IN2, IN3 (pins used by usart), Temperature sensor, Vrefint Channel, VDDA Channel, VSSA Channel
- 8 bit resolution
- DMA Continuous Requests Enabled
- External trigger conversion source as Timer 3 Trigger Out event
- Other configurations stay as defaults
- DMA mode circular, Peripheral to memory, Data Width as Byte
TIM3 is configured as:
- Clock Source as Internal Clock
- Counter Period to 47 999
- Trigger Event Selection TRGO as Update Event
SYSCLK was configured to 48 MHz
To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.