2024-04-30 10:02 PM - edited 2024-05-01 01:47 AM
I have some problems getting all the information out of the manual.
Using HAL is no option.
There are a lot of questions (Question are all refering to "Injected simultaneous mode") that cant be answered, or details that are confusing:
- When in Injected simultaneous mode, regular conversions are possible, but use the settings of the common registers for dual settings?
- Picture "say what": It does not really say how it would behave in that case.
- With all the information i gathered, i can not really determine, how the ADC would work in combination with DMA. When i start regular conversions on ADC2, is it then considered dual mode?
It would be helpful to have a checklist, or a table, that show what has to be orcan be set in different modes. Is there such information availlable? Or anyone knows of a good tutorial?
2024-05-01 12:12 AM
>Using HAL is no option.
Why? Its just doing the setup , as you want it. The speed of ADC is always same - using HAL , or not.
>- When in Injected simultaneous mode, regular conversions are possible, but use the settings of the common registers for dual settings?
> - Picture "say what": It does not really say how it would behave in that case.
>- With all the information i gathered, i can not really determine, how the ADC would work in combination with DMA
Same way, as on other cpus , just more complex than on an old F103 (DMA + MDMA ),
maybe read the 120 pages of ADC in rm ... or use HAL for making it more easy.
>Or anyone knows of a good tutorial?
Did you check the app notes for the cpu you use ? (here G474 -> )
https://www.st.com/en/microcontrollers-microprocessors/stm32g474re.html#documentation
and general ADC ->
https://www.st.com/content/st_com/en/search.html#q=ADC-t=resources-page=1
2024-05-01 01:46 AM
HAL uses too much space, and i also need to understand how things work in order to have them doing exactly what i want.
You have posted a picture of the wrong mode. Yes, its confusing sometimes.
Thanks for your information, but i could not get the information that answers my questions.
I trying to make things simpler, by just using ADC2 regular, but things arent working anyway. Isnt there a checklist, for settings that must be setup with DMA? Those steps in the manual are just not sufficient. I have worked the first time with ADC and DMA before (Without HAL), but i cant combine them. But maybe i am just missing some hidden but yet important information.
2024-05-01 02:01 AM - edited 2024-05-01 02:38 AM
>HAL uses too much space
On a cpu with 512K flash (G474 ) the 10..20K for HAL are "too much" ? really ??
btw. You could also use the LL lib, needing about same space , as bare metal .
>Isnt there a checklist, for settings that must be setup with DMA?
I would use the HAL , to do the setup - even if you dont wanna use it in the end - but ,
just to look, how its doing the setup . Then you know, how to do it.
2024-05-01 03:14 AM
Why do you think i got the G474?
2024-05-01 03:27 AM - edited 2024-05-01 03:28 AM
Wrong - you didnt tell , which cpu you have, so cannot know.
I took just a G4 , i looked at and have ds and rm, as an example.
2024-05-01 08:20 AM
You should have asked then, and not written about assumptions.
Its a G431KBT6