<?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>topic Re: BLE stack fails when started from bootloader in MCUXpresso SDK</title>
    <link>https://community.nxp.com/t5/MCUXpresso-SDK/BLE-stack-fails-when-started-from-bootloader/m-p/931920#M1633</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello, &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It would appear that the issue it's in the bootloader as this does not seem to happen in the example applications, are you using your custom board?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Did you use the one I mentioned as a base?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards, &lt;BR /&gt;Estephania&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 10 Jul 2019 21:01:11 GMT</pubDate>
    <dc:creator>stephanie_m</dc:creator>
    <dc:date>2019-07-10T21:01:11Z</dc:date>
    <item>
      <title>BLE stack fails when started from bootloader</title>
      <link>https://community.nxp.com/t5/MCUXpresso-SDK/BLE-stack-fails-when-started-from-bootloader/m-p/931917#M1630</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;My problem is that the BLE stack misbehaves when the application SW is started via a bootloader.&lt;/P&gt;&lt;P&gt;When there is no bootloader (application started directly) BLE works correctly.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The problem: BLE scanning (RX) reports in invalid (gapScannedDevice_t) length, advEventType and payload.&lt;BR /&gt;BLE advertisment (TX) works correctly even when started from bootloader.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is there something RAM address dependent regarding Gap_StartScanning/gapScannedDevice_t parameter?&lt;BR /&gt;Bootloader should be transparent to application, so it considered as a clean start. (stack reset, bss cleared..)&lt;/P&gt;&lt;P&gt;Bootloader seems to be working correctly, also rest of the application too, only the BLE part fails.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Architecture:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Bootloader&lt;/STRONG&gt; (no BLE stack) at flash address: 0x21000000&lt;BR /&gt; jump to app&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;vector_p =&amp;nbsp;0x21019000&lt;/SPAN&gt;&lt;BR /&gt; SCB-&amp;gt;VTOR = vector_p&lt;BR /&gt; __set_MSP(vector_p-&amp;gt;stack_addr);&lt;BR /&gt; vector_p-&amp;gt;resetFunc_p();&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Application&lt;/STRONG&gt; flash address: 0x21019000&lt;BR /&gt; lib_ble_5-0_host_cm4.a&lt;BR /&gt; lib_ble_QN908XC_controller.a&lt;BR /&gt; lib_crypto_m4.a&lt;/P&gt;&lt;P&gt;binary image shifted by 0x&lt;SPAN&gt;19000&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Env&lt;/STRONG&gt;:&lt;BR /&gt;MCU:QN9080x&lt;BR /&gt;MCUXpresso SDK v2.2.0&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 02 Jul 2019 16:57:48 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MCUXpresso-SDK/BLE-stack-fails-when-started-from-bootloader/m-p/931917#M1630</guid>
      <dc:creator>arpad_toth</dc:creator>
      <dc:date>2019-07-02T16:57:48Z</dc:date>
    </item>
    <item>
      <title>Re: BLE stack fails when started from bootloader</title>
      <link>https://community.nxp.com/t5/MCUXpresso-SDK/BLE-stack-fails-when-started-from-bootloader/m-p/931918#M1631</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello, &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can check the bootloader example that we provide in for the OTA example as well as give a check to the BLE Application Developer's Guide.pdf for further details on this.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope that helps.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Estephania&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 03 Jul 2019 15:11:34 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MCUXpresso-SDK/BLE-stack-fails-when-started-from-bootloader/m-p/931918#M1631</guid>
      <dc:creator>stephanie_m</dc:creator>
      <dc:date>2019-07-03T15:11:34Z</dc:date>
    </item>
    <item>
      <title>Re: BLE stack fails when started from bootloader</title>
      <link>https://community.nxp.com/t5/MCUXpresso-SDK/BLE-stack-fails-when-started-from-bootloader/m-p/931919#M1632</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;After a lot of debugging I figured out that calling&lt;STRONG&gt;&amp;nbsp;CALIB_SystemCalib&lt;/STRONG&gt; library function for the 2nd time &lt;STRONG&gt;reduces&lt;/STRONG&gt; the BLE tag report count by 3. (from 30tag/sec to 10)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;First it was called from bootloader, 2nd it was called from application. Digging deeper it is the&amp;nbsp;&lt;STRONG&gt;CALIB_PowerOn();&lt;/STRONG&gt; part&amp;nbsp;that causes this problem.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Reported tags are still valid, but less.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Looks like a library or HW &lt;STRONG&gt;bug.&lt;/STRONG&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 10 Jul 2019 10:13:35 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MCUXpresso-SDK/BLE-stack-fails-when-started-from-bootloader/m-p/931919#M1632</guid>
      <dc:creator>arpad_toth</dc:creator>
      <dc:date>2019-07-10T10:13:35Z</dc:date>
    </item>
    <item>
      <title>Re: BLE stack fails when started from bootloader</title>
      <link>https://community.nxp.com/t5/MCUXpresso-SDK/BLE-stack-fails-when-started-from-bootloader/m-p/931920#M1633</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello, &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It would appear that the issue it's in the bootloader as this does not seem to happen in the example applications, are you using your custom board?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Did you use the one I mentioned as a base?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards, &lt;BR /&gt;Estephania&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 10 Jul 2019 21:01:11 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MCUXpresso-SDK/BLE-stack-fails-when-started-from-bootloader/m-p/931920#M1633</guid>
      <dc:creator>stephanie_m</dc:creator>
      <dc:date>2019-07-10T21:01:11Z</dc:date>
    </item>
    <item>
      <title>Re: BLE stack fails when started from bootloader</title>
      <link>https://community.nxp.com/t5/MCUXpresso-SDK/BLE-stack-fails-when-started-from-bootloader/m-p/931921#M1634</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Sorry I forgot to mention I could reproduce the issue without a bootloader, so in the application I just called&amp;nbsp;&lt;STRONG style="color: #51626f; background-color: #ffffff; border: 0px; font-weight: bold;"&gt;CALIB_SystemCalib &lt;/STRONG&gt;twice, and the find rate went down by 3 times, and it is easy to reproduce.&lt;/P&gt;&lt;P&gt;We use custom board with 32Mhz crystal, but that shouldn't&amp;nbsp;matter.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 11 Jul 2019 08:03:29 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MCUXpresso-SDK/BLE-stack-fails-when-started-from-bootloader/m-p/931921#M1634</guid>
      <dc:creator>arpad_toth</dc:creator>
      <dc:date>2019-07-11T08:03:29Z</dc:date>
    </item>
    <item>
      <title>Re: BLE stack fails when started from bootloader</title>
      <link>https://community.nxp.com/t5/MCUXpresso-SDK/BLE-stack-fails-when-started-from-bootloader/m-p/931922#M1635</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello, &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;What do you mean that you are calling the &lt;STRONG style="color: #51626f; background-color: #ffffff; border: 0px; font-weight: bold;"&gt;CALIB_SystemCalib&amp;nbsp; &lt;/STRONG&gt;twice? Your board design can affect, is this reproducible in the development kit?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards, &lt;BR /&gt;Estephania&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 12 Jul 2019 16:00:04 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MCUXpresso-SDK/BLE-stack-fails-when-started-from-bootloader/m-p/931922#M1635</guid>
      <dc:creator>stephanie_m</dc:creator>
      <dc:date>2019-07-12T16:00:04Z</dc:date>
    </item>
    <item>
      <title>Re: BLE stack fails when started from bootloader</title>
      <link>https://community.nxp.com/t5/MCUXpresso-SDK/BLE-stack-fails-when-started-from-bootloader/m-p/931923#M1636</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is there a way to fully reset&amp;nbsp; the BLE SW stack?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Looks like to retains some data even when jumping to main application (resetting stack, clearing static variables), BLE causing a lot of problem for us.&lt;/P&gt;&lt;P&gt;Doing this doesn't solve the problem:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;void bleWrapper_deinit(void)&lt;BR /&gt;{&lt;BR /&gt; (void) Gap_StopScanning();&lt;BR /&gt; (void) Gap_StopAdvertising();&lt;BR /&gt; BLE_Init(gAppMaxConnections_c);&lt;BR /&gt;}&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 29 Nov 2019 15:20:42 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MCUXpresso-SDK/BLE-stack-fails-when-started-from-bootloader/m-p/931923#M1636</guid>
      <dc:creator>arpad_toth</dc:creator>
      <dc:date>2019-11-29T15:20:42Z</dc:date>
    </item>
  </channel>
</rss>

