<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>NFCのトピックIncluding NfcReaderLib as ESP-IDF component.</title>
    <link>https://community.nxp.com/t5/NFC/Including-NfcReaderLib-as-ESP-IDF-component/m-p/1629807#M10217</link>
    <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;I am trying to include the NfcReaderLib as a ESP-IDF component.&lt;/P&gt;&lt;P&gt;According to the ESP-IDF build system =&amp;gt;&amp;nbsp;&lt;A href="https://docs.espressif.com/projects/esp-idf/en/latest/esp32/api-guides/build-system.html#using-third-party-cmake-projects-with-components" target="_blank"&gt;Build System - ESP32 - — ESP-IDF Programming Guide latest documentation (espressif.com)&lt;/A&gt;&amp;nbsp;This can be done by including the NxpReaderLib.&lt;/P&gt;&lt;P&gt;When doing so i am facing some issues importing this library.&amp;nbsp;&lt;/P&gt;&lt;P&gt;First of all. the lines:&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="c"&gt;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()&lt;/LI-CODE&gt;&lt;P&gt;Had to be removed, because the override the compiler.&lt;/P&gt;&lt;P&gt;I also noticed the include of the DAL using the add_subdirectory command.&lt;/P&gt;&lt;P&gt;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.&amp;nbsp;&lt;/P&gt;&lt;P&gt;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.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;How would i need to setup my component file to make sure all the headers are found? Should i use add_subdirecty(NxpReaderLib)&amp;nbsp; # main folder&lt;/P&gt;&lt;P&gt;&amp;nbsp;or should i directly include the NxpNfcRdLib folder. and also use add_subdirectory for my DAL and PAL?&amp;nbsp;&lt;/P&gt;&lt;P&gt;Are there any examples/guides to ESP-IDF? I saw this post about it =&amp;gt;&amp;nbsp;&lt;A href="https://community.nxp.com/t5/NFC/NFC-Nxp-lib-Porting-guide-for-ESP32-ESP-IDF/m-p/1521923" target="_blank"&gt;NFC Nxp lib Porting guide for ESP32 (ESP-IDF) - NXP Community&lt;/A&gt;&amp;nbsp;Which mentioned the docs. But i also can't seem to find the right answers.&amp;nbsp;&lt;/P&gt;&lt;P&gt;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.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Fri, 07 Apr 2023 14:30:15 GMT</pubDate>
    <dc:creator>oedze</dc:creator>
    <dc:date>2023-04-07T14:30:15Z</dc:date>
    <item>
      <title>Including NfcReaderLib as ESP-IDF component.</title>
      <link>https://community.nxp.com/t5/NFC/Including-NfcReaderLib-as-ESP-IDF-component/m-p/1629807#M10217</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;I am trying to include the NfcReaderLib as a ESP-IDF component.&lt;/P&gt;&lt;P&gt;According to the ESP-IDF build system =&amp;gt;&amp;nbsp;&lt;A href="https://docs.espressif.com/projects/esp-idf/en/latest/esp32/api-guides/build-system.html#using-third-party-cmake-projects-with-components" target="_blank"&gt;Build System - ESP32 - — ESP-IDF Programming Guide latest documentation (espressif.com)&lt;/A&gt;&amp;nbsp;This can be done by including the NxpReaderLib.&lt;/P&gt;&lt;P&gt;When doing so i am facing some issues importing this library.&amp;nbsp;&lt;/P&gt;&lt;P&gt;First of all. the lines:&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="c"&gt;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()&lt;/LI-CODE&gt;&lt;P&gt;Had to be removed, because the override the compiler.&lt;/P&gt;&lt;P&gt;I also noticed the include of the DAL using the add_subdirectory command.&lt;/P&gt;&lt;P&gt;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.&amp;nbsp;&lt;/P&gt;&lt;P&gt;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.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;How would i need to setup my component file to make sure all the headers are found? Should i use add_subdirecty(NxpReaderLib)&amp;nbsp; # main folder&lt;/P&gt;&lt;P&gt;&amp;nbsp;or should i directly include the NxpNfcRdLib folder. and also use add_subdirectory for my DAL and PAL?&amp;nbsp;&lt;/P&gt;&lt;P&gt;Are there any examples/guides to ESP-IDF? I saw this post about it =&amp;gt;&amp;nbsp;&lt;A href="https://community.nxp.com/t5/NFC/NFC-Nxp-lib-Porting-guide-for-ESP32-ESP-IDF/m-p/1521923" target="_blank"&gt;NFC Nxp lib Porting guide for ESP32 (ESP-IDF) - NXP Community&lt;/A&gt;&amp;nbsp;Which mentioned the docs. But i also can't seem to find the right answers.&amp;nbsp;&lt;/P&gt;&lt;P&gt;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.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 07 Apr 2023 14:30:15 GMT</pubDate>
      <guid>https://community.nxp.com/t5/NFC/Including-NfcReaderLib-as-ESP-IDF-component/m-p/1629807#M10217</guid>
      <dc:creator>oedze</dc:creator>
      <dc:date>2023-04-07T14:30:15Z</dc:date>
    </item>
  </channel>
</rss>

