mirror of
https://github.com/RIOT-OS/RIOT.git
synced 2024-12-29 04:50:03 +01:00
7b1f083cd8
RIOT-OS uses part of Espressif ESP8266 RTOS SDK to build support for this CPU. The SDK includes some vendor-provided closed source pre-compiled libraries that we need to modify to adapt to RIOT-OS usage. This library modifications was done once and uploaded to a fork of the vendor repository and was provided as an environment variable. This patch changes two things: 1. It installs the SDK as a RIOT PKG from the new pkg/esp8266_sdk directory instead of requiring the user to download it separately. 2. It performs the library modifications (symbol renames) on the pkg Makefile removing the need to use a fork with the modifications applied and simplifying the SDK update and future modifications. This change sets the SDK package version (git SHA) to the same one that our fork was using as a parent in the vendor repository, meaning that the output libraries are exactly the same as before. Tested with ``` ESP8266_RTOS_SDK_DIR=/dev/null USEMODULE=esp_log_startup make -C tests/shell BOARD=esp8266-esp-12x flash ``` and verified that the program works. The boot message now includes: ``` ESP8266-RTOS-SDK Version v3.1-51-g913a06a9 ``` confirming the SDK version used. `/dev/null` in the test is just to make sure that no evaluation of `ESP8266_RTOS_SDK_DIR` in make is affected by the environment variable value which would be set to the SDK for people who followed the set up instructions before this change. Tested the checkout size: ```bash $ du -hs build/pkg/esp8266_sdk/ 124M build/pkg/esp8266_sdk/ ```
90 lines
2.2 KiB
C
90 lines
2.2 KiB
C
/*
|
|
* Copyright (C) 2019 Gunar Schorcht
|
|
*
|
|
* This file is subject to the terms and conditions of the GNU Lesser
|
|
* General Public License v2.1. See the file LICENSE in the top level
|
|
* directory for more details.
|
|
*/
|
|
|
|
/**
|
|
* @ingroup cpu_esp8266
|
|
* @{
|
|
*
|
|
* @file
|
|
* @brief SDK configuration compatible to the ESP-IDF
|
|
*
|
|
* This file defines configuration parameters that are only required for source
|
|
* code compatibility with the SDK. These configuration parameters are not used
|
|
* directly to configure the compilation of RIOT-OS. However, some of them can
|
|
* be overrien overridden by application-specific board configuration.
|
|
*
|
|
* @author Gunar Schorcht <gunar@schorcht.net>
|
|
*/
|
|
|
|
#ifndef SDK_CONF_H
|
|
#define SDK_CONF_H
|
|
|
|
#ifndef DOXYGEN
|
|
|
|
#include "board.h"
|
|
#include "esp_image_format.h"
|
|
|
|
#ifdef __cplusplus
|
|
extern "C" {
|
|
#endif
|
|
|
|
/**
|
|
* @brief SDK version number
|
|
*
|
|
* Determined with `git describe --tags` in `$ESP8266_SDK_DIR`
|
|
*/
|
|
#if !defined(IDF_VER) || DOXYGEN
|
|
#include "esp8266_idf_version.h"
|
|
#endif
|
|
|
|
/**
|
|
* @name Default console configuration
|
|
*
|
|
* STDIO_UART_BAUDRATE is used as CONFIG_CONSOLE_UART_BAUDRATE and
|
|
* can be overridden by an application specific configuration.
|
|
*
|
|
* @{
|
|
*/
|
|
#define CONFIG_CONSOLE_UART_NUM (0)
|
|
#ifndef CONFIG_CONSOLE_UART_BAUDRATE
|
|
#define CONFIG_CONSOLE_UART_BAUDRATE (STDIO_UART_BAUDRATE)
|
|
#endif
|
|
/** @} */
|
|
|
|
#define CONFIG_APP1_SIZE (0xf0000)
|
|
#define CONFIG_APP1_OFFSET (0x10000)
|
|
|
|
#define CONFIG_SOC_IRAM_SIZE (0xc000)
|
|
|
|
#define CONFIG_TASK_WDT_PANIC
|
|
#define CONFIG_TASK_WDT_TIMEOUT_S (15)
|
|
#define CONFIG_RESET_REASON (1)
|
|
|
|
#define CONFIG_WIFI_PPT_TASKSTACK_SIZE (3584)
|
|
#define CONFIG_MAIN_TASK_STACK_SIZE (2048)
|
|
#define CONFIG_EVENT_LOOP_STACK_SIZE (2048)
|
|
|
|
#define CONFIG_ESP_PHY_CALIBRATION_AND_DATA_STORAGE
|
|
#define CONFIG_ESP_PHY_INIT_DATA_IN_PARTITION (0)
|
|
|
|
#define CONFIG_SPI_FLASH_FREQ (ESP_IMAGE_SPI_SPEED_40M) /* 40 MHz */
|
|
#define CONFIG_SPI_FLASH_MODE (ESP_IMAGE_SPI_MODE_DIO) /* DIO mode */
|
|
#define CONFIG_SPI_FLASH_SIZE (0x100000)
|
|
|
|
#define CONFIG_SCAN_AP_MAX (32)
|
|
|
|
#define CONFIG_USING_NEW_ETS_VPRINTF
|
|
|
|
#ifdef __cplusplus
|
|
}
|
|
#endif
|
|
|
|
#endif /* DOXYGEN */
|
|
#endif /* SDK_CONF_H */
|
|
/** @} */
|