<?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>Init &amp;amp; deinit modem.</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/73974/init-deinit-modem</link><description>Hi, 
 Firmware v1.31 
 I have a question about using those call functions https://developer.nordicsemi.com/nRF_Connect_SDK/doc/latest/nrf/include/modem/lte_lc.html#c.lte_lc_deinit . Is OK to constantly turn off and on the modem like that. Also in the</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Wed, 21 Apr 2021 10:15:53 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/73974/init-deinit-modem" /><item><title>RE: Init &amp; deinit modem.</title><link>https://devzone.nordicsemi.com/thread/306052?ContentTypeID=1</link><pubDate>Wed, 21 Apr 2021 10:15:53 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:c53f2710-39b4-4daa-bc96-54347cb8bc79</guid><dc:creator>AMG</dc:creator><description>&lt;p&gt;Thanks for the feedback.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Init &amp; deinit modem.</title><link>https://devzone.nordicsemi.com/thread/306049?ContentTypeID=1</link><pubDate>Wed, 21 Apr 2021 10:13:30 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:e322c634-a22b-43e8-be22-1f72a5efc097</guid><dc:creator>Heidi</dc:creator><description>&lt;p&gt;Hi, after &lt;span&gt;lte_lc_offline() and just need to call&amp;nbsp;&lt;/span&gt;lte_lc_normal() to&amp;nbsp;put the modem in online mode again. You don&amp;#39;t need to initialize anything again.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Yes, if you&amp;#39;re constantly switching between LTE and GPS mode, the AT commands AT+CFUN=20,21,30,31 will work better.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;However,&amp;nbsp;please be aware that this will cause the device to detach from the network. Then when you go back to online mode, it has to go through the attach procedure with the network again, which takes both time and power.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;We usually recommend enabling either PSM or eDRX when using LTE and GPS concurrently, as this allows the GPS to run when the modem is in RRC idle mode and the device does not have to detach from the network.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Heidi&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Init &amp; deinit modem.</title><link>https://devzone.nordicsemi.com/thread/305486?ContentTypeID=1</link><pubDate>Mon, 19 Apr 2021 10:31:24 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:045ded1f-543c-4ea4-b786-7e8dcae93262</guid><dc:creator>AMG</dc:creator><description>&lt;p&gt;Acutlally a better way of doing it is using CFUN = 20, 21,30 ,31 .&amp;nbsp;&lt;a href="https://infocenter.nordicsemi.com/index.jsp?topic=%2Fref_at_commands%2FREF%2Fat_commands%2Fmob_termination_ctrl_status%2Fcfun_set.html"&gt;https://infocenter.nordicsemi.com/index.jsp?topic=%2Fref_at_commands%2FREF%2Fat_commands%2Fmob_termination_ctrl_status%2Fcfun_set.html&lt;/a&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Init &amp; deinit modem.</title><link>https://devzone.nordicsemi.com/thread/305367?ContentTypeID=1</link><pubDate>Sat, 17 Apr 2021 10:33:50 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:6d45633b-2e57-493b-8cda-04b54732e3ee</guid><dc:creator>AMG</dc:creator><description>&lt;p&gt;Hi,&lt;br /&gt;&lt;br /&gt;I am using de-init and init the modem since I am using CoAP and GPS and both require modem connection. After using the call functions&amp;nbsp; (offline or turn_off ) the modem will be de-initialized so I had to change ncs to remove the if condition which will lead to an error and&amp;nbsp; return.&lt;/p&gt;
&lt;p&gt;Just to make sure using&amp;nbsp; offline() call and then&amp;nbsp;&amp;nbsp;&lt;span&gt;lte_lc_init&lt;/span&gt;&lt;span&gt;(); , again and again shouldn&amp;#39;t pose any problems.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Init &amp; deinit modem.</title><link>https://devzone.nordicsemi.com/thread/305284?ContentTypeID=1</link><pubDate>Fri, 16 Apr 2021 12:31:42 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:a04ea977-20e3-4e10-9591-97a7efd58b8a</guid><dc:creator>Heidi</dc:creator><description>&lt;p&gt;Hi!&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;No, it&amp;#39;s not a good idea to constantly turn the modem off and on (AT+CFUN=0). Turning the modem off automatically writes a lot of the modem configurations to flash. Since there are a limited number of write operations to flash, you can risk exceeding this limit.&lt;/p&gt;
&lt;p&gt;Instead, we recommend putting the modem in &lt;a href="https://developer.nordicsemi.com/nRF_Connect_SDK/doc/latest/nrf/include/modem/lte_lc.html#c.lte_lc_offline"&gt;offline mode&lt;/a&gt; (AT+CFUN=4), which has the same functionality without writing anything to flash.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Why did you need to remove the if-statement to make this work? We really don&amp;#39;t recommend modifying the libraries in NCS.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Heidi&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>