0
\$\begingroup\$

I've currently got a STM32F777VI microcontroller working with UART receive working through DMA. The problem starts when I try to receive data from 2 UART peripherals using DMA. According to the datasheet it should be possible to have 2 stream concurrently running on 1 DMA as long as you don't have channel overlap, which I checked and don't have.

When I try this only 1 of the UART peripheral work and the other call doesn't do anything even though the second call to HAL_UART_Receive_DMA(), with the respective buffer and uart handler, returns HAL_OK

What am I missing here?

edit: Now I'm getting HAL_ERROR on the second call if I let the debugger run instead of going through step by step, which makes it hard to debug.

\$\endgroup\$
  • \$\begingroup\$ It works just fine for me. I don't use HAL though. \$\endgroup\$ – DKNguyen Mar 18 at 21:46
  • \$\begingroup\$ Have you confirmed that each UART works independently? One of them might just be set up wrong and if you only ever tried to run both at the same time and it is always the same one that doesn't work. \$\endgroup\$ – DKNguyen Mar 19 at 1:27
  • 1
    \$\begingroup\$ It turns out it was the UART pin not being connected to the PCB after a ultrasonic bath and has nothing to do with the software. \$\endgroup\$ – Tryphon Mar 19 at 16:24
  • \$\begingroup\$ I was looking at an ultrasonic bath for work. Which one are you using? \$\endgroup\$ – DKNguyen Mar 19 at 18:14
  • \$\begingroup\$ @Toor I haven't really used it enough to recommend it to anyone to be honest. It's some generic cheap one at my work. Although this kind of talk doesn't belong here, I also noticed there is no option for private messaging. \$\endgroup\$ – Tryphon Mar 25 at 17:16

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.