2016-08-17 11:08:22 -04:00
|
|
|
menu "LWIP"
|
|
|
|
|
2016-11-16 03:24:41 -05:00
|
|
|
config L2_TO_L3_COPY
|
|
|
|
bool "Enable copy between Layer2 and Layer3 packets"
|
2017-03-01 00:37:36 -05:00
|
|
|
default n
|
2016-11-16 03:24:41 -05:00
|
|
|
help
|
2016-11-16 21:22:20 -05:00
|
|
|
If this feature is enabled, all traffic from layer2(WIFI Driver) will be
|
|
|
|
copied to a new buffer before sending it to layer3(LWIP stack), freeing
|
|
|
|
the layer2 buffer.
|
|
|
|
Please be notified that the total layer2 receiving buffer is fixed and
|
|
|
|
ESP32 currently supports 25 layer2 receiving buffer, when layer2 buffer
|
|
|
|
runs out of memory, then the incoming packets will be dropped in hardware.
|
|
|
|
The layer3 buffer is allocated from the heap, so the total layer3 receiving
|
|
|
|
buffer depends on the available heap size, when heap runs out of memory,
|
|
|
|
no copy will be sent to layer3 and packet will be dropped in layer2.
|
|
|
|
Please make sure you fully understand the impact of this feature before
|
|
|
|
enabling it.
|
2016-11-16 03:24:41 -05:00
|
|
|
|
2016-08-17 11:08:22 -04:00
|
|
|
config LWIP_MAX_SOCKETS
|
2016-10-28 01:35:06 -04:00
|
|
|
int "Max number of open sockets"
|
2017-02-27 01:47:48 -05:00
|
|
|
range 1 32
|
2016-11-29 03:25:17 -05:00
|
|
|
default 10
|
2016-09-28 01:24:58 -04:00
|
|
|
help
|
|
|
|
Sockets take up a certain amount of memory, and allowing fewer
|
|
|
|
sockets to be open at the same time conserves memory. Specify
|
2016-10-28 01:35:06 -04:00
|
|
|
the maximum amount of sockets here. The valid value is from 1
|
|
|
|
to 16.
|
2016-08-17 11:08:22 -04:00
|
|
|
|
2016-08-24 01:29:06 -04:00
|
|
|
config LWIP_THREAD_LOCAL_STORAGE_INDEX
|
2016-09-28 01:24:58 -04:00
|
|
|
int "Index for thread-local-storage pointer for lwip"
|
|
|
|
default 0
|
|
|
|
help
|
|
|
|
Specify the thread-local-storage-pointer index for lwip
|
|
|
|
use.
|
2016-08-24 01:29:06 -04:00
|
|
|
|
2016-09-20 03:36:55 -04:00
|
|
|
config LWIP_SO_REUSE
|
2016-09-28 01:24:58 -04:00
|
|
|
bool "Enable SO_REUSEADDR option"
|
2017-03-01 00:37:36 -05:00
|
|
|
default n
|
2016-09-28 01:24:58 -04:00
|
|
|
help
|
|
|
|
Enabling this option allows binding to a port which remains in
|
|
|
|
TIME_WAIT.
|
2016-09-20 03:36:55 -04:00
|
|
|
|
2017-01-05 06:17:52 -05:00
|
|
|
config LWIP_SO_RCVBUF
|
|
|
|
bool "Enable SO_RCVBUF option"
|
2017-03-01 00:37:36 -05:00
|
|
|
default n
|
2017-01-05 06:17:52 -05:00
|
|
|
help
|
|
|
|
Enabling this option allows checking for available data on a netconn.
|
|
|
|
|
2016-11-03 00:46:46 -04:00
|
|
|
config LWIP_DHCP_MAX_NTP_SERVERS
|
2017-01-17 04:44:25 -05:00
|
|
|
int "Maximum number of NTP servers"
|
|
|
|
default 1
|
|
|
|
range 1 16
|
|
|
|
help
|
|
|
|
Set maximum number of NTP servers used by LwIP SNTP module.
|
|
|
|
First argument of sntp_setserver/sntp_setservername functions
|
|
|
|
is limited to this value.
|
2016-11-03 00:46:46 -04:00
|
|
|
|
2016-12-26 02:47:20 -05:00
|
|
|
config LWIP_IP_FRAG
|
|
|
|
bool "Enable fragment outgoing IP packets"
|
2017-03-01 00:37:36 -05:00
|
|
|
default n
|
2017-01-17 04:44:25 -05:00
|
|
|
help
|
2016-12-26 02:47:20 -05:00
|
|
|
Enabling this option allows fragmenting outgoing IP packets if their size
|
|
|
|
exceeds MTU.
|
|
|
|
|
|
|
|
config LWIP_IP_REASSEMBLY
|
|
|
|
bool "Enable reassembly incoming fragmented IP packets"
|
2017-03-01 00:37:36 -05:00
|
|
|
default n
|
2017-01-17 04:44:25 -05:00
|
|
|
help
|
2016-12-26 02:47:20 -05:00
|
|
|
Enabling this option allows reassemblying incoming fragmented IP packets.
|
|
|
|
|
2017-06-22 03:14:21 -04:00
|
|
|
menu "TCP"
|
|
|
|
|
2017-01-17 04:44:25 -05:00
|
|
|
config TCP_MAXRTX
|
|
|
|
int "Maximum number of retransmissions of data segments"
|
|
|
|
default 12
|
|
|
|
range 3 12
|
|
|
|
help
|
|
|
|
Set maximum number of retransmissions of data segments.
|
|
|
|
|
|
|
|
config TCP_SYNMAXRTX
|
|
|
|
int "Maximum number of retransmissions of SYN segments"
|
|
|
|
default 6
|
|
|
|
range 3 12
|
|
|
|
help
|
|
|
|
Set maximum number of retransmissions of SYN segments.
|
|
|
|
|
2017-06-22 03:14:21 -04:00
|
|
|
config TCP_MSS
|
|
|
|
int "Maximum Segment Size (MSS)"
|
|
|
|
default 1436
|
|
|
|
range 1220 1436
|
|
|
|
help
|
|
|
|
Set maximum segment size for TCP transmission.
|
|
|
|
|
|
|
|
Can be set lower to save RAM, the default value 1436 will give best throughput.
|
|
|
|
|
2017-07-09 06:42:37 -04:00
|
|
|
config TCP_MSL
|
|
|
|
int "Maximum segment lifetime (MSL)"
|
|
|
|
default 60000
|
|
|
|
help
|
|
|
|
Set maximum segment lifetime in in milliseconds.
|
|
|
|
|
2017-06-22 03:14:21 -04:00
|
|
|
config TCP_SND_BUF_DEFAULT
|
|
|
|
int "Default send buffer size"
|
|
|
|
default 5744 # 4 * default MSS
|
|
|
|
range 2440 65535
|
|
|
|
help
|
|
|
|
Set default send buffer size for new TCP sockets.
|
|
|
|
|
|
|
|
Per-socket send buffer size can be changed at runtime
|
|
|
|
with lwip_setsockopt(s, TCP_SNDBUF, ...).
|
|
|
|
|
|
|
|
This value must be at least 2x the MSS size, and the default
|
|
|
|
is 4x the default MSS size.
|
|
|
|
|
|
|
|
Setting a smaller default SNDBUF size can save some RAM, but
|
|
|
|
will decrease performance.
|
|
|
|
|
|
|
|
config TCP_WND_DEFAULT
|
|
|
|
int "Default receive window size"
|
|
|
|
default 5744 # 4 * default MSS
|
|
|
|
range 2440 65535
|
|
|
|
help
|
|
|
|
Set default TCP receive window size for new TCP sockets.
|
|
|
|
|
|
|
|
Per-socket receive window size can be changed at runtime
|
|
|
|
with lwip_setsockopt(s, TCP_WINDOW, ...).
|
|
|
|
|
|
|
|
Setting a smaller default receive window size can save some RAM,
|
|
|
|
but will significantly decrease performance.
|
|
|
|
|
2017-07-24 21:13:01 -04:00
|
|
|
config TCP_RECVMBOX_SIZE
|
|
|
|
int "Default TCP receive mail box size"
|
|
|
|
default 6
|
|
|
|
range 6 32
|
|
|
|
help
|
|
|
|
Set TCP receive mail box size. Generally bigger value means higher throughput
|
|
|
|
but more memory. The recommended value is: TCP_WND_DEFAULT/TCP_MSS + 2, e.g. if
|
|
|
|
TCP_WND_DEFAULT=14360, TCP_MSS=1436, then the recommended receive mail box size is
|
|
|
|
(14360/1436 + 2) = 12.
|
|
|
|
|
|
|
|
TCP receive mail box is a per socket mail box, when the application receives packets
|
|
|
|
from TCP socket, LWIP core firstly posts the packets to TCP receive mail box and the
|
|
|
|
application then fetches the packets from mail box. It means LWIP can caches maximum
|
|
|
|
TCP_RECCVMBOX_SIZE packets for each TCP socket, so the maximum possible cached TCP packets
|
|
|
|
for all TCP sockets is TCP_RECCVMBOX_SIZE multiples the maximum TCP socket number. In other
|
|
|
|
words, the bigger TCP_RECVMBOX_SIZE means more memory.
|
|
|
|
On the other hand, if the receiv mail box is too small, the mail box may be full. If the
|
|
|
|
mail box is full, the LWIP drops the packets. So generally we need to make sure the TCP
|
|
|
|
receive mail box is big enough to avoid packet drop between LWIP core and application.
|
|
|
|
|
2017-06-22 03:14:21 -04:00
|
|
|
config TCP_QUEUE_OOSEQ
|
|
|
|
bool "Queue incoming out-of-order segments"
|
|
|
|
default y
|
|
|
|
help
|
|
|
|
Queue incoming out-of-order segments for later use.
|
|
|
|
|
|
|
|
Disable this option to save some RAM during TCP sessions, at the expense
|
|
|
|
of increased retransmissions if segments arrive out of order.
|
|
|
|
|
|
|
|
choice TCP_OVERSIZE
|
|
|
|
prompt "Pre-allocate transmit PBUF size"
|
|
|
|
default TCP_OVERSIZE_MSS
|
|
|
|
help
|
|
|
|
Allows enabling "oversize" allocation of TCP transmission pbufs ahead of time,
|
|
|
|
which can reduce the length of pbuf chains used for transmission.
|
|
|
|
|
|
|
|
This will not make a difference to sockets where Nagle's algorithm
|
|
|
|
is disabled.
|
|
|
|
|
|
|
|
Default value of MSS is fine for most applications, 25% MSS may save
|
|
|
|
some RAM when only transmitting small amounts of data. Disabled will
|
|
|
|
have worst performance and fragmentation characteristics, but uses
|
|
|
|
least RAM overall.
|
|
|
|
|
|
|
|
config TCP_OVERSIZE_MSS
|
|
|
|
bool "MSS"
|
|
|
|
config TCP_OVERSIZE_QUARTER_MSS
|
|
|
|
bool "25% MSS"
|
|
|
|
config TCP_OVERSIZE_DISABLE
|
|
|
|
bool "Disabled"
|
|
|
|
|
|
|
|
endchoice
|
|
|
|
|
|
|
|
endmenu # TCP
|
|
|
|
|
2017-07-24 21:13:01 -04:00
|
|
|
menu "UDP"
|
|
|
|
|
|
|
|
config UDP_RECVMBOX_SIZE
|
|
|
|
int "Default UDP receive mail box size"
|
|
|
|
default 6
|
|
|
|
range 6 32
|
|
|
|
help
|
|
|
|
Set UDP receive mail box size. The recommended value is 6.
|
|
|
|
|
|
|
|
UDP receive mail box is a per socket mail box, when the application receives packets
|
|
|
|
from UDP socket, LWIP core firstly posts the packets to UDP receive mail box and the
|
|
|
|
application then fetches the packets from mail box. It means LWIP can caches maximum
|
|
|
|
UDP_RECCVMBOX_SIZE packets for each UDP socket, so the maximum possible cached UDP packets
|
|
|
|
for all UDP sockets is UDP_RECCVMBOX_SIZE multiples the maximum UDP socket number. In other
|
|
|
|
words, the bigger UDP_RECVMBOX_SIZE means more memory.
|
|
|
|
On the other hand, if the receiv mail box is too small, the mail box may be full. If the
|
|
|
|
mail box is full, the LWIP drops the packets. So generally we need to make sure the UDP
|
|
|
|
receive mail box is big enough to avoid packet drop between LWIP core and application.
|
|
|
|
|
|
|
|
endmenu # UDP
|
|
|
|
|
lwip: optimize the dhcp client
1. modify the discover retry backoff time from (2,4,8,16,32,60,60)s to (500m,1,2,4,8,15,15)s.
2. add DHCP_DOES_ARP_CHECK to menuconfig for users to specify if do a ARP check on the offered address.
If enable, one more second will be taken in obtaining IP address.
3. update wifi libs
2017-01-22 07:32:39 -05:00
|
|
|
config LWIP_DHCP_DOES_ARP_CHECK
|
|
|
|
bool "Enable an ARP check on the offered address"
|
2017-03-01 00:37:36 -05:00
|
|
|
default y
|
lwip: optimize the dhcp client
1. modify the discover retry backoff time from (2,4,8,16,32,60,60)s to (500m,1,2,4,8,15,15)s.
2. add DHCP_DOES_ARP_CHECK to menuconfig for users to specify if do a ARP check on the offered address.
If enable, one more second will be taken in obtaining IP address.
3. update wifi libs
2017-01-22 07:32:39 -05:00
|
|
|
help
|
|
|
|
Enabling this option allows check if the offered IP address is not already
|
|
|
|
in use by another host on the network.
|
|
|
|
|
2017-04-20 21:08:40 -04:00
|
|
|
config TCPIP_TASK_STACK_SIZE
|
|
|
|
int "TCP/IP Task Stack Size"
|
2017-04-27 09:58:38 -04:00
|
|
|
default 2560
|
2017-01-20 06:05:38 -05:00
|
|
|
help
|
2017-04-20 21:08:40 -04:00
|
|
|
Configure TCP/IP task stack size, used by LWIP to process multi-threaded TCP/IP operations.
|
2017-04-27 09:58:38 -04:00
|
|
|
The default is 2560 bytes, setting this stack too small will result in stack overflow crashes.
|
2017-01-20 06:05:38 -05:00
|
|
|
|
2017-04-20 21:08:40 -04:00
|
|
|
menuconfig PPP_SUPPORT
|
|
|
|
bool "Enable PPP support (new/experimental)"
|
|
|
|
default n
|
|
|
|
help
|
|
|
|
Enable PPP stack. Now only PPP over serial is possible.
|
|
|
|
|
|
|
|
PPP over serial support is experimental and unsupported.
|
2017-01-20 06:05:38 -05:00
|
|
|
|
|
|
|
config PPP_PAP_SUPPORT
|
|
|
|
bool "Enable PAP support"
|
2017-04-20 21:08:40 -04:00
|
|
|
depends on PPP_SUPPORT
|
|
|
|
default n
|
2017-01-20 06:05:38 -05:00
|
|
|
help
|
|
|
|
Enable Password Authentication Protocol (PAP) support
|
2017-04-20 21:08:40 -04:00
|
|
|
|
2017-01-20 06:05:38 -05:00
|
|
|
config PPP_CHAP_SUPPORT
|
|
|
|
bool "Enable CHAP support"
|
2017-04-20 21:08:40 -04:00
|
|
|
depends on PPP_SUPPORT
|
|
|
|
default n
|
2017-01-20 06:05:38 -05:00
|
|
|
help
|
2017-04-20 21:08:40 -04:00
|
|
|
Enable Challenge Handshake Authentication Protocol (CHAP) support
|
2017-01-20 06:05:38 -05:00
|
|
|
|
|
|
|
config PPP_MSCHAP_SUPPORT
|
|
|
|
bool "Enable MSCHAP support"
|
2017-04-20 21:08:40 -04:00
|
|
|
depends on PPP_SUPPORT
|
|
|
|
default n
|
2017-01-20 06:05:38 -05:00
|
|
|
help
|
|
|
|
Enable Microsoft version of the Challenge-Handshake Authentication Protocol (MSCHAP) support
|
2017-04-20 21:08:40 -04:00
|
|
|
|
2017-01-20 06:05:38 -05:00
|
|
|
config PPP_MPPE_SUPPORT
|
|
|
|
bool "Enable MPPE support"
|
2017-04-20 21:08:40 -04:00
|
|
|
depends on PPP_SUPPORT
|
|
|
|
default n
|
2017-01-20 06:05:38 -05:00
|
|
|
help
|
|
|
|
Enable Microsoft Point-to-Point Encryption (MPPE) support
|
2017-04-20 21:08:40 -04:00
|
|
|
|
2017-01-20 06:05:38 -05:00
|
|
|
config PPP_DEBUG_ON
|
2017-04-20 21:08:40 -04:00
|
|
|
bool "Enable PPP debug log output"
|
|
|
|
depends on PPP_SUPPORT
|
|
|
|
default n
|
2017-01-20 06:05:38 -05:00
|
|
|
help
|
2017-04-20 21:08:40 -04:00
|
|
|
Enable PPP debug log output
|
2017-01-20 06:05:38 -05:00
|
|
|
|
2017-06-07 03:26:05 -04:00
|
|
|
menu "ICMP"
|
|
|
|
|
|
|
|
config LWIP_MULTICAST_PING
|
|
|
|
bool "Respond to multicast pings"
|
|
|
|
default n
|
|
|
|
|
|
|
|
config LWIP_BROADCAST_PING
|
|
|
|
bool "Respond to broadcast pings"
|
|
|
|
default n
|
|
|
|
|
|
|
|
endmenu # ICMP
|
|
|
|
|
2016-08-17 11:08:22 -04:00
|
|
|
endmenu
|