[lwip-users] MEM_SIZE seems to small for TCP_MSS, PBUF_POOL_BUFSIZE

2018-04-27 Thread Sebastian Gniazdowski
Hello,
I'm using STMicroelectronics's CubeMX which generates RTOS+LwIP code. I
have following in opt.h:

#define MEM_SIZE  2000
#define TCP_MSS   536
#define TCP_SND_BUF  (2 * TCP_MSS)
#define TCP_SND_QUEUELEN  9
#define PBUF_POOL_SIZE16
#define PBUF_POOL_BUFSIZE TCP_MSS+40+0+14+4-1 // tailored this formula, 593
and then align

It looks like:

a) 16 * 593 = 9488 is way bigger than 2000
b) 2 * TCP_MSS * 9 = 9648 is also bigger than 2000

I'm concerned especially about pbuf pool. It looks like a plainly
preallocated thing, pool size times pool element size, thats all – 9.2 kB
of memory to be used. Send buffer and queue looks similar. Am I right and
MEM_SIZE should be bigger?

-- 
Best regards,
Sebastian Gniazdowski
___
lwip-users mailing list
lwip-users@nongnu.org
https://lists.nongnu.org/mailman/listinfo/lwip-users

[lwip-users] Transition to CMake?

2018-04-27 Thread Dirk Ziegelmeier
Hello all,

those who watch the lwIP commits have noticed I started working on a CMake
based build system.

My question is: Is there an interest in the old Makefile-based system? I'm
currently tempted to throw it away :-) I'd just keep the Filelists.mk files
for people with Makefile build systems.

The *far* goal would be to also unify the UNIX and Win32 applications.
CMake will automatically detect the build host and pull in the appropriate
port (Unix/Win32). The netif selection also needs to be per platform, UNIX
uses tapif/tunif and Windows uses pcap.
So the next question is: Who cares about simhost/minimal/lib/check project
in the unix port? Are they important for someone? I'd say we throw them
away and clean up the windows application some more. Currently Simon
maintains the Win32 app and I care about the simhost unix app. They
basically do the same, so this is a waste of time.

Please guys give us some feedback on this!

Dirk
___
lwip-users mailing list
lwip-users@nongnu.org
https://lists.nongnu.org/mailman/listinfo/lwip-users

[lwip-users] lwip PPPoS + ESP8266 wifi module

2018-04-27 Thread Andrea Marangon

Hi everyone,
I'm using lwip on the ESP8266 wifi module.
This module is connected to my card and communicates via PPPos (the PPP 
client is the Wifi module).

Now I need to receive and transmit TCP and UDP packets via Wifi.

Initially I created two TCP sockets (netconn), one client and the other 
server forwarding the data via buffers, but it is very expensive in time 
and memory.
I have doubts about this implementation considering that I will have to 
do the same with the UDP transmission.



Board(10.11.12.13) --> PPPoS --> netconn TCP client(10.11.12.13) --> 
netconn TCP server(172.16.0.1) --> mobile system (172.16.0.2)



I thought of using the network interfaces (netif, one the PPPoS and the 
other the WiFi) to do a kind of forwarding...

could this be the right way? Can the UDP part coexist?
Do you have any suggestions?

Thanks in advance

Andrea


___
lwip-users mailing list
lwip-users@nongnu.org
https://lists.nongnu.org/mailman/listinfo/lwip-users