|
From: | Osborne, David |
Subject: | [lwip-users] Why does enabling Debug fix this tcp_sndbuf() |
Date: | Wed, 24 Mar 2021 15:32:40 +0000 |
Hi All, I’m using LwIP + FreeRTOS + Sockets on STM32H7 with external SDRAM and FLASH (Ethernet buffers are internal). It works well until the server has to send a very large message (> 18Kbytes). One in five attempts ends in failure. During
the transmission tcp_sndbuf() (in api_msg.c) returns zero and the connection falls over. From what I’ve read, a common cause is that it’s waiting for an outstanding ACK. I’m no expert, but it looks like the ACK has been sent (see Wireshark attachment). When I enable certain debug settings it works every time (don’t you hate that). #define
TCP_DEBUG LWIP_DBG_ON #define
TCP_OUTPUT_DEBUG LWIP_DBG_ON It has to be both debugs settings (just one doesn’t fix it). Is there any TCP experts out there who can tell me why tcp_sndbuf() is returning 0 and the client is retransmitting (when debug is off)?
Regards David |
failed_exchange.pcapng
Description: failed_exchange.pcapng
[Prev in Thread] | Current Thread | [Next in Thread] |