Skip to content

ESP8266_RTOS_SDK pre-release v3.1-rc1

Pre-release
Pre-release
Compare
Choose a tag to compare
@wujiangang wujiangang released this 16 Jan 08:45
· 1255 commits to master since this release

This is the list of changes since release RTOS SDK v3.0:

1. Major Improvements

ESP8266_RTOS_SDK V3.1 provides more global heap memory and offers better performance.

  • Heap memory increased by 10KB in comparison to V3.0.
  • Some system global variables are now linked to IRAM which frees up more DRAM and significantly improves calculation and communication performance of the application. This configuration can be disabled in menuconfig if necessary.

2. Added Components

  • coap
  • esp-tls
  • heap
  • libsodium
  • mDNS
  • pthread
  • wpa_supplicant

3. Changes in Functions and Features

3.1 Compiling Framework and Cross-toolchain

  • Now using GCC v5.2.0 by default, you can find the download link in README.md
  • Added the command make ota to build firmware that supports the OTA function.
  • Removed unused and unsupported libraries, including libairkiss.a and libcirom.a

3.2 Systems

  • Updated libphy.a to version 1055_8.
  • Fixed the issue where panic may re-enter itself and fail to dump information.
  • Fixed the issue where esp_restart may return unexpectedly.
  • Fixed the issue with incorrect UART baudrate after the software restarts.
  • Added a configuration in menuconfig for the stack size of ESP8266’s interrupt function.
  • Added a configuration in menuconfig for the stack size of the user start task, which is especially useful for the app_main function.
  • Added more APIs for the A-I/O function.
  • Added a deep heap trace function for OS adapter APIs, which, instead of returning just the address of a function, now returns the name of the function, as well as the file, and the line where it can be found.
  • Added the global macro __ESP_FILE__ replacing __FILE__; from now on, it provides a file name without the full path to save flash space and to optimize debug information.
  • Added the function esp_timer based on the FreeRTOS timer, as opposed to the hardware timer.
  • Added a feature that allows panic to show the system operation status, including NMI, ISR or task.
  • Added a feature where the software jumps into panic when calling abort.
  • Added a configuration in menuconfig for the stack size of the event loop task.
  • Added a new ets_vprintf to save the stack sizes of the task, interrupt and NMI. For debugging Wi-Fi, go to menuconfig and enable the setting Link ets_printf to IRAM.
  • Added a feature allowing ets_putc to support CR/LR/CRLR selection, so both ets_printf/ESP_EARLY_LOGX and printf sets of functions can use it.
  • Added a configuration disabling console UART in menuconfig.
  • Added a function showing the reason for system reset.
  • Freed up 4~5KB of flash by removing .irom0.text from libcore.a.
  • Saved more RAM by moving some functions from IRAM to flash.

3.3 Drivers

  • Fixed a bug where the UART1 interrupt could lead to a crash.
  • Refactored watchdog is now fed at OS idle task instead of ppT task.
  • Saved RAM by refactoring the SPI flash driver which helped to reduce the size of some functions linked to IRAM.
  • Added the I2C driver and an example.
  • Added the PWM driver and an example.
  • Added the hw_timer driver and an example.
  • Added ADC functions.
  • Added the HSPI driver.

3.4 FreeRTOS

  • Fixed the issue of the incorrect RTOS software frequency when switching the CPU frequency from 80MHz to 160MHz. Please pay attention to the HELP notes if you have to change the RTOS software frequency.
  • Changed the license of OS hardware platform port files from GPL to MIT.
  • Added management functions for idle/systick hook callback.
  • Added the API function xPortGetTickRateHz to get RTOS rate frequency.
  • Added the API function xTaskCreatePinnedToCore for code compatible with ESP-IDF.
  • Added a configuration in menuconfig for the stack size of the OS timer task.

3.5 Wi-Fi

  • Fixed the issue of incorrect parameters when saving to flash.
  • Fixed the WPA free data error causing failure due to lack of memory while sending packets.
  • Fixed the packet decryption error which occurred on some specific routers.
  • Fixed the incorrect IP address issue in SmartConfig’s callback.
  • Fixed the issue where assoc capability info is sent incorrectly with LDPC support. ESP8266 does not support LDPC.
  • Added a feature allowing to obtain a cellphone’s IP address during AirKiss.
  • Fixed the issue where a softAP could stop sending packets during stress test.
  • Fixed the incompatibility issue of the CCMP encryption with some specific APs.
  • Fixed the beacon timeout issue.
  • Fixed the issue where a station fails to connect to some specific APs in 11b only mode.
  • Fixed the issue where ESP-NOW in STA+AP mode could set the key index incorrectly.
  • Fixed the disconnect reason code error.
  • Fixed the issue where a station could use the mismatch status code in ADDBA response to join some specific APs.
  • Fixed the issue of WiFi crashing due to lack of memory.
  • Fixed the issue where system could crash if sniffer callback took too long to return.
  • Fixed the issue of the incorrect scan results if the WiFi channel was set to 14.
  • Fixed the BSSID error that could cause failure while connecting to an AP.
  • Optimized the short-distance communication performance.
  • Reduced power consumption.
  • Changed to operating in 11g mode by default to optimize the compatibility with different routers.
  • Refactored phy set/get parameters for APIs including:
    • esp_wifi_set_protoco
    • esp_wifi_get_protocol
    • esp_wifi_set_max_tx_power
  • Refactored WPS APIs and included a WPS example.
  • Refactored ESP-NOW now supports broadcast BSSID, also an ESP-NOW example is included.
  • For debugging purposes, added the description for error codes of data sending errors in the header file esp_wifi_types.h.
  • Added a configuration in menuconfig for the stack size of the ppTask task, which is especially useful for the sniffer callback function, usually having a large stack.
  • Added the API function esp_wifi_send_pkt_freedom for sending a raw 802.11 packet.
  • Added the function allowing to change the smartconfig's ACK information.
  • Added the callback function allowing application users to receive a probe request packet.
  • Optimized software speed.
  • Optimized WPA calculation performance by using DRAM instead of IRAM.
  • Optimized WiFi TX performance.
  • Optimized the sniffer for receiving more packets within the same time.
  • Optimized the smartconfig process and its efficiency.
  • Optimized the speed of joining an AP by using saved PMK instead of calculating them again.

3.6 LwIP

  • Fixed the issue of possible packet losses when receiving UDP multicast packets.
  • Fixed the issue where one UDP packet could exceed 1472 bytes if IP_FRAG was disabled.
  • Fixed some debug information typos.
  • Fixed the incorrect format output data types in the cc.h header file.
  • Disabled TCP cache pbuf.
  • Modified the TCP window max limitation to 14600 (10 * MSS).
  • Made LWIP_DHCP_AUTOIP_COOP automatically enabled if LWIP_AUTOIP is turned on in menuconfig.
  • Refactored socket multi-thread feature to save memory and optimize performance.
  • Refactored the internal heap management API to make debugging easier.
  • Added a configuration in menuconfig that allows to set a maximum number of sockets.
  • Added the header file netinet/in.h.
  • Added the header file sntp/sntp.h.
  • Added the header file arpa/inet.h.
  • Added a configuration for server number of IPv6 DNS in menuconfig.
  • Added an SNTP example.
  • Added a feature that allows UDP cache to support both raw UDP and socket for optimization of UDP throughput performance.
  • Added the ping application function.
  • Added a socket IPv4 and IPv6 example.
  • Added IPv6 multicast support for socket.
  • Added a configuration for autoIP in menuconfig.
  • Added a configuration in menuconfig for the TCP-IP mailbox size.
  • Added a TCP feedback handler.
  • Added a configuration in menuconfig to enable/disable setting SO_LINGER by default for multi-thread applications. If you use a TCP server or HTTP(S) applications, It is recommended to disable the setting.
  • Disabled IPv6 by default to save heap memory.
  • Optimized IPv6 multicast support.
  • Optimized the response speed of the application recv/send thread.
  • Optimized the new allocated TCP port to use hardware random integer.

3.7 SSL

  • Update WolfSSL, which in many cases saves more memory than mbedTLS.
  • Added a configuration to enable/disable the Diffie-Hellman-Merkle(DHM) module.
  • Added a configuration for CTR mode of mbedTLS.
  • Added a configuration for RSA bits of mbedTLS. If a 1024-bit RSA certification is used, it will show a warning.
  • Saved memory by separating mbedTLS Tx and Rx buffers when setting up.

3.8 MQTT

  • Refactored the MQTT example.
  • Added MQTT configurations in menuconfig.
  • Formatted the MQTT code.
  • Fixed some debug information typos.
  • Fixed the low throughput issue caused by taskYIELD.
  • Fixed the issue where the application could be blocked during socket select.
  • Fixed the ping timeout issue.
  • Fixed the issue causing MQTTPublish/MQTTConnect to return -1.
  • Fixed the watchdog reset issue in high throughput.
  • Optimized the communication performance in bad network environment.

3.9 Newlib

  • Fixed the compiling error of the assert function, occurring if DEBUG mode is enabled.
  • Replaced the LwIP private ioctl API with the general ioctl API. The function itself is not changed.
  • Replaced the LwIP private fcntl API with the general fcntl API. The function itself is not changed.
  • Made the abort function to start the system panic.
  • Made the printf sets of functions capable of returning the <null> string if the input string parameter is NULL.
  • Added usleep and sleep functions.
  • Removed error checking from the header file sys/direct.h.
  • Moved the fcntl function from the newlib library to the outside source code.

3.10 TCP/IP Adapter

  • Fixed some debug information typos.
  • Fixed the possible software crash issues when sending packets if LwIP netif is null.
  • Fixed the issue where the software would send a packet from the netif of an AP even if in STA only mode.
  • Added support for IPv6.
  • Added a feature allowing SYSTEM_EVENT_STA_GOT_IP to be triggered in autoIP mode.
  • Removed TCP/IP adapter initialization from the system startup, so you should initialize it in an application's start-up function, such as app_main.

3.11 WPA Supplicant

  • Optimized the performance of the WPA bignum algorithm calculation.
  • Fixed the cache missing issue.

3.12 Util

  • Added the CRC function.
  • Added the base64 codec optimized for the chip’s hardware.

3.13 Heap

  • Refactored the heap component compatible with the old macro APIs.
  • Removed the global debug macro MEMLEAK_DEBUG.
  • Added the feature that allows feeding the watchdog in heap dump function.
  • Optimized malloc and free to work faster.

3.14 Pthread

  • Added the pthread component. Disabled by default in menuconfig.

3.15 App Update

  • Fixed some incorrect descriptions.
  • Added support for 1MB flash OTA, and included an OTA example.

3.16 MDNS

  • Added the mDNS component.
  • Added the mDNS example.
  • Added a configuration for stack size of mDNS task. Disabled by default in menuconfig.

3.17 CoAP

  • Added the CoAP component.
  • Added the CoAP example.
  • Added a configuration to enable/disable IPv6 in menuconfig.

3.18 Bootloader Support

  • Fixed the mismatch flash size issue by making it configurable in menuconfig.
  • Fixed the issue where the flash read buffer failed to be aligned to 4 bytes in some specific compiling environments.
  • Added the SHA256 verification feature for the bootloader and OTA.
  • Added the SPI flash clock and I/O mode initialization in bootloader to speed up system start-up. If using the V3.0 bootloder, please disable this configuration in menuconfig.
  • Added a configuration in menuconfig which allows you to activate a test application by pulling the configured GPIO low for a specified time.

3.19 Libsodium

  • Added the libsodium component.

3.20 ESP-TLS

  • Added the ESP-TLS component.
  • Added the https_request ESP-TLS example.
  • Disabled IPv6 by default to save memory and bin size by disabling the LWIP_IPV6 in LwIP.

3.21 AWS IoT

  • Reduced the time of handshake by switching the CPU to 160 MHz.

3.22 JSON

  • Added support for float encoding in cJson with nano-newlib.

3.23 Log

  • Added support for setting the log level of TAG.
  • Fixed the incorrect log time stamp.

3.24 SPIFFS

  • Removed the SPIFFS example because a part of it is not supported now.

3.25 Tools

  • Fixed the bug leading to the system monitor crash on Win10 Ubuntu subsystem.
  • To make the system compatible with different types of flash, begin by launching it in DIO mode and then change to a different mode, such as QIO or QOUT, in accordance with the active configuration in menuconfig.
  • Revised the partition table script, changed the application binary alignment from 64KB to 4KB.
  • Added the tools to generate an eclipse project and build in the eclipse environment.
  • Added the script for generating PDF-type documents.
  • Added the configuration in menuconfig for saving the esptool log automatically. Disabled by default.

4. Modified Documents

  • Updated the README file for v3.1
  • Added the script to generate doxygen-type documents from the hardware driver, Wi-Fi, system and TCP-IP adapter header files.
  • Added the document describing system tasks.
  • Added the document showing how to use Eclipse for developing SDK.
  • Added the document describing how to set up the development environment on such platforms as Linux, Windows, and MacOS.