<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://devzone.nordicsemi.com/cfs-file/__key/system/syndication/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>mesh sensor observer sample on nrf52840 USB dongle</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/120490/mesh-sensor-observer-sample-on-nrf52840-usb-dongle</link><description>Hello, 
 
 I am developing a mesh solution when the nrf52840 USB dongle will act as an observer. 
 I am using the mesh sensor observer sample. I am able to build and flash it to the device. 
 But I am unable to make the USB connection stable. I am adding</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Tue, 06 May 2025 12:06:43 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/120490/mesh-sensor-observer-sample-on-nrf52840-usb-dongle" /><item><title>RE: mesh sensor observer sample on nrf52840 USB dongle</title><link>https://devzone.nordicsemi.com/thread/534102?ContentTypeID=1</link><pubDate>Tue, 06 May 2025 12:06:43 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:1f4d3036-c903-48c1-93ff-af6ed4bf2e43</guid><dc:creator>Edvin</dc:creator><description>&lt;p&gt;Hello,&lt;/p&gt;
&lt;p&gt;Sorry for the late reply. It seems like whatever sample you were starting from was not supporting the nRF52840 dongle board.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;I have a dongle that I have soldered on a 10-pin header, so that I can attach an external debugger to it (but I always flash it using the pre-programmed bootloader. I use the debugger only for debugging and RTT logging). I changed all your printk() to LOG_INF(), and enabled RTT logging in prj.conf, and saw that it faulted in some storage related stuff (nvs = non-volatile storage):&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;00&amp;gt; *** Booting nRF Connect SDK v2.9.1-60d0d6c8d42d ***
00&amp;gt; *** Using Zephyr OS v3.7.99-ca954a6216c9 ***
00&amp;gt; [00:00:00.000,366] &amp;lt;inf&amp;gt; app: Initializing...
00&amp;gt; 
00&amp;gt; [00:00:00.000,488] &amp;lt;inf&amp;gt; app: &amp;#226; USB enabled
00&amp;gt; 
00&amp;gt; [00:00:00.004,302] &amp;lt;inf&amp;gt; fs_nvs: No GC Done marker found: restarting gc
00&amp;gt; [00:00:00.004,669] &amp;lt;err&amp;gt; os: ***** BUS FAULT *****
00&amp;gt; [00:00:00.004,669] &amp;lt;err&amp;gt; os:   Imprecise data bus error
00&amp;gt; [00:00:00.004,669] &amp;lt;err&amp;gt; os: r0/a1:  0x200062bc  r1/a2:  0x00000000  r2/a3:  0x00000000
00&amp;gt; [00:00:00.004,699] &amp;lt;err&amp;gt; os: r3/a4:  0x00000000 r12/ip:  0x20004580 r14/lr:  0x0003626b
00&amp;gt; [00:00:00.004,699] &amp;lt;err&amp;gt; os:  xpsr:  0x41000000
00&amp;gt; [00:00:00.004,699] &amp;lt;err&amp;gt; os: Faulting instruction address (r15/pc): 0x00032f6a
00&amp;gt; [00:00:00.004,760] &amp;lt;err&amp;gt; os: &amp;gt;&amp;gt;&amp;gt; ZEPHYR FATAL ERROR 26: Unknown error on CPU 0
00&amp;gt; [00:00:00.004,791] &amp;lt;err&amp;gt; os: Current thread: 0x20004580 (unknown)
00&amp;gt; [00:00:00.340,454] &amp;lt;err&amp;gt; os: Halting system&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;So this triggered when it tried to spin up the BLE stack, because it is dependent on storing some things in flash.&lt;/p&gt;
&lt;p&gt;I thought these were default settings for the board files for the dongle, but apparently it is not. So I found another sample that looked like it was actually tested on the nRF52840 dongle. The sample:&lt;/p&gt;
&lt;p&gt;ncs\nrf\samples\bluetooth\mesh\light_dimmer. If you look in that sample, you can see the file pm_static_nrf52840dongle_nrf52840.yml. It holds information about the nRF5 SDK bootloader that is pre-programmed in the dongle, and tells it where to put the NCS application&amp;#39;s settings partition and so on.&lt;/p&gt;
&lt;p&gt;If you copy that file into your sample it should work. But for reference, I&amp;#39;ll upload what I used to test as well, in case you want to try to attach a debugger for RTT logging. When you see asserts like these, the USB will stop working, and it is not possible to monitor the log about the crash information.&lt;/p&gt;
&lt;p&gt;&lt;a href="https://devzone.nordicsemi.com/cfs-file/__key/communityserver-discussions-components-files/4/mesh_5F00_provisioner_5F00_usb_5F00_2.zip"&gt;devzone.nordicsemi.com/.../mesh_5F00_provisioner_5F00_usb_5F00_2.zip&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Edvin&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: mesh sensor observer sample on nrf52840 USB dongle</title><link>https://devzone.nordicsemi.com/thread/533361?ContentTypeID=1</link><pubDate>Tue, 29 Apr 2025 10:34:51 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:a554421f-4270-45dd-b65e-aa6275f7b22f</guid><dc:creator>bjornolsen</dc:creator><description>&lt;p&gt;Hello again.&lt;br /&gt;&lt;br /&gt;Let me share some code and HEX. it may make things easier.&lt;br /&gt;&lt;br /&gt;This first example is a modified blinky_pwm with USB support.&lt;br /&gt;I have included the code + 2 overlay files, as well as the HEX for nrf52840DK and nrf52840dongle. When I flash it to each device it works 100% as expected. So all&amp;nbsp;is good here.&lt;br /&gt;&lt;br /&gt;&lt;a href="https://devzone.nordicsemi.com/cfs-file/__key/communityserver-discussions-components-files/4/blinky_5F00_usb.zip"&gt;devzone.nordicsemi.com/.../blinky_5F00_usb.zip&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;below you will find the mesh_provisioner sample. I have only added output over UART here. This works 100% for nrf52840DK, but for nrf52840dongle I get no output (frozen device or similar).&amp;nbsp;&lt;br /&gt;&lt;br /&gt;&lt;a href="https://devzone.nordicsemi.com/cfs-file/__key/communityserver-discussions-components-files/4/mesh_5F00_provisioner_5F00_usb.zip"&gt;devzone.nordicsemi.com/.../mesh_5F00_provisioner_5F00_usb.zip&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;This is why I feel that enableing BLE somehow creates a strange problem with nrf52840dongle.&lt;br /&gt;&lt;br /&gt;I am using SDK2.9.1&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: mesh sensor observer sample on nrf52840 USB dongle</title><link>https://devzone.nordicsemi.com/thread/533315?ContentTypeID=1</link><pubDate>Tue, 29 Apr 2025 08:11:19 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:d47b5952-fe98-4234-a338-3874f35e75b4</guid><dc:creator>Edvin</dc:creator><description>[quote user="bjornolsen"]I did not have my&amp;nbsp;debugger at hand[/quote]
&lt;p&gt;But to be clear, you did have a debugger at some point?&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;For me to reproduce this, can you zip and upload the application that you are testing on, so that I can try to reproduce this?&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Edvin&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: mesh sensor observer sample on nrf52840 USB dongle</title><link>https://devzone.nordicsemi.com/thread/532940?ContentTypeID=1</link><pubDate>Fri, 25 Apr 2025 05:07:38 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:7e1dcfdd-f037-4361-89b0-12ba1cb15344</guid><dc:creator>bjornolsen</dc:creator><description>&lt;p&gt;I suspect the issue is that I am using&amp;nbsp;&amp;quot;option 1&amp;quot; from&amp;nbsp;&lt;a id="" href="https://docs.nordicsemi.com/bundle/ncs-latest/page/zephyr/boards/nordic/nrf52840dongle/doc/index.html"&gt;https://docs.nordicsemi.com/bundle/ncs-latest/page/zephyr/boards/nordic/nrf52840dongle/doc/index.html&lt;/a&gt;&amp;nbsp;- then built-in bootloader.&amp;nbsp;&lt;br /&gt;&lt;br /&gt;the perflexiing thing to me is that it seems to work 100% fine except for applications including BLE.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: mesh sensor observer sample on nrf52840 USB dongle</title><link>https://devzone.nordicsemi.com/thread/532912?ContentTypeID=1</link><pubDate>Thu, 24 Apr 2025 19:33:39 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:78f4c916-66b7-443d-bec0-358133faf717</guid><dc:creator>bjornolsen</dc:creator><description>&lt;p&gt;&lt;strong&gt;I have never tried &amp;quot;BOARD_HAS_NRF5_BOOTLOADER=n&amp;quot; (or =y for that matter). But I tried it now&amp;nbsp;&lt;/strong&gt;Hello,&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;We will eventually get to the bottom of this.&amp;nbsp;&lt;br /&gt;&lt;br /&gt;I am using SDK 2.9.&lt;br /&gt;&lt;br /&gt;I can program the USB dongle using &amp;quot;nRF Connect for Desktop BLE&amp;quot;. Then the BLE works fine for the dongle. So yes, BLE does work on the dongle - this I know.&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;
&lt;p&gt;Here is the programmer after I have programmed it in &amp;quot;nRF Connect for Desktop BLE&amp;quot;. There is a nice soft device here, and it looks tidy. This of course works.&lt;br /&gt;&lt;br /&gt;&lt;img style="max-height:240px;max-width:320px;" src="https://devzone.nordicsemi.com/resized-image/__size/640x480/__key/communityserver-discussions-components-files/4/pastedimage1745522291547v1.png" alt=" " /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;I have never tried &amp;quot;BOARD_HAS_NRF5_BOOTLOADER=n&amp;quot; (or =y for that matter). But I tried it now and I get &amp;quot;prj.conf:99: warning: ignoring malformed line &amp;#39;BOARD_HAS_NRF5_BOOTLOADER=n&amp;#39;&amp;quot;.&amp;nbsp;&lt;br /&gt;&lt;br /&gt;When I flash my USB dongle with my own program - e.g.&amp;nbsp;with BLE&amp;nbsp;I cannot read it since it crashes at bootup... but after I reset the device (reset = pressing the button on the side), it looks like this.&lt;br /&gt;&lt;br /&gt;&lt;img style="max-height:240px;max-width:320px;" src="https://devzone.nordicsemi.com/resized-image/__size/640x480/__key/communityserver-discussions-components-files/4/pastedimage1745522949822v2.png" alt=" " /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;I did not have my&amp;nbsp;debugger at hand - but I cannot see how that would help since the&amp;nbsp;device dies when I flash it with BLE (when I use my own code).&lt;br /&gt;&lt;br /&gt;Right now I have programmed the dongle with a non-BLE application, which works 100%.&amp;nbsp;&lt;br /&gt;&lt;br /&gt;So something is clearly strange.&lt;br /&gt;&lt;br /&gt;maybe I can program it with &amp;quot;&lt;span&gt;nRF Connect for Desktop BLE&lt;/span&gt;&amp;quot;, and then somehow replace just the application. ..&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: mesh sensor observer sample on nrf52840 USB dongle</title><link>https://devzone.nordicsemi.com/thread/532686?ContentTypeID=1</link><pubDate>Wed, 23 Apr 2025 22:11:55 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:f34e8e3d-223b-4138-b67c-c0b98c4b31fc</guid><dc:creator>Edvin</dc:creator><description>&lt;p&gt;I understand that you are struggling when the BLE stack is enabled, but there are no issues using BLE on the dongle, in itself. I am trying to figure out what causes the BLE stack to fail during initialization. That is why I am asking all these seemingly unrelated questions.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Can you please try this for me. Connect your debugger (like you already have), and open nRF Connect for Desktop -&amp;gt; Programmer, select your programmer/debugger from the drop-down menu on the top left, and select &amp;quot;Read&amp;quot;:&lt;/p&gt;
&lt;p&gt;&lt;img style="max-height:240px;max-width:320px;" src="https://devzone.nordicsemi.com/resized-image/__size/640x480/__key/communityserver-discussions-components-files/4/pastedimage1745445923692v1.png" alt=" " /&gt;&lt;/p&gt;
&lt;p&gt;This should provide some coloured stripes as shown on the right hand side in that screenshot.&amp;nbsp; What is currently present there? Feel free to also click &amp;quot;save to file&amp;quot; and upload it here, then I can investigate a bit more.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Note that this one is not from a dongle with a bootloader. It is just a DK with some simple application.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;If the bootloader is in fact deleted, you need to decide whether you want to program it back in (I don&amp;#39;t have it at hand, but I can find it). Or you need to make sure to add &amp;quot;&lt;span&gt;CONFIG_BOARD_HAS_NRF5_BOOTLOADER=n&amp;quot; to your prj.conf, when building for the target board nrf52840dongle/nrf52840.&amp;nbsp;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Are you currently building with CONFIG_BOARD_HAS_NRF5_BOOTLOADER=n, or not? Because the fact that the dongle is booting in the first place suggests that either&amp;nbsp;CONFIG_BOARD_HAS_NRF5_BOOTLOADER=y (default value when building for the dongle), then the application (with or without softdevice) wouldn&amp;#39;t start, unless the bootloader was present. Alternatively, you would not be able to flash it using &amp;quot;nrfutil dfu usb ...&amp;quot;&amp;nbsp;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;But if possible: upload the &amp;quot;save as file&amp;quot; .hex file, and zip and upload the application that you are currently testing. I assume you are still using NCS v2.9.0.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Best regards,&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Edvin&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: mesh sensor observer sample on nrf52840 USB dongle</title><link>https://devzone.nordicsemi.com/thread/532600?ContentTypeID=1</link><pubDate>Wed, 23 Apr 2025 12:30:37 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:741d3ca0-30ae-4ccf-bbd5-c3a13aaf1abe</guid><dc:creator>bjornolsen</dc:creator><description>&lt;p&gt;Hello.&lt;br /&gt;&lt;br /&gt;To be honest, I am not sure if I erase(d) the pre-programmed bootloader.&lt;br /&gt;All I do is to build a HEX file and the load it the the USB dongle. I do this using nrfutil and also using the programming tool.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;For simple programs (that do NOT include BLE), the dongle works 100% fine. The issue is when I enable BLE (or try to run a BLE sample out of the box) this causes the dongle to crash.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;*** Booting Mesh Sensor Observer v2.9.1-31d0e132576e ***
*** Using nRF Connect SDK v2.9.1-60d0d6c8d42d ***
*** Using Zephyr OS v3.7.99-ca954a6216c9 ***
Initializing...
[00:00:00.010,620] &amp;lt;err&amp;gt; os: ***** BUS FAULT *****
[00:00:00.010,620] &amp;lt;err&amp;gt; os:   Imprecise data bus error
[00:00:00.010,650] &amp;lt;err&amp;gt; os: r0/a1:  0x000000c3  r1/a2:  0x00000000  r2/a3:  0x00000003
[00:00:00.010,650] &amp;lt;err&amp;gt; os: r3/a4:  0x00000012 r12/ip:  0xaaaaaaaa r14/lr:  0x0001f349
[00:00:00.010,681] &amp;lt;err&amp;gt; os:  xpsr:  0x81000000
[00:00:00.010,681] &amp;lt;err&amp;gt; os: Faulting instruction address (r15/pc): 0x0001f2ea
[00:00:00.010,711] &amp;lt;err&amp;gt; os: &amp;gt;&amp;gt;&amp;gt; ZEPHYR FATAL ERROR 26: Unknown error on CPU 0
[00:00:00.010,772] &amp;lt;err&amp;gt; os: Current thread: 0x20003820 (shell_uart)
[00:00:00.303,955] &amp;lt;err&amp;gt; fatal_error: Resetting system&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;(log when I added my J-LINK)&lt;/p&gt;
&lt;p&gt;Yes&amp;nbsp;I may need a &amp;quot;correct&amp;quot; bootloader if that is the issue, but how?&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Bjorn&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: mesh sensor observer sample on nrf52840 USB dongle</title><link>https://devzone.nordicsemi.com/thread/532593?ContentTypeID=1</link><pubDate>Wed, 23 Apr 2025 12:18:28 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:33dc67b6-5585-450f-8139-ec7946f4fd5a</guid><dc:creator>Edvin</dc:creator><description>[quote user="bjornolsen"]including using a&amp;nbsp;J-Link to follow what is happening[/quote]
&lt;p&gt;Did you erase the pre-programmed bootloader on the dongle? Or how did you flash the firmware that you are debugging?&lt;/p&gt;
&lt;p&gt;BR,&lt;br /&gt;Edvin&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: mesh sensor observer sample on nrf52840 USB dongle</title><link>https://devzone.nordicsemi.com/thread/532424?ContentTypeID=1</link><pubDate>Tue, 22 Apr 2025 17:16:54 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:e80cab74-57c2-4b23-9489-a2f3d64ca2ca</guid><dc:creator>bjornolsen</dc:creator><description>&lt;p&gt;Hello,&lt;br /&gt;&lt;br /&gt;Thank you for your reply. But as you can see from the correspondance I have already tried all of this.&lt;br /&gt;I am able to build and run all sorts of applications on nrf52DK, nrf52840DK and nrf54L15.&lt;br /&gt;&lt;br /&gt;I can also run programs on nrf52840dongle/nrf52840 - BUT. I am completly unable to run anything that activates BLE on the dongle -&amp;gt; it crashes (as you see above). I have done what I can do debug - including using a&amp;nbsp;J-Link to follow what is happening (see above).&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Can you please try to replicate this (just flash any ble sample onto the nrf52840dongle)?&lt;br /&gt;&lt;br /&gt;I would be very grateful if you could help solve this mystery.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Bjorn&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: mesh sensor observer sample on nrf52840 USB dongle</title><link>https://devzone.nordicsemi.com/thread/532070?ContentTypeID=1</link><pubDate>Wed, 16 Apr 2025 19:37:27 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:fbc227ab-0918-499b-9a4f-bf481d4ecff8</guid><dc:creator>Edvin</dc:creator><description>&lt;p&gt;Hello Bjorn,&lt;/p&gt;
&lt;p&gt;Håkon is currently out of office.&lt;/p&gt;
[quote user="bjornolsen"]- I am using &amp;quot;nRF52840 Dongle nRF52840&amp;quot; as my target - correct?[/quote]
&lt;p&gt;I assume you mean &amp;quot;nrf52840dongle/nrf52840&amp;quot; as your build target, right?&lt;/p&gt;
[quote user="bjornolsen"]2) I am flashing it incorrectly:[/quote]
&lt;p&gt;Can you try flashing it with &lt;a href="https://www.nordicsemi.com/Products/Development-tools/nRF-Connect-for-Desktop"&gt;nRF Connect for Desktop&lt;/a&gt; -&amp;gt; Programmer, just to see if it makes any difference? Then you can just use the .hex file.&lt;/p&gt;
[quote user="bjornolsen"]3) The ble soft device of the nrf52840 USB dongle has issues or is not compatible with SDK 2.9[/quote]
&lt;p&gt;I don&amp;#39;t think that is the issue.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;The challenge when developing directly on the dongle is that you don&amp;#39;t have a debugger. This also indirectly means no reliable logger. As you can see, whenever the application crashes, the USB will stop working, and you are not able to transmit the log to your terminal.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Do you have access to a DK? If so, I highly recommend that you try to run this application on that one, and then later port the application to your dongle. This will probably save you a lot of time.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Edvin&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: mesh sensor observer sample on nrf52840 USB dongle</title><link>https://devzone.nordicsemi.com/thread/531593?ContentTypeID=1</link><pubDate>Sun, 13 Apr 2025 06:07:27 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:02999297-c8d7-4c62-8fce-25a5433dba7e</guid><dc:creator>bjornolsen</dc:creator><description>&lt;p&gt;Hi H&amp;aring;kon,&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;
&lt;p&gt;I have&amp;nbsp;removed all build folders. Then I did a fresh build and flashed nrf52DK - works 100%. Fresh build and flash nrf52840DK - works 100%. In both these cases the BLE starts up with no problem.&lt;br /&gt;&lt;br /&gt;however with nrf52840 USB dongle it crashes every time when BLE starts. This is consistent for all&amp;nbsp;use of BLE on this HW.&amp;nbsp;&lt;br /&gt;&lt;br /&gt;From what I understand there are 3 possible issues&lt;br /&gt;1) My build configuration is wrong: &lt;br /&gt;- I am using &amp;quot;nRF52840 Dongle nRF52840&amp;quot; as my target - correct?&lt;br /&gt;2) I am flashing it incorrectly:&lt;br /&gt;- I am doing this &amp;quot;nrfutil nrf5sdk-tools pkg generate --hw-version 52 --sd-req=0x00 --application .\merged.hex --application-version 1 mesh_provisioner.zip;nrfutil device program --firmware mesh_provisioner.zip --traits nordicDfu&amp;quot;&amp;nbsp; &amp;nbsp; &amp;nbsp;Seems to flash fine&lt;br /&gt;3) The ble soft device of the nrf52840 USB dongle has issues or is not compatible with SDK 2.9&lt;br /&gt;- here I do not know what to do&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;It would be great if you could try to flash the nrf52840 USB dongle and see if it works on your side.&amp;nbsp;&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;
&lt;p&gt;Bjorn&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: mesh sensor observer sample on nrf52840 USB dongle</title><link>https://devzone.nordicsemi.com/thread/531394?ContentTypeID=1</link><pubDate>Thu, 10 Apr 2025 14:31:55 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:f10124d5-a834-4e9d-9e16-24c9b0a4225f</guid><dc:creator>H&amp;#229;kon Alseth</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;I took the stock mesh/sensor_client sample, compiled it for the nrf52840dongle/nrf52840, and got this output:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;--- 3 messages dropped ---
*** Booting Mesh Sensor Observer v2.9.1-60d0d6c8d42d ***
*** Using nRF Connect SDK v2.9.1-60d0d6c8d42d ***
*** Using Zephyr OS v3.7.99-ca954a6216c9 ***
Initializing...
[00:00:00.010,253] &amp;lt;inf&amp;gt; fs_nvs: 8 Sectors of 4096 bytes
[00:00:00.010,253] &amp;lt;inf&amp;gt; fs_nvs: alloc wra: 0, fe8
[00:00:00.010,284] &amp;lt;inf&amp;gt; fs_nvs: data wra: 0, 0
[00:00:00.010,681] &amp;lt;inf&amp;gt; bt_sdc_hci_driver: SoftDevice Controller build revision: 
                                            79 a3 10 be e6 80 b7 e9  a3 ba cc a9 fc 08 66 12 |y....... ......f.
                                            90 cf 45 a9                                      |..E.             
[00:00:00.014,282] &amp;lt;inf&amp;gt; bt_hci_core: HW Platform: Nordic Semiconductor (0x0002)
[00:00:00.014,343] &amp;lt;inf&amp;gt; bt_hci_core: HW Variant: nRF52x (0x0002)
[00:00:00.014,373] &amp;lt;inf&amp;gt; bt_hci_core: Firmware: Standard Bluetooth controller (0x00) Version 121.4259 Build 3078678206
[00:00:00.014,709] &amp;lt;inf&amp;gt; bt_hci_core: No ID address. App must call settings_load()
Bluetooth initialized
[00:00:00.277,740] &amp;lt;inf&amp;gt; bt_hci_core: Identity: FD:1C:5D:F7:F9:9A (random)
[00:00:00.277,801] &amp;lt;inf&amp;gt; bt_hci_core: HCI: version 6.0 (0x0e) revision 0x109a, manufacturer 0x0059
uart:~$ 
&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;I do not have a dongle readily available, so I had to configure &amp;quot;CONFIG_BOARD_HAS_NRF5_BOOTLOADER=n&amp;quot; and ran this on a nRF52840-DK.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Added your suggested config, ie. appending these to prj.conf:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;CONFIG_LOG=y
CONFIG_USE_SEGGER_RTT=y
CONFIG_LOG_BACKEND_RTT=y&lt;/pre&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Then I get the RTT output:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;00&amp;gt; *** Booting Mesh Sensor Observer v2.9.1-60d0d6c8d42d ***
00&amp;gt; *** Using nRF Connect SDK v2.9.1-60d0d6c8d42d ***
00&amp;gt; *** Using Zephyr OS v3.7.99-ca954a6216c9 ***
00&amp;gt; Initializing...
00&amp;gt; [00:00:00.009,246] &amp;lt;inf&amp;gt; fs_nvs: 8 Sectors of 4096 bytes
00&amp;gt; [00:00:00.009,277] &amp;lt;inf&amp;gt; fs_nvs: alloc wra: 0, fb8
00&amp;gt; [00:00:00.009,277] &amp;lt;inf&amp;gt; fs_nvs: data wra: 0, 4c
00&amp;gt; [00:00:00.009,643] &amp;lt;inf&amp;gt; bt_sdc_hci_driver: SoftDevice Controller build revision: 
00&amp;gt;                                             79 a3 10 be e6 80 b7 e9  a3 ba cc a9 fc 08 66 12 |y....... ......f.
00&amp;gt;                                             90 cf 45 a9                                      |..E.             
00&amp;gt; [00:00:00.013,275] &amp;lt;inf&amp;gt; bt_hci_core: HW Platform: Nordic Semiconductor (0x0002)
00&amp;gt; [00:00:00.013,305] &amp;lt;inf&amp;gt; bt_hci_core: HW Variant: nRF52x (0x0002)
00&amp;gt; [00:00:00.013,336] &amp;lt;inf&amp;gt; bt_hci_core: Firmware: Standard Bluetooth controller (0x00) Version 121.4259 Build 3078678206
00&amp;gt; [00:00:00.013,702] &amp;lt;inf&amp;gt; bt_hci_core: No ID lized&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Have you tried removing your build folder and regenerating the build itself?&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Kind regards,&lt;/p&gt;
&lt;p&gt;Håkon&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: mesh sensor observer sample on nrf52840 USB dongle</title><link>https://devzone.nordicsemi.com/thread/531223?ContentTypeID=1</link><pubDate>Wed, 09 Apr 2025 14:58:21 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:663d6d5a-4ade-4298-b0be-8cc3b46a5765</guid><dc:creator>bjornolsen</dc:creator><description>&lt;p&gt;Hello.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;hm. I connected my SEGGER J-link to the nrf52840 dongle.&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;
&lt;p&gt;I take the plain sensor_client example, and I add this for the logger (nothing else)&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;CONFIG_LOG=y
CONFIG_USE_SEGGER_RTT=y
CONFIG_LOG_BACKEND_RTT=y&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;It crashes when the BLE is initialized.&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;*** Booting Mesh Sensor Observer v2.9.1-31d0e132576e ***
*** Using nRF Connect SDK v2.9.1-60d0d6c8d42d ***
*** Using Zephyr OS v3.7.99-ca954a6216c9 ***
Initializing...
[00:00:00.010,620] &amp;lt;err&amp;gt; os: ***** BUS FAULT *****
[00:00:00.010,620] &amp;lt;err&amp;gt; os:   Imprecise data bus error
[00:00:00.010,650] &amp;lt;err&amp;gt; os: r0/a1:  0x000000c3  r1/a2:  0x00000000  r2/a3:  0x00000003
[00:00:00.010,650] &amp;lt;err&amp;gt; os: r3/a4:  0x00000012 r12/ip:  0xaaaaaaaa r14/lr:  0x0001f349
[00:00:00.010,681] &amp;lt;err&amp;gt; os:  xpsr:  0x81000000
[00:00:00.010,681] &amp;lt;err&amp;gt; os: Faulting instruction address (r15/pc): 0x0001f2ea
[00:00:00.010,711] &amp;lt;err&amp;gt; os: &amp;gt;&amp;gt;&amp;gt; ZEPHYR FATAL ERROR 26: Unknown error on CPU 0
[00:00:00.010,772] &amp;lt;err&amp;gt; os: Current thread: 0x20003820 (shell_uart)
[00:00:00.303,955] &amp;lt;err&amp;gt; fatal_error: Resetting system&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;I then removed&amp;nbsp;RTT configuration (basic sensor observer samble). I only added to turn on a led just to see if it stays on after ble starts.&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;int main(void)
{
	gpio_pin_configure_dt(&amp;amp;led0, GPIO_OUTPUT_INACTIVE);
	gpio_pin_set_dt(&amp;amp;led0, 1);
	int err;

	printk(&amp;quot;Initializing...\n&amp;quot;);
	k_msleep(1000);

	err = bt_enable(bt_ready);
	if (err) {
		printk(&amp;quot;Bluetooth init failed (err %d)\n&amp;quot;, err);
	}

	return 0;
}&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;But it does not. My&amp;nbsp;conclusion is that hte Mesh Sensor Observer samble does not work on nrf52840 usb dongle with SDK 2.9.1&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: mesh sensor observer sample on nrf52840 USB dongle</title><link>https://devzone.nordicsemi.com/thread/530811?ContentTypeID=1</link><pubDate>Mon, 07 Apr 2025 12:15:56 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:729d0eae-b6a0-456b-9679-eaf1e7ddc0e2</guid><dc:creator>H&amp;#229;kon Alseth</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Setup your project with CONFIG_RESET_ON_FATAL_ERROR=n and attach your debugger.&lt;/p&gt;
&lt;p&gt;It should then show a fault on the call stack.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Look then at one of the frames in fault.c (z_arm_fault or&amp;nbsp;fault_handle) and read out the *esf variable.&lt;/p&gt;
&lt;p&gt;Use the contents of this to check where the fault occurred via addr2line:&lt;/p&gt;
&lt;p&gt;addr2line -e build/my_project/zephyr/zephyr.elf 0xFAULTING_ADDR&lt;/p&gt;
&lt;p&gt;Use the LR and PC.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;The depth of the call stack can, in some cases, also show the faulting module/src.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Kind regards,&lt;/p&gt;
&lt;p&gt;Håkon&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: mesh sensor observer sample on nrf52840 USB dongle</title><link>https://devzone.nordicsemi.com/thread/530806?ContentTypeID=1</link><pubDate>Mon, 07 Apr 2025 11:58:17 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:ea43bee3-587a-4fd6-92bf-99d1bd553690</guid><dc:creator>bjornolsen</dc:creator><description>&lt;p&gt;Hi H&amp;aring;kon.&lt;br /&gt;&lt;br /&gt;I&amp;nbsp;increased the stack size several times -&amp;nbsp;same issue.&lt;br /&gt;I guess the problem is that BLE&amp;nbsp;somehow interfers with the UART console.&lt;br /&gt;It clear that it is doing a soft reset.&lt;br /&gt;&lt;br /&gt;It is not absolutely required to use the usb for the logger (although that would be nice).&amp;nbsp;However, I do need to be able to communicate with the USB device.&lt;br /&gt;&lt;br /&gt;All suggestions are welcome.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: mesh sensor observer sample on nrf52840 USB dongle</title><link>https://devzone.nordicsemi.com/thread/530796?ContentTypeID=1</link><pubDate>Mon, 07 Apr 2025 11:27:32 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:31af488e-d736-4b88-b6fc-e21786e22de7</guid><dc:creator>H&amp;#229;kon Alseth</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Since you are using usb for your logger, I assume that this line:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;⚠️ Serial error: ClearCommError failed (PermissionError(13, &amp;#39;The device does not recognize the command.&amp;#39;, None, 22))&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;Occurs due to an assertion (where the default behavior is a soft-reset). This&amp;nbsp;then masks out the assertion log.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;My first guess would be a stack overflow, so try to adjust the CONFIG_MAIN_STACK_SIZE and see if the issue still occurs.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Kind regards,&lt;/p&gt;
&lt;p&gt;Håkon&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>