2024-05-28 06:28 AM
I am using the Nucleo-STM32H723ZG board and I'm trying to set up a maximally reactive UDP/TCP communication channel between the board and an external node.
Just to use a common ground, lets take as an example project the LwIP_UDP_EchoServer.
If I send a message to the board and monitor the time it takes to receive the reply, it's over 1 millisecond. I tried to isolate the slow part and couldn't find it: I inserted a pin toggle inside the udp_echoserver_receive_callback, at the start and at the end; the time it takes to execute this function is around 11 microseconds. Nevertheless, the delay between the request and the echo reply, in wireshark, is more than 1 millisecond.
I followed the function calls down to the HAL_ETH_Transmit and couldn't understand what may cause this long delay. It is a blocking function and my understanding is that HAL_ETH_Transmit returns when the DMA has finished transmitting the data.
Could you please provide any hint about what may cause this delay and what may be the possible solutions?
Any input on this issue would be greatly appreciated.
Solved! Go to Solution.
2024-05-31 09:35 AM
Hello @ioncasu ,
This Delay can be caused by a variety of external factors (cable, node, switch ...) so it could be that you are only seeing this delay because of a bottleneck somewhere external to the Board as you confirmed that "the time it takes to execute this function is around 11 microseconds".
you can check this related thread to help you understand this better.
Regards
2024-05-31 09:35 AM
Hello @ioncasu ,
This Delay can be caused by a variety of external factors (cable, node, switch ...) so it could be that you are only seeing this delay because of a bottleneck somewhere external to the Board as you confirmed that "the time it takes to execute this function is around 11 microseconds".
you can check this related thread to help you understand this better.
Regards
2024-07-01 11:46 PM
Thanks for the input.
It was the Windows OS.
I measured the data exchange delay using PHY signals, and it was indeed around 13 microseconds.