EasyManuals Logo

Espressif ESP32-S2 User Manual

Espressif ESP32-S2
1695 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #1435 background imageLoading...
Page #1435 background image
Chapter 4. API Guides
4.19.8 DMA Buffer in the stack
Placing DMA buffers in the stack is possible but discouraged. If doing so, pay attention to the following:
Placing DRAM buffers on the stack is not recommended if the stack may be in PSRAM. If the stack of a task
is placed in the PSRAM, several steps have to be taken as described in Support for external RAM.
Use macro WORD_ALIGNED_ATTR in functions before variables to place them in proper positions like:
void app_main()
{
uint8_t stuff;
WORD_ALIGNED_ATTR uint8_t buffer[] = "I want to send something"; //or
,the buffer will be placed right after stuff.
// initialization code...
spi_transaction_t temp = {
.tx_buffer = buffer,
.length = 8 * sizeof(buffer),
};
spi_device_transmit(spi, &temp);
// other stuff
}
4.20 lwIP
ESP-IDF uses the open source lwIP lightweight TCP/IP stack. The ESP-IDF version of lwIP (esp-lwip) has some
modifications and additions compared to the upstream project.
4.20.1 Supported APIs
ESP-IDF supports the following lwIP TCP/IP stack functions:
BSD Sockets API
Netconn API is enabled but not officially supported for ESP-IDF applications
Adapted APIs
Some common lwIP appAPIs are supported indirectly by ESP-IDF:
DHCP Server & Client are supported indirectly via the ESP-NETIF functionality
Simple Network Time Protocol (SNTP) is supported via the lwip/include/apps/sntp/sntp.h
lwip/lwip/src/include/lwip/apps/sntp.h functions (see also SNTP Time Synchronization)
ICMP Ping is supported using a variation on the lwIP ping API. See ICMP Echo.
NetBIOS lookup is available using the standard lwIP API. protocols/http_server/restful_server has an option
to demonstrate using NetBIOS to look up a host on the LAN.
mDNS uses a different implementation to the lwIP default mDNS (see mDNS Service), but lwIP can look up
mDNS hosts using standard APIs such as gethostbyname() and the convention hostname.local,
provided the CONFIG_LWIP_DNS_SUPPORT_MDNS_QUERIES setting is enabled.
4.20.2 BSD Sockets API
The BSD Sockets API is a common cross-platform TCP/IP sockets API that originated in the Berkeley Standard
Distribution of UNIX but is now standardized in a section of the POSIX specification. BSD Sockets are sometimes
called POSIX Sockets or Berkeley Sockets.
As implemented in ESP-IDF, lwIP supports all of the common usages of the BSD Sockets API.
Espressif Systems 1424
Submit Document Feedback
Release v4.4

Table of Contents

Questions and Answers:

Question and Answer IconNeed help?

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

Espressif ESP32-S2 Specifications

General IconGeneral
BrandEspressif
ModelESP32-S2
CategorySingle board computers
LanguageEnglish