<?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>config in runtime instead of in prj.conf</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/111623/config-in-runtime-instead-of-in-prj-conf</link><description>Hi Support team: 
 I&amp;#39;m using Zephyr cellular modem driver on the nRF5340 and set APN in prj.conf with &amp;#39;CONFIG_MODEM_CELLULAR_APN=&amp;quot;telenor.iot&amp;quot;&amp;#39; now. I need to set APN value in runtime at the initialization stage, because this value is provided by the</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Wed, 29 May 2024 09:59:23 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/111623/config-in-runtime-instead-of-in-prj-conf" /><item><title>RE: config in runtime instead of in prj.conf</title><link>https://devzone.nordicsemi.com/thread/486372?ContentTypeID=1</link><pubDate>Wed, 29 May 2024 09:59:23 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:88c89596-405f-4936-9d89-66d97138ac39</guid><dc:creator>Yanpengwu</dc:creator><description>&lt;p&gt;Hi &lt;span&gt;H&amp;aring;kon,&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;I&amp;#39;m using&amp;nbsp;&lt;span&gt;nRF5340, not the&lt;/span&gt;&amp;nbsp;&lt;span&gt;nRF91. Is it the same for&amp;nbsp;nRF5340? If so, I will study the AT command sequence to see how to do it in runtime.&lt;br /&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;Yanpeng Wu&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: config in runtime instead of in prj.conf</title><link>https://devzone.nordicsemi.com/thread/486345?ContentTypeID=1</link><pubDate>Wed, 29 May 2024 09:06:47 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:c4091db0-bb21-48b5-9f61-7435decf168f</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;We do not use the modem subsys with the nRF91-series in zephyr, so I cannot answer this, as I do not know. However; if you have a way to send an arbitrary AT command to your modem, you should send a similar sequence which I pointed to in my former reply.&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: config in runtime instead of in prj.conf</title><link>https://devzone.nordicsemi.com/thread/486339?ContentTypeID=1</link><pubDate>Wed, 29 May 2024 08:55:59 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:4b2f7936-9512-431c-b54d-86814f58a9d8</guid><dc:creator>Yanpengwu</dc:creator><description>&lt;p&gt;Hi&amp;nbsp;&lt;span&gt;H&amp;aring;kon, Thanks for the quick reply. Before touching the driver code, is it possible to do this in Zephyr? For example through set environment variables or other similar ...&amp;nbsp;&lt;br /&gt;I can understand the prf.conf will be processed in the compiling stage, not sure if there is any chance to do it in the application domain.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: config in runtime instead of in prj.conf</title><link>https://devzone.nordicsemi.com/thread/486336?ContentTypeID=1</link><pubDate>Wed, 29 May 2024 08:40:52 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:97fecf34-c2b8-4850-a072-c1da519db9de</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;&lt;/p&gt;
[quote user=""]&lt;p&gt;I&amp;#39;m using Zephyr cellular modem driver on the nRF5340 and set APN in prj.conf with &amp;#39;CONFIG_MODEM_CELLULAR_APN=&amp;quot;telenor.iot&amp;quot;&amp;#39; now.&lt;br /&gt;I need to set APN value in runtime at the initialization stage, because this value&amp;nbsp;is provided by the user.&lt;/p&gt;
&lt;p&gt;I found the driver did not provide API to do this. Is there any method to do this in Zephyr or Nordic sdk? Thank you very much.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;[/quote]
&lt;p&gt;Given that this is the zephyr modem subsys, and not the nrf9160 that you&amp;#39;re looking into, the best option is to ask the zephyr community, as these are modules that isn&amp;#39;t directly supported by nRF devices.&lt;/p&gt;
&lt;p&gt;That being said; It does not look like the zephyr modem subsys has the option for this.&lt;/p&gt;
&lt;p&gt;However; you can issue the following AT commands manually:&amp;nbsp;&lt;a href="https://github.com/zephyrproject-rtos/zephyr//blob/v3.6.0/drivers/modem/modem_cellular.c#L1818-L1823"&gt;https://github.com/zephyrproject-rtos/zephyr//blob/v3.6.0/drivers/modem/modem_cellular.c#L1818-L1823&lt;/a&gt;&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>