Skip to content

Commit

Permalink
IDF release/v3.3 68b237fe5 with Disable IRAM optimisation for WiFi
Browse files Browse the repository at this point in the history
  • Loading branch information
me-no-dev authored Nov 16, 2020
2 parents adafd9d + f6bf0f7 commit 6d256b6
Show file tree
Hide file tree
Showing 82 changed files with 109 additions and 11 deletions.
Binary file modified tools/sdk/bin/bootloader_dio_40m.bin
Binary file not shown.
Binary file modified tools/sdk/bin/bootloader_qout_80m.bin
Binary file not shown.
5 changes: 2 additions & 3 deletions tools/sdk/include/config/sdkconfig.h
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,7 @@
#define CONFIG_MFN56_1X 1
#define CONFIG_LWIP_MAX_SOCKETS 10
#define CONFIG_LWIP_NETIF_LOOPBACK 1
#define CONFIG_LWIP_TCP_ISN_HOOK 1
#define CONFIG_ESP32_PTHREAD_TASK_NAME_DEFAULT "pthread"
#define CONFIG_EMAC_TASK_PRIORITY 20
#define CONFIG_TIMER_TASK_STACK_DEPTH 2048
Expand Down Expand Up @@ -244,7 +245,6 @@
#define CONFIG_SPIFFS_GC_MAX_RUNS 10
#define CONFIG_ARDUINO_RUN_CORE1 1
#define CONFIG_ESP32_APPTRACE_DEST_NONE 1
#define CONFIG_ESP32_WIFI_RX_IRAM_OPT 1
#define CONFIG_HP_NANO1 1
#define CONFIG_MBEDTLS_INTERNAL_MEM_ALLOC 1
#define CONFIG_MBEDTLS_SSL_PROTO_TLS1_2 1
Expand Down Expand Up @@ -392,7 +392,6 @@
#define CONFIG_HD_NANO1 1
#define CONFIG_BTDM_MODEM_SLEEP_MODE_ORIG 1
#define CONFIG_ARDUHAL_LOG_DEFAULT_LEVEL_ERROR 1
#define CONFIG_ESP32_WIFI_IRAM_OPT 1
#define CONFIG_FATFS_API_ENCODING_ANSI_OEM 1
#define CONFIG_ARDUINO_IDF_COMMIT "66d3783c8"
#define CONFIG_ARDUINO_IDF_COMMIT "68b237fe5"
#define CONFIG_ARDUINO_IDF_BRANCH "release/v3.3"
10 changes: 10 additions & 0 deletions tools/sdk/include/esp32/esp_mesh_internal.h
Original file line number Diff line number Diff line change
Expand Up @@ -263,6 +263,16 @@ esp_err_t esp_mesh_set_announce_interval(int short_ms, int long_ms);
*/
esp_err_t esp_mesh_get_announce_interval(int *short_ms, int *long_ms);

/**
* @brief Enable mesh print scan result
*
* @param[in] enable enable or not
*
* @return
* - ESP_OK
*/
esp_err_t esp_mesh_print_scan_result(bool enable);

#ifdef __cplusplus
}
#endif
Expand Down
27 changes: 26 additions & 1 deletion tools/sdk/include/esp32/esp_panic.h
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ extern "C"
#ifndef __ASSEMBLER__

#include "esp_err.h"
#include "soc/soc.h"


/**
Expand Down Expand Up @@ -61,12 +62,36 @@ esp_err_t esp_set_watchpoint(int no, void *adr, int size, int flags);
*/
void esp_clear_watchpoint(int no);

/**
* @brief Checks stack pointer in dram
*/
inline static bool esp_stack_ptr_in_dram(uint32_t sp)
{
//Check if stack ptr is in between SOC_DRAM_LOW and SOC_DRAM_HIGH, and 16 byte aligned.
return !(sp < SOC_DRAM_LOW + 0x10 || sp > SOC_DRAM_HIGH - 0x10 || ((sp & 0xF) != 0));
}

#if CONFIG_SPIRAM_ALLOW_STACK_EXTERNAL_MEMORY
/**
* @brief Checks stack pointer in external ram
*/
inline static bool esp_stack_ptr_in_extram(uint32_t sp)
{
//Check if stack ptr is in between SOC_EXTRAM_DATA_LOW and SOC_EXTRAM_DATA_HIGH, and 16 byte aligned.
return !(sp < SOC_EXTRAM_DATA_LOW + 0x10 || sp > SOC_EXTRAM_DATA_HIGH - 0x10 || ((sp & 0xF) != 0));
}
#endif

/**
* @brief Checks stack pointer
*/
static inline bool esp_stack_ptr_is_sane(uint32_t sp)
{
return !(sp < 0x3ffae010UL || sp > 0x3ffffff0UL || ((sp & 0xf) != 0));
#if CONFIG_SPIRAM_ALLOW_STACK_EXTERNAL_MEMORY
return (esp_stack_ptr_in_dram(sp) || esp_stack_ptr_in_extram(sp));
#else
return esp_stack_ptr_in_dram(sp);
#endif
}
#endif

Expand Down
11 changes: 11 additions & 0 deletions tools/sdk/include/lwip/lwipopts.h
Original file line number Diff line number Diff line change
Expand Up @@ -396,6 +396,17 @@
*/
#define LWIP_TCP_RTO_TIME CONFIG_LWIP_TCP_RTO_TIME

/**
* Set TCP hook for Initial Sequence Number (ISN)
*/
#ifdef CONFIG_LWIP_TCP_ISN_HOOK
#include <lwip/arch.h>
struct ip_addr;
u32_t lwip_hook_tcp_isn(const struct ip_addr *local_ip, u16_t local_port,
const struct ip_addr *remote_ip, u16_t remote_port);
#define LWIP_HOOK_TCP_ISN lwip_hook_tcp_isn
#endif

/*
----------------------------------
---------- Pbuf options ----------
Expand Down
8 changes: 8 additions & 0 deletions tools/sdk/include/lwip/netdb.h
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,17 @@

#include "lwip/netdb.h"

#ifdef __cplusplus
extern "C" {
#endif

#ifdef ESP_PLATFORM
int getnameinfo(const struct sockaddr *addr, socklen_t addrlen,
char *host, socklen_t hostlen,
char *serv, socklen_t servlen, int flags);

#endif

#ifdef __cplusplus
}
#endif
48 changes: 48 additions & 0 deletions tools/sdk/include/lwip/tcp_isn.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
/*
* Copyright (c) 2016 The MINIX 3 Project.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without modification,
* are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright notice,
* this list of conditions and the following disclaimer.
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
* 3. The name of the author may not be used to endorse or promote products
* derived from this software without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED
* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
* MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT
* SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
* EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT
* OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
* INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
* CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
* IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY
* OF SUCH DAMAGE.
*
* Author: David van Moolenbroek <david@minix3.org>
*/

#ifndef LWIP_TCP_ISN_H
#define LWIP_TCP_ISN_H

#include "lwip/opt.h"
#include "lwip/ip_addr.h"

#ifdef __cplusplus
extern "C" {
#endif

void lwip_init_tcp_isn(u32_t boot_time, const u8_t *secret_16_bytes);
u32_t lwip_hook_tcp_isn(const ip_addr_t *local_ip, u16_t local_port,
const ip_addr_t *remote_ip, u16_t remote_port);

#ifdef __cplusplus
}
#endif

#endif /* LWIP_TCP_ISN_H */
6 changes: 1 addition & 5 deletions tools/sdk/ld/esp32.project.ld

Large diffs are not rendered by default.

Binary file modified tools/sdk/lib/libapp_trace.a
Binary file not shown.
Binary file modified tools/sdk/lib/libapp_update.a
Binary file not shown.
Binary file modified tools/sdk/lib/libasio.a
Binary file not shown.
Binary file modified tools/sdk/lib/libbootloader_support.a
Binary file not shown.
Binary file modified tools/sdk/lib/libbt.a
Binary file not shown.
Binary file modified tools/sdk/lib/libcoap.a
Binary file not shown.
Binary file modified tools/sdk/lib/libcoexist.a
Binary file not shown.
Binary file modified tools/sdk/lib/libconsole.a
Binary file not shown.
Binary file modified tools/sdk/lib/libcore.a
Binary file not shown.
Binary file modified tools/sdk/lib/libcxx.a
Binary file not shown.
Binary file modified tools/sdk/lib/libdriver.a
Binary file not shown.
Binary file modified tools/sdk/lib/libefuse.a
Binary file not shown.
Binary file modified tools/sdk/lib/libesp-tls.a
Binary file not shown.
Binary file modified tools/sdk/lib/libesp32-camera.a
Binary file not shown.
Binary file modified tools/sdk/lib/libesp32.a
Binary file not shown.
Binary file modified tools/sdk/lib/libesp_adc_cal.a
Binary file not shown.
Binary file modified tools/sdk/lib/libesp_event.a
Binary file not shown.
Binary file modified tools/sdk/lib/libesp_http_client.a
Binary file not shown.
Binary file modified tools/sdk/lib/libesp_http_server.a
Binary file not shown.
Binary file modified tools/sdk/lib/libesp_https_ota.a
Binary file not shown.
Binary file modified tools/sdk/lib/libesp_https_server.a
Binary file not shown.
Binary file modified tools/sdk/lib/libesp_ringbuf.a
Binary file not shown.
Binary file modified tools/sdk/lib/libesp_websocket_client.a
Binary file not shown.
Binary file modified tools/sdk/lib/libespcoredump.a
Binary file not shown.
Binary file modified tools/sdk/lib/libespnow.a
Binary file not shown.
Binary file modified tools/sdk/lib/libethernet.a
Binary file not shown.
Binary file modified tools/sdk/lib/libexpat.a
Binary file not shown.
Binary file modified tools/sdk/lib/libface_detection.a
Binary file not shown.
Binary file modified tools/sdk/lib/libface_recognition.a
Binary file not shown.
Binary file modified tools/sdk/lib/libfatfs.a
Binary file not shown.
Binary file modified tools/sdk/lib/libfb_gfx.a
Binary file not shown.
Binary file modified tools/sdk/lib/libfreemodbus.a
Binary file not shown.
Binary file modified tools/sdk/lib/libfreertos.a
Binary file not shown.
Binary file modified tools/sdk/lib/libheap.a
Binary file not shown.
Binary file modified tools/sdk/lib/libimage_util.a
Binary file not shown.
Binary file modified tools/sdk/lib/libjsmn.a
Binary file not shown.
Binary file modified tools/sdk/lib/libjson.a
Binary file not shown.
Binary file modified tools/sdk/lib/liblibsodium.a
Binary file not shown.
Binary file modified tools/sdk/lib/liblog.a
Binary file not shown.
Binary file modified tools/sdk/lib/liblwip.a
Binary file not shown.
Binary file modified tools/sdk/lib/libmbedtls.a
Binary file not shown.
Binary file modified tools/sdk/lib/libmdns.a
Binary file not shown.
Binary file modified tools/sdk/lib/libmesh.a
Binary file not shown.
Binary file modified tools/sdk/lib/libmicro-ecc.a
Binary file not shown.
Binary file modified tools/sdk/lib/libmqtt.a
Binary file not shown.
Binary file modified tools/sdk/lib/libnet80211.a
Binary file not shown.
Binary file modified tools/sdk/lib/libnewlib.a
Binary file not shown.
Binary file modified tools/sdk/lib/libnghttp.a
Binary file not shown.
Binary file modified tools/sdk/lib/libnvs_flash.a
Binary file not shown.
Binary file modified tools/sdk/lib/libopenssl.a
Binary file not shown.
Binary file modified tools/sdk/lib/libpp.a
Binary file not shown.
Binary file modified tools/sdk/lib/libprotobuf-c.a
Binary file not shown.
Binary file modified tools/sdk/lib/libprotocomm.a
Binary file not shown.
Binary file modified tools/sdk/lib/libpthread.a
Binary file not shown.
Binary file modified tools/sdk/lib/libsdmmc.a
Binary file not shown.
Binary file modified tools/sdk/lib/libsmartconfig.a
Binary file not shown.
Binary file modified tools/sdk/lib/libsmartconfig_ack.a
Binary file not shown.
Binary file modified tools/sdk/lib/libsoc.a
Binary file not shown.
Binary file modified tools/sdk/lib/libspi_flash.a
Binary file not shown.
Binary file modified tools/sdk/lib/libspiffs.a
Binary file not shown.
Binary file modified tools/sdk/lib/libtcp_transport.a
Binary file not shown.
Binary file modified tools/sdk/lib/libtcpip_adapter.a
Binary file not shown.
Binary file modified tools/sdk/lib/libulp.a
Binary file not shown.
Binary file modified tools/sdk/lib/libunity.a
Binary file not shown.
Binary file modified tools/sdk/lib/libvfs.a
Binary file not shown.
Binary file modified tools/sdk/lib/libwear_levelling.a
Binary file not shown.
Binary file modified tools/sdk/lib/libwifi_provisioning.a
Binary file not shown.
Binary file modified tools/sdk/lib/libwpa.a
Binary file not shown.
Binary file modified tools/sdk/lib/libwpa2.a
Binary file not shown.
Binary file modified tools/sdk/lib/libwpa_supplicant.a
Binary file not shown.
Binary file modified tools/sdk/lib/libwps.a
Binary file not shown.
Binary file modified tools/sdk/lib/libxtensa-debug-module.a
Binary file not shown.
5 changes: 3 additions & 2 deletions tools/sdk/sdkconfig
Original file line number Diff line number Diff line change
Expand Up @@ -457,8 +457,8 @@ CONFIG_ESP32_WIFI_TASK_PINNED_TO_CORE_1=
CONFIG_ESP32_WIFI_SOFTAP_BEACON_MAX_LEN=752
CONFIG_ESP32_WIFI_MGMT_SBUF_NUM=32
CONFIG_ESP32_WIFI_DEBUG_LOG_ENABLE=
CONFIG_ESP32_WIFI_IRAM_OPT=y
CONFIG_ESP32_WIFI_RX_IRAM_OPT=y
CONFIG_ESP32_WIFI_IRAM_OPT=
CONFIG_ESP32_WIFI_RX_IRAM_OPT=

#
# PHY
Expand Down Expand Up @@ -690,6 +690,7 @@ CONFIG_LWIP_LOOPBACK_MAX_PBUFS=8
#
# TCP
#
CONFIG_LWIP_TCP_ISN_HOOK=y
CONFIG_LWIP_MAX_ACTIVE_TCP=16
CONFIG_LWIP_MAX_LISTENING_TCP=16
CONFIG_TCP_MAXRTX=12
Expand Down

0 comments on commit 6d256b6

Please sign in to comment.