mirror of
https://github.com/RIOT-OS/RIOT.git
synced 2024-12-29 04:50:03 +01:00
cpu/esp32: add ESP-IDF interface API
Implements an interface for ESP-IDF types and functions that are required by RIOT-OS but cannot be included directly due to name conflicts. f
This commit is contained in:
parent
45aa420c42
commit
de96a31e1f
@ -136,5 +136,6 @@ endmenu
|
||||
|
||||
rsource "bootloader/Kconfig"
|
||||
rsource "esp-idf/Kconfig"
|
||||
rsource "esp-idf-api/Kconfig"
|
||||
rsource "periph/Kconfig"
|
||||
source "$(RIOTCPU)/esp_common/Kconfig"
|
||||
|
@ -7,6 +7,7 @@ SRC = irq_arch.c startup.c syscalls.c
|
||||
DIRS += $(RIOTCPU)/esp_common
|
||||
DIRS += periph
|
||||
DIRS += esp-idf
|
||||
DIRS += esp-idf-api
|
||||
|
||||
ifneq (, $(filter esp_bootloader, $(USEMODULE)))
|
||||
DIRS += bootloader
|
||||
|
@ -4,6 +4,7 @@ include $(RIOTCPU)/esp_common/Makefile.dep
|
||||
|
||||
USEPKG += esp32_sdk
|
||||
|
||||
USEMODULE += esp_idf_api
|
||||
USEMODULE += esp_idf_common
|
||||
USEMODULE += esp_bootloader
|
||||
|
||||
|
14
cpu/esp32/esp-idf-api/Kconfig
Normal file
14
cpu/esp32/esp-idf-api/Kconfig
Normal file
@ -0,0 +1,14 @@
|
||||
# Copyright (c) 2022 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.
|
||||
#
|
||||
|
||||
config MODULE_ESP_IDF_API
|
||||
bool
|
||||
depends on TEST_KCONFIG
|
||||
depends on HAS_ARCH_ESP32
|
||||
default y
|
||||
help
|
||||
ESP-IDF interface API
|
18
cpu/esp32/esp-idf-api/Makefile
Normal file
18
cpu/esp32/esp-idf-api/Makefile
Normal file
@ -0,0 +1,18 @@
|
||||
MODULE = esp_idf_api
|
||||
|
||||
# ESP-IDF header files must be found first in this module. Therefore,
|
||||
# the ESP-IDF include paths must come before the RIOT include paths.
|
||||
PRE_INCLUDES += -I$(ESP32_SDK_DIR)/components/driver/include
|
||||
PRE_INCLUDES += -I$(ESP32_SDK_DIR)/components/esp_common/include
|
||||
PRE_INCLUDES += -I$(ESP32_SDK_DIR)/components/esp_hw_support/include
|
||||
PRE_INCLUDES += -I$(ESP32_SDK_DIR)/components/esp_rom/include
|
||||
PRE_INCLUDES += -I$(ESP32_SDK_DIR)/components/hal/include
|
||||
PRE_INCLUDES += -I$(ESP32_SDK_DIR)/components/hal/platform_port/include
|
||||
PRE_INCLUDES += -I$(ESP32_SDK_DIR)/components/soc/include
|
||||
|
||||
PRE_INCLUDES += -I$(ESP32_SDK_DIR)/components/hal/$(CPU)/include
|
||||
PRE_INCLUDES += -I$(ESP32_SDK_DIR)/components/soc/$(CPU)/include
|
||||
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
|
||||
INCLUDES := $(PRE_INCLUDES) $(INCLUDES)
|
23
cpu/esp32/esp-idf-api/doc.txt
Normal file
23
cpu/esp32/esp-idf-api/doc.txt
Normal file
@ -0,0 +1,23 @@
|
||||
/*
|
||||
* Copyright (C) 2022 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.
|
||||
*/
|
||||
|
||||
/**
|
||||
* @defgroup cpu_esp32_esp_idf_api ESP-IDF Interface API
|
||||
* @ingroup cpu_esp32
|
||||
* @brief ESP-IDF Interface API
|
||||
*
|
||||
* This module implements an interface for ESP-IDF types and functions that are
|
||||
* required by RIOT-OS but cannot be included directly due to name conflicts.
|
||||
*
|
||||
* For this purpose, the header files of this module declare all the types and
|
||||
* functions that are required from the ESP-IDF, but without using the ESP-IDF
|
||||
* header files with conflicting names. The implementation of the module then
|
||||
* uses the ESP-IDF. In most cases, simple wrapper functions are sufficient.
|
||||
*
|
||||
* @author Gunar Schorcht <gunar@schorcht.net>
|
||||
*/
|
Loading…
Reference in New Issue
Block a user