<?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のトピックGetting runtime error in nfcDemoApp after adding user stack on PN7160 (Linux NFC Stack)</title>
    <link>https://community.nxp.com/t5/NFC/Getting-runtime-error-in-nfcDemoApp-after-adding-user-stack-on/m-p/2256044#M13879</link>
    <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;I am working on integrating the PN7160 NFC controller with a Linux-based board (MediaTek Genio-510 EVK).&lt;BR /&gt;I have cross-compiled the NXP Linux NFC stack and added the user-space stack (linux_libnfc-nci) into the board. The stack builds successfully and installs correctly, but when I run the demo application, I get a runtime error.&lt;/P&gt;&lt;H3&gt;&lt;FONT size="3"&gt;Command:&amp;nbsp;./nfcDemoApp poll&lt;BR /&gt;&lt;/FONT&gt;&lt;/H3&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Niranjan123_0-1764925933756.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/368754iCAD673C080716F98/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Niranjan123_0-1764925933756.png" alt="Niranjan123_0-1764925933756.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;H3&gt;&lt;STRONG&gt;What I have done:&lt;/STRONG&gt;&lt;/H3&gt;&lt;UL&gt;&lt;LI&gt;&lt;P&gt;Enabled required I2C bus and verified PN7160 is detected.&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;Added libnfc-nci.conf and libnfc-nxp.conf under /usr/local/etc/.&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;Verified I2C lines with oscilloscope and interrupts appear.&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;Compiled the stack using the correct cross-toolchain.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;H3&gt;&lt;STRONG&gt;Questions:&lt;/STRONG&gt;&lt;/H3&gt;&lt;OL&gt;&lt;LI&gt;&lt;P&gt;What does this std::out_of_range: basic_string::substr error typically indicate in the PN7160 Linux NFC stack?&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;Is it related to missing configuration fields in libnfc-nci.conf or a parsing issue?&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;Which debug logs should I enable to identify the exact cause?&lt;/P&gt;&lt;/LI&gt;&lt;/OL&gt;&lt;P&gt;Any guidance on resolving this issue would be very helpful.&lt;BR /&gt;&lt;BR /&gt;i have attached the complete debug log from the board for reference.&lt;BR /&gt;Thank you!&lt;/P&gt;&lt;P&gt;— Niranjan&lt;/P&gt;&lt;H3&gt;&lt;FONT size="3"&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/H3&gt;</description>
    <pubDate>Fri, 05 Dec 2025 09:36:00 GMT</pubDate>
    <dc:creator>Niranjan123</dc:creator>
    <dc:date>2025-12-05T09:36:00Z</dc:date>
    <item>
      <title>Getting runtime error in nfcDemoApp after adding user stack on PN7160 (Linux NFC Stack)</title>
      <link>https://community.nxp.com/t5/NFC/Getting-runtime-error-in-nfcDemoApp-after-adding-user-stack-on/m-p/2256044#M13879</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;I am working on integrating the PN7160 NFC controller with a Linux-based board (MediaTek Genio-510 EVK).&lt;BR /&gt;I have cross-compiled the NXP Linux NFC stack and added the user-space stack (linux_libnfc-nci) into the board. The stack builds successfully and installs correctly, but when I run the demo application, I get a runtime error.&lt;/P&gt;&lt;H3&gt;&lt;FONT size="3"&gt;Command:&amp;nbsp;./nfcDemoApp poll&lt;BR /&gt;&lt;/FONT&gt;&lt;/H3&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Niranjan123_0-1764925933756.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/368754iCAD673C080716F98/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Niranjan123_0-1764925933756.png" alt="Niranjan123_0-1764925933756.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;H3&gt;&lt;STRONG&gt;What I have done:&lt;/STRONG&gt;&lt;/H3&gt;&lt;UL&gt;&lt;LI&gt;&lt;P&gt;Enabled required I2C bus and verified PN7160 is detected.&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;Added libnfc-nci.conf and libnfc-nxp.conf under /usr/local/etc/.&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;Verified I2C lines with oscilloscope and interrupts appear.&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;Compiled the stack using the correct cross-toolchain.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;H3&gt;&lt;STRONG&gt;Questions:&lt;/STRONG&gt;&lt;/H3&gt;&lt;OL&gt;&lt;LI&gt;&lt;P&gt;What does this std::out_of_range: basic_string::substr error typically indicate in the PN7160 Linux NFC stack?&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;Is it related to missing configuration fields in libnfc-nci.conf or a parsing issue?&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;Which debug logs should I enable to identify the exact cause?&lt;/P&gt;&lt;/LI&gt;&lt;/OL&gt;&lt;P&gt;Any guidance on resolving this issue would be very helpful.&lt;BR /&gt;&lt;BR /&gt;i have attached the complete debug log from the board for reference.&lt;BR /&gt;Thank you!&lt;/P&gt;&lt;P&gt;— Niranjan&lt;/P&gt;&lt;H3&gt;&lt;FONT size="3"&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/H3&gt;</description>
      <pubDate>Fri, 05 Dec 2025 09:36:00 GMT</pubDate>
      <guid>https://community.nxp.com/t5/NFC/Getting-runtime-error-in-nfcDemoApp-after-adding-user-stack-on/m-p/2256044#M13879</guid>
      <dc:creator>Niranjan123</dc:creator>
      <dc:date>2025-12-05T09:36:00Z</dc:date>
    </item>
    <item>
      <title>Re: Getting runtime error in nfcDemoApp after adding user stack on PN7160 (Linux NFC Stack)</title>
      <link>https://community.nxp.com/t5/NFC/Getting-runtime-error-in-nfcDemoApp-after-adding-user-stack-on/m-p/2256171#M13880</link>
      <description>&lt;P&gt;Hello&amp;nbsp;&lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/244755"&gt;@Niranjan123&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Please apply the following patch, this issue can be fixed.&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="KaiLi_0-1764942913896.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/368790iA7720C371967A9E4/image-size/medium?v=v2&amp;amp;px=400" role="button" title="KaiLi_0-1764942913896.png" alt="KaiLi_0-1764942913896.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 05 Dec 2025 13:55:22 GMT</pubDate>
      <guid>https://community.nxp.com/t5/NFC/Getting-runtime-error-in-nfcDemoApp-after-adding-user-stack-on/m-p/2256171#M13880</guid>
      <dc:creator>KaiLi</dc:creator>
      <dc:date>2025-12-05T13:55:22Z</dc:date>
    </item>
    <item>
      <title>Re: Getting runtime error in nfcDemoApp after adding user stack on PN7160 (Linux NFC Stack)</title>
      <link>https://community.nxp.com/t5/NFC/Getting-runtime-error-in-nfcDemoApp-after-adding-user-stack-on/m-p/2257219#M13889</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;Thank you for your earlier support.&lt;/P&gt;&lt;P&gt;Our previous error has been resolved, but we are still facing an issue while running the nfcDemoapp.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Niranjan123_1-1765202025521.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/368985iCD7DF9C37F8AA519/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Niranjan123_1-1765202025521.png" alt="Niranjan123_1-1765202025521.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;When we see the main code, the application &lt;STRONG&gt;does not enter InitMode()&lt;/STRONG&gt;. We added debug printf statements to confirm this, and the control simply never reaches inside the InitMode function.&lt;/P&gt;&lt;P&gt;Could you please help explain &lt;STRONG&gt;why the initialization is failing&lt;/STRONG&gt; or what conditions must be met for InitMode() to execute successfully?&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;What we have observed:&lt;/STRONG&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;P&gt;The code builds correctly.&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;Debug prints show that execution stops before entering InitMode.&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;No obvious error logs are printed from the NFC HAL or NCI stack.&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;IRQ and VEN pins appear to be configured correctly, but the behavior suggests something may be blocking initialization.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;If needed, I can share the relevant log snippet and configuration details.&lt;/P&gt;&lt;P&gt;Any guidance on what could cause InitMode to be skipped or fail would be appreciated.&lt;/P&gt;&lt;P&gt;Thank you.&lt;BR /&gt;&lt;BR /&gt;-niranjan&lt;/P&gt;</description>
      <pubDate>Mon, 08 Dec 2025 13:57:36 GMT</pubDate>
      <guid>https://community.nxp.com/t5/NFC/Getting-runtime-error-in-nfcDemoApp-after-adding-user-stack-on/m-p/2257219#M13889</guid>
      <dc:creator>Niranjan123</dc:creator>
      <dc:date>2025-12-08T13:57:36Z</dc:date>
    </item>
  </channel>
</rss>

