<?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>How to configure Settings?</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/114760/how-to-configure-settings</link><description>Hello, 
 I have the task to persistently store some (2) configuration values in a Zephyr application (Nordic Version). The final version contains some external flash memory, will make use of MCUBoot, and Bluetooth (LE). The configuration values should</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Fri, 27 Sep 2024 08:42:39 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/114760/how-to-configure-settings" /><item><title>RE: How to configure Settings?</title><link>https://devzone.nordicsemi.com/thread/504123?ContentTypeID=1</link><pubDate>Fri, 27 Sep 2024 08:42:39 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:c9e93e52-8ddc-441b-bdf9-f51e0bf9a3df</guid><dc:creator>Einar Thorsrud</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;There are (probably too) many dependencies which makes things like this a bit tricky in general, so it makes sense to set&amp;nbsp;&lt;code&gt;CONFIG_NORDIC_QSPI_NOR=n&lt;/code&gt; on your end. I agee that needing to disable something you never ment to enable in the first place is not very elegant, but in the end the key is that the generated .config file is correct.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to configure Settings?</title><link>https://devzone.nordicsemi.com/thread/503942?ContentTypeID=1</link><pubDate>Thu, 26 Sep 2024 10:50:36 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:f0d6f4fd-4f56-4990-a934-2e350403b10a</guid><dc:creator>Torsten Robitzki</dc:creator><description>&lt;p&gt;I&amp;#39;m on a local branch, that is based on 2.7, but contains a lot of commits after 2.7. I could update to 2.8 and see, if my required fixes are included and then report, if that also fix this issue.&lt;/p&gt;
&lt;p&gt;Here is the configuration:&lt;pre class="ui-code" data-mode="text"&gt;# Temporary workaround for https://devzone.nordicsemi.com/f/nordic-q-a/107445/colon-in-soc_cpu_idle-h-leads-to-failing-build-with-arm-none-eabi-gcc-version-12-2
CONFIG_SOC_NRF53_ANOMALY_168_WORKAROUND=n

# drivers/external_pin.cpp is defining the GPIOTE interrupt handler
CONFIG_GPIO_NRFX_INTERRUPT=n

# Enable support for C++
CONFIG_CPP=y
CONFIG_REQUIRES_FULL_LIBCPP=y
CONFIG_NEWLIB_LIBC=y
CONFIG_STD_CPP20=y

CONFIG_MAIN_STACK_SIZE=16384

CONFIG_LOG=y
CONFIG_USE_SEGGER_RTT=y
CONFIG_LOG_BACKEND_RTT=y
CONFIG_LOG_BACKEND_UART=n
CONFIG_LOG_MODE_MINIMAL=n
CONFIG_LOG_PRINTK=y
CONFIG_LOG_MODE_DEFERRED=y
CONFIG_LOG_BUFFER_SIZE=16384

CONFIG_MBEDTLS_PSA_CRYPTO_C=y
CONFIG_NRF_SECURITY=y
CONFIG_PSA_CRYPTO_DRIVER_CC3XX=y
CONFIG_PSA_WANT_ALG_SHA_256=y

CONFIG_I2C=y

# USB
CONFIG_USB_DEVICE_STACK=y
CONFIG_USB_DEVICE_PRODUCT=&amp;quot;Lovelace Pod&amp;quot;
CONFIG_USB_DEVICE_PID=0x0001
CONFIG_USB_DRIVER_LOG_LEVEL_ERR=y
CONFIG_USB_DEVICE_LOG_LEVEL_ERR=y
CONFIG_USB_DEVICE_INITIALIZE_AT_BOOT=n
CONFIG_UART_INTERRUPT_DRIVEN=y
CONFIG_UART_LINE_CTRL=y

# MQTT
CONFIG_MQTT_SN_LIB=y
CONFIG_NETWORKING=y
CONFIG_MQTT_SN_LOG_LEVEL_DBG=y

# Analogue Frontend uses ZERO_LATENCY IRQs to call the SPI preparation callbacks
CONFIG_ZERO_LATENCY_IRQS=y

# For debugging only!
#CONFIG_LOG_MODE_IMMEDIATE=n
CONFIG_RESET_ON_FATAL_ERROR=n
CONFIG_ASSERT=y

# Bootloader
#CONFIG_BOOTLOADER_MCUBOOT=y

# Enable SMP Server
#CONFIG_MCUMGR=y
#CONFIG_MCUMGR_GRP_IMG=y

# CONFIG_MCUMGR_GRP_IMG dependencies
#CONFIG_FLASH=y
#CONFIG_IMG_MANAGER=y

# CONFIG_IMG_MANAGER dependencies
#CONFIG_STREAM_FLASH=y

# CONFIG_MCUMGR dependencies
#CONFIG_NET_BUF=y
#CONFIG_ZCBOR=y

#CONFIG_MCUBOOT_BUILD_STRATEGY_FROM_SOURCE=y
#CONFIG_MCUBOOT_USE_ALL_AVAILABLE_RAM=y
#CONFIG_NRF53_UPGRADE_NETWORK_CORE=y
#CONFIG_UPDATEABLE_IMAGE_NUMBER=2
#CONFIG_ADD_MCUBOOT_MEDIATE_SIM_FLASH_DTS=y

# Storing configuration values
CONFIG_FLASH=y
CONFIG_NVS=y
# Required to actually use the NVS backend, conflicts with QSPI usage:
# https://devzone.nordicsemi.com/f/nordic-q-a/114760/how-to-configure-settings
CONFIG_FLASH_MAP=y
CONFIG_SETTINGS=y
CONFIG_SETTINGS_NVS=y
CONFIG_NORDIC_QSPI_NOR=n

# Bluetooth
CONFIG_BT=y
CONFIG_BT_PERIPHERAL=y
CONFIG_BT_DEVICE_NAME=&amp;quot;Lovelace Pod&amp;quot;
#CONFIG_NCS_SAMPLE_MCUMGR_BT_OTA_DFU=y
&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;I would love to get rid of the `CONFIG_NORDIC_QSPI_NOR=n` configuration, or in general, I would love to get rid of all unused drivers (as back in the good old days where library where statically linked ;-) )&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to configure Settings?</title><link>https://devzone.nordicsemi.com/thread/503886?ContentTypeID=1</link><pubDate>Thu, 26 Sep 2024 07:55:45 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:0c2f2c3c-fe7d-4938-a91a-5a707dedb398</guid><dc:creator>Einar Thorsrud</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;Which SDK version are you using, and can you share all your Kconfigs? If you use &lt;a href="https://docs.nordicsemi.com/bundle/ncs-latest/page/kconfig/index.html#CONFIG_NCS_SAMPLE_MCUMGR_BT_OTA_DFU"&gt;CONFIG_NCS_SAMPLE_MCUMGR_BT_OTA_DFU&lt;/a&gt;=y that&amp;nbsp;implies CONFIG_NORDIC_QSPI_NOR also in nRF Connect SDK 2.7, but that will be fixed in 2.8 (and is fixed in main).&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to configure Settings?</title><link>https://devzone.nordicsemi.com/thread/503377?ContentTypeID=1</link><pubDate>Mon, 23 Sep 2024 09:33:15 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:43e03cca-cbf6-482d-997d-4438b1ad9c7d</guid><dc:creator>Torsten Robitzki</dc:creator><description>&lt;p&gt;&lt;span&gt;The resulting `build/zephyr/zephyr.dts` has a `qspi` node, with the `status` attribute set to `disabled`. However, the resulting kconfig&amp;nbsp;(`build/zephyr/.config`) contains this entry: `CONFIG_DT_HAS_NORDIC_QSPI_NOR_ENABLED=y`.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Further more, it contains directly has the `CONFIG_NORDIC_QSPI_NOR` flag set to `y`:&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;pre class="ui-code" data-mode="text"&gt;...
#
# Nordic nRF Connect
#
CONFIG_WARN_EXPERIMENTAL=y
CONFIG_BT_BUF_CMD_TX_COUNT=10
CONFIG_INIT_ARCH_HW_AT_BOOT=y
CONFIG_NORDIC_QSPI_NOR=y
...&lt;/pre&gt;&lt;br /&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;The &amp;quot;Nordic nRF Connect&amp;quot; text comes from the nrf/Kconfig.nrf file, which, at the end, also includes:&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;pre class="ui-code" data-mode="text"&gt;rsource &amp;quot;samples/Kconfig&amp;quot;
rsource &amp;quot;subsys/Kconfig&amp;quot;
rsource &amp;quot;modules/Kconfig&amp;quot;
rsource &amp;quot;lib/Kconfig&amp;quot;
rsource &amp;quot;drivers/Kconfig&amp;quot;
rsource &amp;quot;ext/Kconfig&amp;quot;
rsource &amp;quot;tests/Kconfig&amp;quot;&lt;/pre&gt;&lt;br /&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;From which &amp;quot;samples/Kconfig&amp;quot; contains an other include to &amp;quot;samples/common&amp;quot;, from which on, things get a little bit &amp;quot;confusing&amp;quot;.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;If there is a way to&amp;nbsp;&lt;/span&gt;further track down, why (first of all)&amp;nbsp;&lt;span&gt;CONFIG_DT_HAS_NORDIC_QSPI_NOR_ENABLED is set, or why&amp;nbsp;CONFIG_NORDIC_QSPI_NOR is set, I would invest some more hours into this. If there is no way to figure out, why I have this settings, I would stick to directly setting&amp;nbsp;CONFIG_NORDIC_QSPI_NOR to n.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;As we are developing a medical device, I would really love to understand, how we could avoid getting drivers linked in, that we are not going to use.&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to configure Settings?</title><link>https://devzone.nordicsemi.com/thread/503243?ContentTypeID=1</link><pubDate>Fri, 20 Sep 2024 11:00:36 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:43ada1f3-a15b-4ecb-bfa7-5c8abd0d99e0</guid><dc:creator>Einar Thorsrud</dc:creator><description>&lt;p&gt;Hi&amp;nbsp;Torsten,&lt;/p&gt;
&lt;p&gt;Good to see you found the relevant config.&amp;nbsp;Is&amp;nbsp;CONFIG_NORDIC_QSPI_NOR set somethwere else, in a project or board specific Kconfig?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to configure Settings?</title><link>https://devzone.nordicsemi.com/thread/503061?ContentTypeID=1</link><pubDate>Thu, 19 Sep 2024 08:17:09 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:f3b128a2-2cd3-40a2-8dea-abbb4c3e1dba</guid><dc:creator>Torsten Robitzki</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;I now, figured out, that I could set `CONFIG_NORDIC_QSPI_NOR` to `n` to prevent Zephyr from&amp;nbsp;linking in the qspi-nor library. According to `zephyr/drivers/flash/Kconfig.nordic_qspi_nor` this configuration flag should depend on `DT_HAS_NORDIC_QSPI_NOR_ENABLED`. So I thought, the more appropriate solution to my problem would be to disable qspi in the device tree:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;&amp;amp;qspi {
    status = &amp;quot;disabled&amp;quot;;
};
&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;My current design is based on the `nrf5340dk/nrf5340/cpuapp` board. By disabling the qspi peripheral, I though, that the dependency for&amp;nbsp;&lt;span&gt;`CONFIG_&lt;/span&gt;&lt;span&gt;NORDIC_QSPI_NOR` would not be given and thus, `CONFIG_NORDIC_QSPI_NOR` would not have been set to `y`. But that didn&amp;#39;t worked out as expected. Any idea, as to how to make the `DT_HAS_NORDIC_QSPI_NOR_ENABLED` dependency fail, so that&amp;nbsp;`CONFIG_NORDIC_QSPI_NOR` will not get set to `y`?&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;Torsten&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to configure Settings?</title><link>https://devzone.nordicsemi.com/thread/502771?ContentTypeID=1</link><pubDate>Tue, 17 Sep 2024 12:37:25 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:93e57090-0b47-4f33-9587-a11b49a22c95</guid><dc:creator>Torsten Robitzki</dc:creator><description>&lt;p&gt;Hi Einar,&lt;/p&gt;
&lt;p&gt;thanks for taking a look into my issue. The problem is, that the flash_map sources define a `&lt;span&gt;IRQ_CONNECT` handler with the very same IRQ number, as my flash driver. While my flash driver actually uses the QSPI peripheral, the flash_map should not use the QSPI peripheral, as the Settings should be written to the internal flash memory of the nrf53.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;The concrete error message is:&amp;nbsp;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;pre class="ui-code" data-mode="text"&gt;gen_isr_tables.py: error: multiple registrations at table_index 43 for irq 43 (0x2b)
Existing handler 0x4715, new handler 0x38897
Has IRQ_CONNECT or IRQ_DIRECT_CONNECT accidentally been invoked on the same irq multiple times?
&lt;/pre&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;With 43 from nrf5340_application.h:&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;pre class="ui-code" data-mode="c_cpp"&gt;  QSPI_IRQn                 =  43,              /*!&amp;lt; 43 QSPI                                                                   */
&lt;/pre&gt;&lt;/span&gt;&lt;span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to configure Settings?</title><link>https://devzone.nordicsemi.com/thread/502763?ContentTypeID=1</link><pubDate>Tue, 17 Sep 2024 12:25:52 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:392c0773-783b-4e3f-bf6d-49c6ce78a9f6</guid><dc:creator>Einar Thorsrud</dc:creator><description>&lt;p&gt;Hi&amp;nbsp;Torsten,&lt;/p&gt;
&lt;p&gt;The settings related configs you have here look sensible. You should include&amp;nbsp;CONFIG_FLASH_MAP, ans you can see that the same essential set of configs is used in the Bluetooth samples that&amp;nbsp;support bonding.&lt;/p&gt;
&lt;p&gt;Is there a problem when you include this? If so, what is it (that the parition is placed on the external flash where you do not want it, or somehting else?). In addition to understanding what the problem is, it would be usefull to see your partition layout (both the generated as well as any static partitions you have configured.&lt;/p&gt;
&lt;p&gt;Br,&lt;/p&gt;
&lt;p&gt;Einar&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>