Continuous ADC with DMA on NUCLEO-F446RE board not working #89175
-
Describe the bug To Reproduce
Expected behavior Environment
|
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
Unfortunately, continuous sampling on Zephyr is currently not supported for STM32 driver. I don't think there is even the possibility to enable the option using the Zephyr API. As a partial workaround, you could use |
Beta Was this translation helpful? Give feedback.
-
I've converted the issue to discussion as this feature is not yet available through Zephyr API. |
Beta Was this translation helpful? Give feedback.
Unfortunately, continuous sampling on Zephyr is currently not supported for STM32 driver. I don't think there is even the possibility to enable the option using the Zephyr API.
I'm not sure of the behavior of your code, using a mix of driver function and direct call is risky. The driver may rewrite some registers in the interrupts resulting in strange behavior.
As a partial workaround, you could use
extra_samplings
to sample up to 65536 values at a time. You'll still have to relaunch a read sequence every now and then, but it is at least much less frequent. You can see examples of how it is used intests/drivers/adc/adc_api/src/test_adc.c