<?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>Disabling peripherals and default state of GPIOTE</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/88278/disabling-peripherals-and-default-state-of-gpiote</link><description>Hello dear nRF people! 
 I am going thorough the various power optimization techniques and over and over again I come across the following advice here on the DevZone: 
 
 Disable the peripheral before going to systemON state. 
 
 I&amp;#39;m struggling to find</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Fri, 03 Jun 2022 13:43:13 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/88278/disabling-peripherals-and-default-state-of-gpiote" /><item><title>RE: Disabling peripherals and default state of GPIOTE</title><link>https://devzone.nordicsemi.com/thread/370904?ContentTypeID=1</link><pubDate>Fri, 03 Jun 2022 13:43:13 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:0dbee6e4-e14c-4d9f-a273-7d07559e8199</guid><dc:creator>Kazi Afroza Sultana</dc:creator><description>&lt;p&gt;Hello,&lt;/p&gt;
&lt;p&gt;When twi peripheral is disable you can use GPIO peripheral you have to use the config GPIO peripheral.&lt;/p&gt;
&lt;p&gt;&lt;a href="https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.nrf52832.ps.v1.1/twi.html?cp=4_2_0_48_1#concept_a4z_2pv_sr"&gt;https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.nrf52832.ps.v1.1/twi.html?cp=4_2_0_48_1#concept_a4z_2pv_sr&lt;/a&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;At a time either GPIO or TWI(M) can be assigned based on this ( either enable or system off mode). If the pins are set in PSEL registers and TWI(M) is enabled, then the config/control from GPIO peripheral will not have any effect as the pins are controlled by TWI(M).&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;I hope it helps.&amp;nbsp;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Thanks.&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;Kazi Afroza Sultana&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Disabling peripherals and default state of GPIOTE</title><link>https://devzone.nordicsemi.com/thread/369539?ContentTypeID=1</link><pubDate>Wed, 25 May 2022 12:52:25 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:dcf135dd-f487-42a2-afe8-c7d6c11d4d77</guid><dc:creator>Pero Krivic</dc:creator><description>&lt;p&gt;Hello Kazi, thanks for the help. I have checked your advice already when I found that Errata about GPIOTE and I must say it didn&amp;#39;t help.&amp;nbsp; I have also decided not to use TWIM nor nRFx drivers, but use legacy TWI Driver instead.&lt;/p&gt;
&lt;p&gt;TWIM or TWI makes no difference in current consumption.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Do you know how the GPIOTE should be configured when I disable the TWI?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Disabling peripherals and default state of GPIOTE</title><link>https://devzone.nordicsemi.com/thread/369523?ContentTypeID=1</link><pubDate>Wed, 25 May 2022 12:23:56 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b9ab220b-7e9d-4f70-951a-ec5a2349b2d1</guid><dc:creator>Kazi Afroza Sultana</dc:creator><description>&lt;p&gt;&lt;span style="font-size:inherit;"&gt;Hello,&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-size:inherit;"&gt;Have you checked the current without initializing the TWIM? &lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;The following code is for each time after disabling the TWIM&amp;nbsp;&lt;/span&gt;&lt;/p&gt;
&lt;pre&gt;&lt;span&gt;&lt;code&gt;*(volatile uint32_t *)0x40003FFC = 0;
*(volatile uint32_t *)0x40003FFC;
*(volatile uint32_t *)0x40003FFC = 1;&lt;/code&gt;&lt;/span&gt;&lt;/pre&gt;
&lt;p&gt;&lt;span style="font-size:inherit;"&gt;You should use nRFx drivers&amp;nbsp;&lt;a href="https://infocenter.nordicsemi.com/topic/sdk_nrf5_v17.1.0/group__nrfx__twim.html?cp=8_1_6_8_0_39_0_22#ga075ad0230174de95202aba61d13b77f1"&gt;https://infocenter.nordicsemi.com/topic/sdk_nrf5_v17.1.0/group__nrfx__twim.html?cp=8_1_6_8_0_39_0_22#ga075ad0230174de95202aba61d13b77f1&lt;/a&gt;&amp;nbsp;then there will be an API to enable or disable the TWIM.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-size:inherit;"&gt;&lt;img src="https://devzone.nordicsemi.com/resized-image/__size/320x240/__key/communityserver-discussions-components-files/4/5808.pastedimage1653477229876v1.png" alt=" " /&gt;&amp;nbsp;&amp;nbsp;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-size:inherit;"&gt;Thanks.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-size:inherit;"&gt;Best Regards,&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-size:inherit;"&gt;Kazi Afroza Sultana&lt;/span&gt;&lt;/p&gt;
&lt;pre&gt;&lt;/pre&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>