diff --git a/CMakeLists.txt b/CMakeLists.txt index 43aedfd..e165d47 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1 +1,6 @@ -idf_component_register(SRCS "zh_inclinometer.c" INCLUDE_DIRS "include" REQUIRES driver) \ No newline at end of file +if(${IDF_VERSION_MAJOR} STREQUAL 6) + set(requires esp_driver_gpio esp_driver_pcnt) +else() + set(requires driver) +endif() +idf_component_register(SRCS "zh_inclinometer.c" INCLUDE_DIRS "include" REQUIRES ${requires}) \ No newline at end of file diff --git a/README.md b/README.md index 5f89d2b..d85a326 100644 --- a/README.md +++ b/README.md @@ -2,7 +2,7 @@ ## Tested on -1. [ESP32 ESP-IDF v5.5.3](https://docs.espressif.com/projects/esp-idf/en/v5.5.3/esp32/index.html) +1. [ESP32 ESP-IDF v6.0.0](https://docs.espressif.com/projects/esp-idf/en/v6.0/esp32/index.html) ## SAST Tools diff --git a/version.txt b/version.txt index 7c32728..e3a4f19 100644 --- a/version.txt +++ b/version.txt @@ -1 +1 @@ -2.1.1 \ No newline at end of file +2.2.0 \ No newline at end of file