Espressif ESP32-S2 Programming Manual page 1140

Table of Contents

Advertisement

Chapter 2. API Reference
• 10 if
CONFIG_SPIRAM_TRY_ALLOCATE_WIFI_LWIP
• 16 if
CONFIG_SPIRAM_TRY_ALLOCATE_WIFI_LWIP
CONFIG_ESP32_WIFI_DYNAMIC_RX_BUFFER_NUM
Max number of WiFi dynamic RX buffers
Found in:
Component config
Set the number of WiFi dynamic RX buffers, 0 means unlimited RX buffers will be allocated (provided
sufficient free RAM). The size of each dynamic RX buffer depends on the size of the received data
frame.
For each received data frame, the WiFi driver makes a copy to an RX buffer and then delivers it to the
high layer TCP/IP stack. The dynamic RX buffer is freed after the higher layer has successfully received
the data frame.
For some applications, WiFi data frames may be received faster than the application can process them.
In these cases we may run out of memory if RX buffer number is unlimited (0).
If a dynamic RX buffer limit is set, it should be at least the number of static RX buffers.
Range:
• from 0 to 128 if
• from 0 to 1024 if
Default value:
• 32
CONFIG_ESP32_WIFI_TX_BUFFER
Type of WiFi TX buffers
Found in:
Component config
Select type of WiFi TX buffers:
If"Static"is selected, WiFi TX buffers are allocated when WiFi is initialized and released when WiFi
is de-initialized. The size of each static TX buffer is fixed to about 1.6KB.
If "Dynamic"is selected, each WiFi TX buffer is allocated as needed when a data frame is delivered
to the Wifi driver from the TCP/IP stack. The buffer is freed after the data frame has been sent by the
WiFi driver. The size of each dynamic TX buffer depends on the length of each data frame sent by the
TCP/IP layer.
If PSRAM is enabled, "Static"should be selected to guarantee enough WiFi TX buffers. If PSRAM
is disabled, "Dynamic"should be selected to improve the utilization of RAM.
Available options:
• Static (ESP32_WIFI_STATIC_TX_BUFFER)
• Dynamic (ESP32_WIFI_DYNAMIC_TX_BUFFER)
CONFIG_ESP32_WIFI_STATIC_TX_BUFFER_NUM
Max number of WiFi static TX buffers
Found in:
Component config
Set the number of WiFi static TX buffers. Each buffer takes approximately 1.6KB of RAM. The static
RX buffers are allocated when esp_wifi_init() is called, they are not released until esp_wifi_deinit() is
called.
For each transmitted data frame from the higher layer TCP/IP stack, the WiFi driver makes a copy of
it in a TX buffer. For some applications especially UDP applications, the upper layer can deliver frames
faster than WiFi layer can transmit. In these cases, we may run out of TX buffers.
Espressif Systems
>
Wi-Fi
CONFIG_LWIP_WND_SCALE
CONFIG_LWIP_WND_SCALE
>
Wi-Fi
>
Wi-Fi
1129
Submit Document Feedback
Release v4.4

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the ESP32-S2 and is the answer not in the manual?

Table of Contents

Save PDF