using esp_timer_cxx.hpp
Posted: Wed Apr 27, 2022 7:03 am
Hi ALl,
I would like to create a project with cpp and I need to use timers, but I cannot use this file. My root CMakelist.txt contains this:
cmake_minimum_required(VERSION 3.5)
set(EXTRA_COMPONENT_DIRS "$ENV{IDF_PATH}/examples/cxx/experimental/experimental_cpp_component")
include($ENV{IDF_PATH}/tools/cmake/project.cmake)
project(MyTestProject)
and my main/CMakelists.txt is:
idf_component_register(SRCS
"main.cpp"
"control.cpp"
INCLUDE_DIRS "."
REQUIRES nvs_flash json pthread esp_timer driver esp_event)
in config I enabled the compiler options/Enable C++ exceptions option.
in my control.h ther is:
#include "esp_exception.hpp"
#include "esp_timer_cxx.hpp"
compiler said:
esp_exception.hpp: No such file or directory
esp_timer_cxx.hpp: No such file or directory
How can I use timers?
thx,
Zamek
I would like to create a project with cpp and I need to use timers, but I cannot use this file. My root CMakelist.txt contains this:
cmake_minimum_required(VERSION 3.5)
set(EXTRA_COMPONENT_DIRS "$ENV{IDF_PATH}/examples/cxx/experimental/experimental_cpp_component")
include($ENV{IDF_PATH}/tools/cmake/project.cmake)
project(MyTestProject)
and my main/CMakelists.txt is:
idf_component_register(SRCS
"main.cpp"
"control.cpp"
INCLUDE_DIRS "."
REQUIRES nvs_flash json pthread esp_timer driver esp_event)
in config I enabled the compiler options/Enable C++ exceptions option.
in my control.h ther is:
#include "esp_exception.hpp"
#include "esp_timer_cxx.hpp"
compiler said:
esp_exception.hpp: No such file or directory
esp_timer_cxx.hpp: No such file or directory
How can I use timers?
thx,
Zamek