1

I have a STM 32F microcontroller which is connected to a X3399 core board via UART. Every 400 ms I`m sending a keep alive message from the micro controller to the board, once in a while, asynchronously, the keep alive message is not received on the processor side.

This phenomenon only happens when another specific process is running and not when this process is the only one that running. Maybe someone has an idea what should I check?

Maybe a memory override where the messages coming from the UART are stored by the corresponding process?

Mike
  • 4,041
  • 6
  • 20
  • 37
  • Check the UART for overrun errors. If the other processes somehow prevent the UART from being read for a period that is longer than the inter-character delay of the port then the UART may be overrunning (i.e., dropping a character) resulting in an incorrect message being received. – kkrambo Sep 12 '18 at 12:10
  • How can I check for UART overrun errors? – NimbleAlgoS Sep 12 '18 at 12:25
  • Depends on the exact device you're using - it would pay to be more specific in your question. But for example on the STM32F407, receive overrun detection is via bit 3 (ORE) of the USART status register. – cooperised Sep 12 '18 at 14:55
  • It would also be really helpful to know what operating system you're using. This has all the hallmarks of a timing bug, but without knowing more about your setup it's hard to know how to help. – cooperised Sep 12 '18 at 14:55
  • Im working with STM32F303vct and on the X3399 Im working with Ubuntu 16.04.4 LTS. – NimbleAlgoS Sep 13 '18 at 07:22
  • I would like to add that these are messages sent **from** the STM to the X3399 – NimbleAlgoS Sep 13 '18 at 08:33
  • I've figured out the source of the problem. When I use guvcview and show the my usb camera in MJPG instead of the default YUYV format I don't miss the messages anymore, at any other non compressed format messages are missed again. What could be the reason, if the messages are transmitted via UART and the camera via USB? – NimbleAlgoS Sep 16 '18 at 11:37

0 Answers0