lwip-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[lwip-users] Problem with loading web-pages


From: Андрей Виноградов
Subject: [lwip-users] Problem with loading web-pages
Date: Tue, 20 Jul 2021 18:12:11 +0300

Hello!

I'm working on an embedded web-server. Web-browser (Chrome) can't get all needed files for opening a page. Some files he can obtain only after a second or third try. LwIP seems to be working fine, drivers too.
It looks like LwIP doesn't see or ignore browser file requests, if there are "too many" of them at the same time.

Browser screenshot:
https://drive.google.com/file/d/10Hp9MEY5ajJj9Bx_m1SDxUy5nKHm7KPE/view?usp=sharing

LwIP debug log:
https://docs.google.com/document/d/1ThkPlngDfR2Z_FePcTF2aETJ3b9KEKel6IlYSOj_w18/edit?usp=sharing

I don't know where to search for bottleneck. Which debug logs should I also enable and change LwIP options. Can you give me some clues on where to search for the bug?


BTW, some suggestions on debug prints:
tcp_debug_print_flags():
disable LWIP_DEBUGF(TCP_DEBUG, ("\n")) at the end, because debug log looks like this:
TCP header:
+-------------------------------+
|     7100      |       80      | (src port, dest port)
+-------------------------------+
|           2064295908          | (seq no)
+-------------------------------+
|           0000006957          | (ack no)
+-------------------------------+
|  5 |   |010000|     64240     | (hdrlen, flags (ACK    <---
 ), win)
+-------------------------------+
|    0xc50c     |         0     | (chksum, urgp)
+-------------------------------+

and next add \n here
#if TCP_INPUT_DEBUG
  LWIP_DEBUGF(TCP_INPUT_DEBUG, ("+-+-+-+-+-+-+-+-+-+-+-+-+-+- tcp_input: flags "));
  tcp_debug_print_flags(TCPH_FLAGS(tcphdr));
  LWIP_DEBUGF(TCP_INPUT_DEBUG, ("\n-+-+-+-+-+-+-+-+-+-+-+-+-+-+\n")); // <--- \n on both sides
#endif /* TCP_INPUT_DEBUG */


http.c:
LWIP_DEBUGF(HTTPD_DEBUG | LWIP_DBG_TRACE, ("Received GET request\"\n"));
Extra quotation mark. Probably should be just
LWIP_DEBUGF(HTTPD_DEBUG | LWIP_DBG_TRACE, ("Received GET request\n"));

Thx!

reply via email to

[Prev in Thread] Current Thread [Next in Thread]