Including NfcReaderLib as ESP-IDF component.

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Including NfcReaderLib as ESP-IDF component.

927 Views
oedze
Contributor I

Hello,

I am trying to include the NfcReaderLib as a ESP-IDF component.

According to the ESP-IDF build system => Build System - ESP32 - — ESP-IDF Programming Guide latest documentation (espressif.com) This can be done by including the NxpReaderLib.

When doing so i am facing some issues importing this library. 

First of all. the lines: 

IF(IS_ABSOLUTE ${CMAKE_TOOLCHAIN_FILE})
    SET(INCLUDING_TOOLCHAIN_FILE_FOR_FLAGS ON)
    INCLUDE(${CMAKE_TOOLCHAIN_FILE})
    SET(INCLUDING_TOOLCHAIN_FILE_FOR_FLAGS OFF)
ENDIF()

Had to be removed, because the override the compiler.

I also noticed the include of the DAL using the add_subdirectory command.

The CMakeLists.txt in this folder is directly importing Linux Files. Which won't work in ESP-IDF. I changed it so it doesn't to that. 

When i fix all of those small errors, i am left with a lot of include errors, a lot of headers can't be found. 

 

How would i need to setup my component file to make sure all the headers are found? Should i use add_subdirecty(NxpReaderLib)  # main folder

 or should i directly include the NxpNfcRdLib folder. and also use add_subdirectory for my DAL and PAL? 

Are there any examples/guides to ESP-IDF? I saw this post about it => NFC Nxp lib Porting guide for ESP32 (ESP-IDF) - NXP Community Which mentioned the docs. But i also can't seem to find the right answers. 

The problem's i am facing are mostly CMake Problems, not coding problems. Creating the DAL for the ESP-IDF isn't really the problem. The problemen is linking all the libraries together.

 

 

 

0 Kudos
Reply
0 Replies