Setup:
ChibiOS version : 20.3.4
Compiler: arm-none-eabi-gcc 9.2.1
Platform: STM32G474 on a custom board.
Problem:
Using the DAC driver with an error callback configured results in me entering the error callback every time. Adding some breakpoints i can see that the DMA channel is reporting a bus error. Digging through the code and the Ref man i can see that in hal_dac_lld.c the DMA is configured to be half-word sized while the Ref man indicated that the access should be Word sized, section 22.7.
Looking through the forum i can see this thread where this problem is discussed. viewtopic.php?f=3&t=5122&start=20#p36415 but that changes appears to have been reverted to solve bug #1100 viewtopic.php?f=35&t=5529#p37873.
I have locally reverted that fix and the DAC is working as expected.
DMA to DAC peripheral causes DMA error on STM32G474 Topic is solved
-
- Posts: 2
- Joined: Sun Jan 23, 2022 5:19 pm
- Giovanni
- Site Admin
- Posts: 14444
- Joined: Wed May 27, 2009 8:48 am
- Location: Salerno, Italy
- Has thanked: 1074 times
- Been thanked: 921 times
- Contact:
Re: DMA to DAC peripheral causes DMA error on STM32G474
Hi,
Thanks for finding, the DAC driver needs a serious review.
Giovanni
Thanks for finding, the DAC driver needs a serious review.
Giovanni
- Giovanni
- Site Admin
- Posts: 14444
- Joined: Wed May 27, 2009 8:48 am
- Location: Salerno, Italy
- Has thanked: 1074 times
- Been thanked: 921 times
- Contact:
Re: DMA to DAC peripheral causes DMA error on STM32G474
Hi,
Reverted bug #1100, It broke the driver as you described.
Changes committed to trunk, 21.11.x, 20.3.x.
Giovanni
Reverted bug #1100, It broke the driver as you described.
Changes committed to trunk, 21.11.x, 20.3.x.
Giovanni
-
- Posts: 2
- Joined: Sun Jan 23, 2022 5:19 pm
Re: DMA to DAC peripheral causes DMA error on STM32G474
Thanks Giovanni.
Ill pick this up as soon as possible.
If the DAC driver is reworked in the future, i'm happy to test it on the STM32G474.
Ill pick this up as soon as possible.
If the DAC driver is reworked in the future, i'm happy to test it on the STM32G474.
Who is online
Users browsing this forum: No registered users and 9 guests