STM32H725 ADC3 DMA
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
2021-09-30 11:17 PM
I read the adc value using ADC3 + DMA using STM32H725.
ADC3 channel 0,1,10,11 are reading adc value.
1) ADC3 + DMA1 : RAM 0x24000000 ~ 0x2401FFFF
2) ADC3 + BDMA : Allocate an array to store adc values to SRAM4.
In all experiments, the correct value does not come out, but 0 or a very large value comes out, and even if the power of the corresponding channel is cut off, a strange value comes out...
What more should I consider and test?
The structure of H7 is complicated, so there are too many things that I don't understand because of my short knowledge... Please explain in detail.
- Labels:
-
ADC
-
DMA
-
STM32H7 Series
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
2021-10-01 8:24 AM
If the value is getting populated, the DMA is probably putting it there, barring any rogue out of bounds accesses.
Get the ADC working in blocking mode first. Plenty of examples to go off of.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
2021-10-03 6:11 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
2021-10-04 8:51 AM
Hi @ssooki ,
Some explanation of DMA weird behavior with STM32H7 in this article: DMA is not working on STM32H7 devices.
-Amel
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.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
2021-10-12 3:17 AM
Hello @ssooki ,
For the setup "ADC3 + DMA1": Can you start from an example of FW package, for example:
...\Firmware\Projects\NUCLEO-H743ZI\Examples\ADC\ADC_DMA_Transfer
with modifications:
- update debugger for your target STM32H725
- in file main.h: replace instance ADC1 by ADC3, "..._ADC12_..." by "..._ADC3_..."
- in file msp.c: replace DMA_REQUEST_ADC1 by DMA_REQUEST_ADC3
Best regards
Philippe
