<?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>Problem using an external flash together with MCUBOOT</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/107256/problem-using-an-external-flash-together-with-mcuboot</link><description>I have I custom board based on a NRF52832. I also have an external SPI Nor flash I use to store data. 
 I want to add MCUBOOT and don&amp;#39;t use the external flash to store the second image. In fact I use the serial recovery if the DFU fails. 
 If I compile</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Wed, 17 Jan 2024 14:03:56 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/107256/problem-using-an-external-flash-together-with-mcuboot" /><item><title>RE: Problem using an external flash together with MCUBOOT</title><link>https://devzone.nordicsemi.com/thread/464627?ContentTypeID=1</link><pubDate>Wed, 17 Jan 2024 14:03:56 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:e0b7cb7e-d7e8-4bc8-9de5-ffece953c7bb</guid><dc:creator>dejans</dc:creator><description>&lt;p&gt;Hi Paul,&lt;br /&gt;&lt;br /&gt;I am glad to hear that your issue has been resolved. Thank you for the update.&lt;br /&gt;&lt;br /&gt;Best regards,&lt;br /&gt;Dejan&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Problem using an external flash together with MCUBOOT</title><link>https://devzone.nordicsemi.com/thread/464517?ContentTypeID=1</link><pubDate>Wed, 17 Jan 2024 07:53:58 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:8e1cfd5f-c251-4c2a-a6d4-c927ef13a20d</guid><dc:creator>Paul123</dc:creator><description>&lt;p&gt;Hi Dejan,&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;thank you very much for your help adding the chosen option and the three kconfig parameters solved my problem, I really appreciate you effort to help me solve my problem.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Kind regards,&lt;/p&gt;
&lt;p&gt;Paul&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Problem using an external flash together with MCUBOOT</title><link>https://devzone.nordicsemi.com/thread/464448?ContentTypeID=1</link><pubDate>Tue, 16 Jan 2024 15:36:46 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:372c98e4-cb27-447c-8a82-2f37ae4b36d3</guid><dc:creator>dejans</dc:creator><description>&lt;p&gt;Hi Paul,&lt;br /&gt;&lt;br /&gt;You would need to have &amp;quot;chosen&amp;quot; added in an overlay file for both the application and bootloader as it is shown in&amp;nbsp;&lt;a href="https://developer.nordicsemi.com/nRF_Connect_SDK/doc/latest/nrf/scripts/partition_manager/partition_manager.html#external-flash-memory-partitions"&gt;external flash memory partitions&lt;/a&gt;. Since SPI NOR driver requires multithreading support and is required to be enabled in bootloader configuration, you could try to add the following configuration options to your bootloader configuration in &amp;lt;your_project_folder&amp;gt;\child_image\mcuboot.conf&lt;br /&gt;&lt;pre class="ui-code" data-mode="text"&gt;CONFIG_SPI_NOR=y
CONFIG_PM_OVERRIDE_EXTERNAL_DRIVER_CHECK=y
CONFIG_MULTITHREADING=y
&lt;/pre&gt;&lt;br /&gt;Best regards,&lt;br /&gt;Dejan&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Problem using an external flash together with MCUBOOT</title><link>https://devzone.nordicsemi.com/thread/464375?ContentTypeID=1</link><pubDate>Tue, 16 Jan 2024 12:12:03 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:ec892df7-42fd-4e41-afdc-2a0ced57e016</guid><dc:creator>Paul123</dc:creator><description>&lt;p&gt;Hi Dejan,&lt;/p&gt;
&lt;p&gt;I started my project based on different samples such as the peripheral sample, but it grew bigger and bigger. It is basically a BLE project, and the last issue is to add DFU. If I don&amp;#39;t use the SPI Flash the application works fine. But if I want to use the Flash and have DFU function, I get the described compile error.&lt;/p&gt;
&lt;p&gt;What other information do you need?&lt;/p&gt;
&lt;p&gt;Kind Regards&lt;/p&gt;
&lt;p&gt;Paul&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Problem using an external flash together with MCUBOOT</title><link>https://devzone.nordicsemi.com/thread/464359?ContentTypeID=1</link><pubDate>Tue, 16 Jan 2024 10:56:46 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:e3e9df0e-e80a-46ca-bcc2-58f159069352</guid><dc:creator>dejans</dc:creator><description>&lt;p&gt;Hi Paul,&lt;br /&gt;&lt;br /&gt;Is your project based on any of the NCS samples?&lt;br /&gt;&lt;br /&gt;Best regards,&lt;br /&gt;Dejan&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Problem using an external flash together with MCUBOOT</title><link>https://devzone.nordicsemi.com/thread/464294?ContentTypeID=1</link><pubDate>Tue, 16 Jan 2024 06:56:41 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:dc839075-1c2d-4502-ba45-7d438d6ed328</guid><dc:creator>Paul123</dc:creator><description>&lt;p&gt;Hi Dejan,&lt;/p&gt;
&lt;p&gt;I don&amp;#39;t have an overlay file. I made a custom dts file&lt;/p&gt;
&lt;p&gt;Kind regards&lt;/p&gt;
&lt;p&gt;Paul&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Problem using an external flash together with MCUBOOT</title><link>https://devzone.nordicsemi.com/thread/464251?ContentTypeID=1</link><pubDate>Mon, 15 Jan 2024 16:09:31 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:d0ccdf27-ab7a-4001-a7bd-11dfdd9f42f8</guid><dc:creator>dejans</dc:creator><description>&lt;p&gt;Hi Paul,&lt;br /&gt;&lt;br /&gt;Do you have any overlay file?&lt;br /&gt;&lt;br /&gt;Best regards,&lt;br /&gt;Dejan&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Problem using an external flash together with MCUBOOT</title><link>https://devzone.nordicsemi.com/thread/464082?ContentTypeID=1</link><pubDate>Mon, 15 Jan 2024 07:40:29 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b5cf7523-7952-4483-9354-6ec739f33c81</guid><dc:creator>Paul123</dc:creator><description>&lt;p&gt;Hi Dejan,&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;here are the relevant parts of my device tree:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;{

    chosen {
		zephyr,console = &amp;amp;uart0;
		zephyr,shell-uart = &amp;amp;uart0;
		zephyr,uart-mcumgr = &amp;amp;uart0;
		zephyr,bt-mon-uart = &amp;amp;uart0;
		zephyr,bt-c2h-uart = &amp;amp;uart0;
		zephyr,sram = &amp;amp;sram0;
		zephyr,flash = &amp;amp;flash0;
		zephyr,code-partition = &amp;amp;slot0_partition;
	};
	
    aliases {
        spi-flash0 = &amp;amp;mx25r80;
    }
}

&amp;amp;spi1 {
	compatible = &amp;quot;nordic,nrf-spi&amp;quot;;
	status = &amp;quot;okay&amp;quot;;
	cs-gpios = 	&amp;lt; &amp;amp;gpio0 28 GPIO_ACTIVE_LOW&amp;gt;;
	pinctrl-0 = &amp;lt;&amp;amp;spi1_default&amp;gt;;
	pinctrl-1 = &amp;lt;&amp;amp;spi1_sleep&amp;gt;;
	pinctrl-names = &amp;quot;default&amp;quot;, &amp;quot;sleep&amp;quot;;
	mx25r80: mx25r8035f@0 {
		compatible = &amp;quot;jedec,spi-nor&amp;quot;;
		label = &amp;quot;MX25R8035F&amp;quot;;
		reg = &amp;lt;0&amp;gt;;
		spi-max-frequency = &amp;lt;8000000&amp;gt;;
		size = &amp;lt;0x800000&amp;gt;;
		jedec-id = [c2 28 14];
		sfdp-bfp = [
		 	 e5 20 f1 ff  ff ff 7f 00  44 eb 08 6b  08 3b 04 bb
		 	 ee ff ff ff  ff ff 00 ff  ff ff 00 ff  0c 20 0f 52
		 	 10 d8 00 ff  23 72 f5 00  82 ed 04 b7  44 83 38 44
		     30 b0 30 b0  f7 c4 d5 5c  00 be 29 ff  f0 d0 ff ff
		];
		has-dpd;
		t-enter-dpd = &amp;lt; 10000 &amp;gt;;
		t-exit-dpd = &amp;lt; 35000 &amp;gt;;
	};
	
&amp;amp;flash0 {
	partitions {
		compatible = &amp;quot;fixed-partitions&amp;quot;;
		#address-cells = &amp;lt;1&amp;gt;;
		#size-cells = &amp;lt;1&amp;gt;;

		boot_partition: partition@0 {
			label = &amp;quot;mcuboot&amp;quot;;
			reg = &amp;lt;0x0 0xc000&amp;gt;;
		};
		slot0_partition: partition@c000 {
			label = &amp;quot;image-0&amp;quot;;
			reg = &amp;lt;0xc000 0x6de00&amp;gt;;
		};
		slot1_partition: partition@79e00 {
			label = &amp;quot;image-1&amp;quot;;
			reg = &amp;lt;0x79e00 0x100&amp;gt;;
		};
		storage_partition: partition@7a000 {
			label = &amp;quot;storage&amp;quot;;
			reg = &amp;lt;0x7a000 0x6000&amp;gt;;
		};
	};
};&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;Unfortunately I cannot share my whole dts file&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Kind Regards&lt;/p&gt;
&lt;p&gt;Paul&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Problem using an external flash together with MCUBOOT</title><link>https://devzone.nordicsemi.com/thread/464012?ContentTypeID=1</link><pubDate>Fri, 12 Jan 2024 14:58:09 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:8ad18d2d-e57f-4004-8316-c52bd6f2879a</guid><dc:creator>dejans</dc:creator><description>&lt;p&gt;Hi Paul,&lt;br /&gt;&lt;br /&gt;Could you share your dts and overlay files?&lt;br /&gt;&lt;br /&gt;Best regards,&lt;br /&gt;Dejan&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Problem using an external flash together with MCUBOOT</title><link>https://devzone.nordicsemi.com/thread/463936?ContentTypeID=1</link><pubDate>Fri, 12 Jan 2024 09:31:21 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:ca222b46-bd49-4c32-a3bc-ac3f4ca8f3a6</guid><dc:creator>Paul123</dc:creator><description>&lt;p&gt;Hi Dejan,&lt;/p&gt;
&lt;p&gt;I am not sure what line you mean but here is the section of ordinal 90:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;/* Node&amp;#39;s dependency ordinal: */
#define DT_N_S_soc_S_spi_40004000_ORD 90
#define DT_N_S_soc_S_spi_40004000_ORD_STR_SORTABLE 00090

/* Ordinals for what this node depends on directly: */
#define DT_N_S_soc_S_spi_40004000_REQUIRES_ORDS \
	4, /* /soc */ \
	5, /* /soc/interrupt-controller@e000e100 */ \
	9, /* /soc/gpio@50000000 */ \
	28, /* /pin-controller/spi1_default */ \
	30, /* /pin-controller/spi1_sleep */&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;Is this the write code line?&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Kind Regards Paul&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Problem using an external flash together with MCUBOOT</title><link>https://devzone.nordicsemi.com/thread/463932?ContentTypeID=1</link><pubDate>Fri, 12 Jan 2024 09:14:24 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:faa9a5bd-bb11-4f1c-9dcd-9714cd82a6b6</guid><dc:creator>dejans</dc:creator><description>&lt;p&gt;Hi Paul,&lt;br /&gt;&lt;br /&gt;Could you show the line with ordinal 90 from your devicetree_generated.h?&lt;br /&gt;&lt;br /&gt;Best regards,&lt;br /&gt;Dejan&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Problem using an external flash together with MCUBOOT</title><link>https://devzone.nordicsemi.com/thread/463722?ContentTypeID=1</link><pubDate>Thu, 11 Jan 2024 11:22:17 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b54e90f5-f934-4db9-a328-2b1dd7a103a0</guid><dc:creator>Paul123</dc:creator><description>&lt;p&gt;I added CONFIG_BOOTLOADER_MCUBOOT=y in my prf.conf.&lt;/p&gt;
&lt;p&gt;I use ncs v2.5.0&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Kind Regards&lt;/p&gt;
&lt;p&gt;Paul&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Problem using an external flash together with MCUBOOT</title><link>https://devzone.nordicsemi.com/thread/463687?ContentTypeID=1</link><pubDate>Thu, 11 Jan 2024 09:26:59 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:4967a8d4-23ad-4955-944e-ec2815b6d832</guid><dc:creator>dejans</dc:creator><description>&lt;p&gt;Hi Paul,&lt;br /&gt;&lt;br /&gt;It seems that your flash settings are enabled.&lt;br /&gt;&lt;br /&gt;Where did you try to add CONFIG_BOOTLOADER_MCUBOOT=y?&lt;br /&gt;&lt;br /&gt;Which nRF Connect SDK version do you use?&lt;br /&gt;&lt;br /&gt;Best regards,&lt;br /&gt;Dejan&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Problem using an external flash together with MCUBOOT</title><link>https://devzone.nordicsemi.com/thread/463678?ContentTypeID=1</link><pubDate>Thu, 11 Jan 2024 08:49:35 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:f33fc055-588f-4865-8334-b6dbda06410e</guid><dc:creator>Paul123</dc:creator><description>&lt;p&gt;Hi Dejan,&lt;/p&gt;
&lt;p&gt;thank you for your response. How do I enable the flash support in my project?&lt;/p&gt;
&lt;p&gt;my prf.conf looks like this:&lt;/p&gt;
&lt;div style="background-color:#1f1f1f;color:#cccccc;font-family:Consolas, &amp;#39;Courier New&amp;#39;, monospace;font-size:14px;font-weight:normal;line-height:19px;white-space:pre;"&gt;
&lt;div&gt;
&lt;div style="background-color:#1f1f1f;color:#cccccc;font-family:Consolas, &amp;#39;Courier New&amp;#39;, monospace;font-size:14px;font-weight:normal;line-height:19px;white-space:pre;"&gt;
&lt;div&gt;&lt;span style="color:#569cd6;"&gt;CONFIG_SPI&lt;/span&gt;&lt;span style="color:#cccccc;"&gt;=y&lt;/span&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;div&gt;&lt;span style="color:#569cd6;"&gt;CONFIG_FLASH&lt;/span&gt;&lt;span style="color:#cccccc;"&gt;=y&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
&lt;div style="background-color:#1f1f1f;color:#cccccc;font-family:Consolas, &amp;#39;Courier New&amp;#39;, monospace;font-size:14px;font-weight:normal;line-height:19px;white-space:pre;"&gt;
&lt;div&gt;&lt;span style="color:#569cd6;"&gt;CONFIG_FLASH_PAGE_LAYOUT&lt;/span&gt;&lt;span style="color:#cccccc;"&gt;=y&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
&lt;div style="background-color:#1f1f1f;color:#cccccc;font-family:Consolas, &amp;#39;Courier New&amp;#39;, monospace;font-size:14px;font-weight:normal;line-height:19px;white-space:pre;"&gt;
&lt;div&gt;&lt;span style="color:#569cd6;"&gt;CONFIG_FLASH_MAP&lt;/span&gt;&lt;span style="color:#cccccc;"&gt;=y&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
&lt;div style="background-color:#1f1f1f;color:#cccccc;font-family:Consolas, &amp;#39;Courier New&amp;#39;, monospace;font-size:14px;font-weight:normal;line-height:19px;white-space:pre;"&gt;
&lt;div&gt;&lt;span style="color:#569cd6;"&gt;CONFIG_NVS&lt;/span&gt;&lt;span style="color:#cccccc;"&gt;=y&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
&lt;div style="background-color:#1f1f1f;color:#cccccc;font-family:Consolas, &amp;#39;Courier New&amp;#39;, monospace;font-size:14px;font-weight:normal;line-height:19px;white-space:pre;"&gt;
&lt;div&gt;&lt;span style="color:#569cd6;"&gt;CONFIG_SPI_NOR&lt;/span&gt;&lt;span style="color:#cccccc;"&gt;=y&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;&lt;span style="color:#569cd6;"&gt;CONFIG_STDOUT_CONSOLE&lt;/span&gt;&lt;span style="color:#cccccc;"&gt;=y&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
&lt;div style="background-color:#1f1f1f;color:#cccccc;font-family:Consolas, &amp;#39;Courier New&amp;#39;, monospace;font-size:14px;font-weight:normal;line-height:19px;white-space:pre;"&gt;
&lt;div&gt;&lt;span style="color:#569cd6;"&gt;CONFIG_FLASH_JESD216_API&lt;/span&gt;&lt;span style="color:#cccccc;"&gt;=y&lt;/span&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;My project woks with this setup as long as I don&amp;#39;t set&lt;/p&gt;
&lt;div style="background-color:#1f1f1f;color:#cccccc;font-family:Consolas, &amp;#39;Courier New&amp;#39;, monospace;font-size:14px;font-weight:normal;line-height:19px;white-space:pre;"&gt;
&lt;div&gt;&lt;span style="color:#569cd6;"&gt;CONFIG_BOOTLOADER_MCUBOOT&lt;/span&gt;&lt;span style="color:#cccccc;"&gt;=y&lt;/span&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;Do I need to add some defines to mcuboot.conf?&lt;/p&gt;
&lt;p&gt;I tried adding these defines to mcuboot.conf but I still get the compiling error.&lt;/p&gt;
&lt;p&gt;The only thing that works is, if I remove the Flash from my devicetree.dts.&lt;/p&gt;
&lt;p&gt;But then I can&amp;#39;t use the flash at all so this is not an option for me.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Kind Regards&lt;/p&gt;
&lt;p&gt;Paul&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Problem using an external flash together with MCUBOOT</title><link>https://devzone.nordicsemi.com/thread/463586?ContentTypeID=1</link><pubDate>Wed, 10 Jan 2024 14:41:11 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:dba454f2-4ca5-4b06-8067-b131d4429c49</guid><dc:creator>dejans</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
[quote user=""]What does this error mean? Especially what means the error &lt;span style="font-family:courier new, courier;"&gt;undefined reference to `__device_dts_ord_90&amp;#39;&lt;/span&gt;?&amp;nbsp;[/quote]
&lt;p&gt;This is coming from&amp;nbsp;&lt;a href="https://developer.nordicsemi.com/nRF_Connect_SDK/doc/latest/zephyr/build/cmake/index.html"&gt;devicetree_generated.h&lt;/a&gt;&amp;nbsp;located in build/zephyr/include/generated. It might mean that you have not specifically enabled flash support in your project configuration.&lt;br /&gt;&lt;br /&gt;Best regards,&lt;br /&gt;Dejan&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>