<?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>nRF9160 FOTA using sdk2.1.0 and SPM fails to get flash area from ID</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/107726/nrf9160-fota-using-sdk2-1-0-and-spm-fails-to-get-flash-area-from-id</link><description>sdk v2.1.0 
 nRF9160 modem v1.3.5 
 
 Hi, 
 I am changing my application, based on a LWM2M client, from SDK 1.9.1 to SDK 2.1.0 while maintaining the use of SPM. 
 Everything works correctly except when I try to do a FOTA... 
 After completing the image</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Thu, 22 Feb 2024 11:53:16 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/107726/nrf9160-fota-using-sdk2-1-0-and-spm-fails-to-get-flash-area-from-id" /><item><title>RE: nRF9160 FOTA using sdk2.1.0 and SPM fails to get flash area from ID</title><link>https://devzone.nordicsemi.com/thread/470228?ContentTypeID=1</link><pubDate>Thu, 22 Feb 2024 11:53:16 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:f53bc633-1a25-4709-bb34-ba355f168a5f</guid><dc:creator>RicardoCarvalho</dc:creator><description>&lt;p&gt;Hi Jonathan,&lt;/p&gt;
&lt;p&gt;You&amp;#39;re right, there is only this line that references the QSPI in the .config file in the build output files.&lt;/p&gt;
&lt;p&gt;But it seems to me that the problem was really related to the QSPI, I tested this:&lt;/p&gt;
&lt;p&gt;&lt;a href="https://devzone.nordicsemi.com/f/nordic-q-a/94254/external-flash-not-working-with-simple-example-on-nrf9160dk-1-0-0" rel="noopener noreferrer" target="_blank"&gt;If the external flash device is not using the QSPI NOR driver, you must enable CONFIG_PM_OVERRIDE_EXTERNAL_DRIVER_CHECK&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;span class="HwtZe" lang="en"&gt;&lt;span class="jCAhz ChMk0b"&gt;&lt;span class="ryNqvb"&gt;and now the regions.yml file has changed and has this override:&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span class="HwtZe" lang="en"&gt;&lt;span class="jCAhz ChMk0b"&gt;&lt;pre class="ui-code" data-mode="text"&gt;external_flash:
  base_address: 0x0
  default_driver_kconfig: CONFIG_PM_OVERRIDE_EXTERNAL_DRIVER_CHECK
  device: /soc/peripheral@40000000/spi@b000/mx25l6433f@0
  dynamic_partition: null
  name: external_flash
  placement_strategy: start_to_end
  size: 0x800000
flash_primary:
  base_address: 0x0
  default_driver_kconfig: CONFIG_SOC_FLASH_NRF
  device: flash_controller
  dynamic_partition: null
  name: flash_primary
  placement_strategy: complex
  size: 0x100000
otp:
  base_address: 0xff8108
  default_driver_kconfig: &amp;#39;&amp;#39;
  device: &amp;#39;&amp;#39;
  dynamic_partition: null
  name: otp
  placement_strategy: start_to_end
  size: 0x2f4
sram_primary:
  base_address: 0x20000000
  default_driver_kconfig: &amp;#39;&amp;#39;
  device: &amp;#39;&amp;#39;
  dynamic_partition: sram_primary
  name: sram_primary
  placement_strategy: complex
  size: 0x40000&lt;/pre&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;and thus recognizes all areas created in the external flash!&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;However, I still can&amp;#39;t do FOTA but it seems to me that now the problem is related to MCUBoot...&amp;nbsp;&lt;span class="HwtZe" lang="en"&gt;&lt;span class="jCAhz ChMk0b"&gt;&lt;span class="ryNqvb"&gt;&lt;span class="emoticon" data-url="https://devzone.nordicsemi.com/cfs-file/__key/system/emoji/1f61e.svg" title="Disappointed"&gt;&amp;#x1f61e;&lt;/span&gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span class="HwtZe" lang="en"&gt;&lt;span class="jCAhz ChMk0b"&gt;&lt;span class="ryNqvb"&gt;So I&amp;#39;m going to close this case.&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;EDIT: my FOTA problem was resolved by applying this &lt;a href="https://devzone.nordicsemi.com/f/nordic-q-a/93947/nrf9160---mcuboot-fails-to-swap-image-when-using-external-spi-nor-flash-using-spm?ReplyFilter=Answers&amp;amp;ReplySortBy=Answers&amp;amp;ReplySortOrder=Descending"&gt;patch&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Thanks for your help!&lt;/p&gt;
&lt;p&gt;&lt;span class="HwtZe" lang="en"&gt;&lt;span class="jCAhz ChMk0b"&gt;&lt;span class="ryNqvb"&gt;Regards,&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span class="HwtZe" lang="en"&gt;&lt;span class="jCAhz ChMk0b"&gt;&lt;span class="ryNqvb"&gt;Ricardo&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF9160 FOTA using sdk2.1.0 and SPM fails to get flash area from ID</title><link>https://devzone.nordicsemi.com/thread/469285?ContentTypeID=1</link><pubDate>Fri, 16 Feb 2024 14:51:18 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:c83983f0-511a-4624-bbe8-97e7e24c23cf</guid><dc:creator>JONATHAN LL</dc:creator><description>&lt;p&gt;Looks like you configs are correct and the device tree is configured seemingly correct.&amp;nbsp;&lt;br /&gt;&lt;br /&gt;I am not 100% sure how the regions.yml file is generated so not sure where it sources it info from, but can you check the .conf file in your build output files if there is anything named QSPI that is set to Y ?&amp;nbsp;&lt;br /&gt;&lt;br /&gt;There is likely only one line with QSPI and its&amp;nbsp;&lt;/p&gt;
&lt;div&gt;
&lt;div&gt;&lt;code&gt;&lt;span&gt;CONFIG_NORDIC_QSPI_NOR_FLASH_LAYOUT_PAGE_SIZE&lt;/span&gt;&lt;span&gt;=4096&lt;/span&gt;&lt;/code&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;But that should be fine.&amp;nbsp;&lt;br /&gt;&lt;br /&gt;So unless there is no other differences in the regions.yml on the&amp;nbsp;working version and this new update then i think we should not dig to deep on QSPI mention in the .yml file.&amp;nbsp;&amp;nbsp;&lt;br /&gt;&lt;br /&gt;Regards,&lt;br /&gt;Jonathan&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF9160 FOTA using sdk2.1.0 and SPM fails to get flash area from ID</title><link>https://devzone.nordicsemi.com/thread/469015?ContentTypeID=1</link><pubDate>Thu, 15 Feb 2024 12:23:54 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:cffcbff5-30d9-4dc3-b670-688d0e78b895</guid><dc:creator>RicardoCarvalho</dc:creator><description>&lt;p&gt;Hi Jonathan,&lt;/p&gt;
&lt;p&gt;&lt;span class="HwtZe" lang="en"&gt;&lt;span class="jCAhz ChMk0b"&gt;&lt;span class="ryNqvb"&gt;Yes, I still need your help!!!&lt;/span&gt;&lt;/span&gt; &lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span class="HwtZe" lang="en"&gt;&lt;span class="jCAhz ChMk0b"&gt;&lt;span class="ryNqvb"&gt;The behavior is the same for different versions of the modem...&lt;/span&gt;&lt;/span&gt;&lt;span class="jCAhz"&gt;&lt;span class="ryNqvb"&gt; &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span class="HwtZe" lang="en"&gt;&lt;span class="jCAhz ChMk0b"&gt;&lt;span class="ryNqvb"&gt;However, I noticed something else, in the file in build\regions.yml, the external flash is defined as: &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span class="HwtZe" lang="en"&gt;&lt;span class="jCAhz ChMk0b"&gt;&lt;span class="ryNqvb"&gt;default_driver_kconfig: CONFIG_NORDIC_QSPI_NOR&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span class="HwtZe" lang="en"&gt;&lt;span class="jCAhz ChMk0b"&gt;&lt;span class="ryNqvb"&gt;regions.yml:&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="jCAhz"&gt;&lt;span class="ryNqvb"&gt; &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span class="HwtZe" lang="en"&gt;&lt;span class="jCAhz ChMk0b"&gt;&lt;span class="ryNqvb"&gt;&lt;pre class="ui-code" data-mode="text"&gt;external_flash:
  base_address: 0x0
  default_driver_kconfig: CONFIG_NORDIC_QSPI_NOR
  device: /soc/peripheral@40000000/spi@b000/mx25l6433f@0
  dynamic_partition: null
  name: external_flash
  placement_strategy: start_to_end
  size: 0x800000
flash_primary:
  base_address: 0x0
  default_driver_kconfig: CONFIG_SOC_FLASH_NRF
  device: flash_controller
  dynamic_partition: null
  name: flash_primary
  placement_strategy: complex
  size: 0x100000
otp:
  base_address: 0xff8108
  default_driver_kconfig: &amp;#39;&amp;#39;
  device: &amp;#39;&amp;#39;
  dynamic_partition: null
  name: otp
  placement_strategy: start_to_end
  size: 0x2f4
sram_primary:
  base_address: 0x20000000
  default_driver_kconfig: &amp;#39;&amp;#39;
  device: &amp;#39;&amp;#39;
  dynamic_partition: sram_primary
  name: sram_primary
  placement_strategy: complex
  size: 0x40000&lt;/pre&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span class="HwtZe" lang="en"&gt;&lt;span class="jCAhz ChMk0b"&gt;&lt;span class="ryNqvb"&gt;why? The problem may come from here...&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span class="HwtZe" lang="en"&gt;&lt;span class="jCAhz ChMk0b"&gt;&lt;span class="ryNqvb"&gt;The nrf9160 does not support QSPI and the flash I think is configured correctly in the config file:&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span class="HwtZe" lang="en"&gt;&lt;span class="jCAhz ChMk0b"&gt;&lt;span class="ryNqvb"&gt;&lt;pre class="ui-code" data-mode="text"&gt;# External Flash
CONFIG_SPI=y
CONFIG_SPI_NOR=y
CONFIG_SPI_NOR_FLASH_LAYOUT_PAGE_SIZE=4096
CONFIG_SPI_NOR_SFDP_RUNTIME=y
CONFIG_FLASH_JESD216_API=y
CONFIG_SPI_NRFX_RAM_BUFFER_SIZE=32&lt;/pre&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span class="HwtZe" lang="en"&gt;&lt;span class="jCAhz ChMk0b"&gt;&lt;span class="ryNqvb"&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span class="HwtZe" lang="en"&gt;&lt;span class="jCAhz ChMk0b"&gt;&lt;span class="ryNqvb"&gt;Thank you for your help.&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span class="HwtZe" lang="en"&gt;&lt;span class="jCAhz ChMk0b"&gt;&lt;span class="ryNqvb"&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span class="HwtZe" lang="en"&gt;&lt;span class="jCAhz ChMk0b"&gt;&lt;span class="ryNqvb"&gt;Regards,&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span class="HwtZe" lang="en"&gt;&lt;span class="jCAhz ChMk0b"&gt;&lt;span class="ryNqvb"&gt;Ricardo&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF9160 FOTA using sdk2.1.0 and SPM fails to get flash area from ID</title><link>https://devzone.nordicsemi.com/thread/468896?ContentTypeID=1</link><pubDate>Wed, 14 Feb 2024 16:52:37 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:cb498a31-6c58-4b72-9dd9-13371aa84c2b</guid><dc:creator>JONATHAN LL</dc:creator><description>&lt;p&gt;Hi Ricardo, have you had any progress or found a solation or do you still&amp;nbsp; need help?&amp;nbsp;&lt;br /&gt;&lt;br /&gt;Regards,&lt;br /&gt;Jonathan&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF9160 FOTA using sdk2.1.0 and SPM fails to get flash area from ID</title><link>https://devzone.nordicsemi.com/thread/466446?ContentTypeID=1</link><pubDate>Mon, 29 Jan 2024 10:50:38 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:2533ff74-b335-4814-8678-6a7ba3828e80</guid><dc:creator>RicardoCarvalho</dc:creator><description>&lt;p&gt;Hi Jonathan,&lt;/p&gt;
&lt;p&gt;I tested with version mfw 1.3.4 and the results are the same...&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Regards,&lt;/p&gt;
&lt;p&gt;Ricardo&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF9160 FOTA using sdk2.1.0 and SPM fails to get flash area from ID</title><link>https://devzone.nordicsemi.com/thread/466267?ContentTypeID=1</link><pubDate>Fri, 26 Jan 2024 14:44:13 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:cd114c6e-0423-4442-887b-7bb9015da5fb</guid><dc:creator>JONATHAN LL</dc:creator><description>&lt;p&gt;Hi,&lt;br /&gt;&lt;br /&gt;mfw 1.3.5 does not have sdk 2.1.0 listed as compatible(tested) ref:&amp;nbsp;&lt;a href="https://infocenter.nordicsemi.com/topic/comp_matrix_nrf9160/COMP/nrf9160/nrf9160_modem_fw.html?cp=2_1_3_5"&gt;https://infocenter.nordicsemi.com/topic/comp_matrix_nrf9160/COMP/nrf9160/nrf9160_modem_fw.html?cp=2_1_3_5&lt;/a&gt;&amp;nbsp;&lt;br /&gt;Could you try with mfw 1.3.4?&lt;br /&gt;&lt;br /&gt;Regards,&lt;br /&gt;Jonathan&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>