<?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>NRF52833 SLEEP MODE &amp;amp; WAKEUP THROUGH GPIO INTERRUPT.</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/89694/nrf52833-sleep-mode-wakeup-through-gpio-interrupt</link><description>Hi All, 
 I have implemented sleep mode in the firmware. I am using NRF52833 in my project. When the device is in idle state it goes in sleep mode. Now I wanted to wakeup the device through GPIO interrupt. How can I wake up the device? The sleep mode</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Fri, 22 Jul 2022 12:15:59 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/89694/nrf52833-sleep-mode-wakeup-through-gpio-interrupt" /><item><title>RE: NRF52833 SLEEP MODE &amp; WAKEUP THROUGH GPIO INTERRUPT.</title><link>https://devzone.nordicsemi.com/thread/378291?ContentTypeID=1</link><pubDate>Fri, 22 Jul 2022 12:15:59 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:6b2c2591-ced3-4ae9-b024-8967192e6e3c</guid><dc:creator>J&amp;#248;rgen Holmefjord</dc:creator><description>&lt;p&gt;How do you configure/setup the timer? Are you using RTC/app_timer or the TIMER peripheral? As long as you only enter System ON idle mode, not System OFF, the timer can run during the sleep period. The timer will then wakeup the chip every 20 second. If you shut down the timer when going to sleep, you need to restart it when you press the button to wakeup.&lt;/p&gt;
&lt;p&gt;Please post your code to show what you are doing and what is not working.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: NRF52833 SLEEP MODE &amp; WAKEUP THROUGH GPIO INTERRUPT.</title><link>https://devzone.nordicsemi.com/thread/376690?ContentTypeID=1</link><pubDate>Wed, 13 Jul 2022 03:14:35 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:f5f4919f-6156-4224-ba28-affbaef58a83</guid><dc:creator>sne_333</dc:creator><description>&lt;p&gt;&lt;span&gt;Hi Jorgen,&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Can you please help?&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;I observed is that the timers are not getting initialized again after waking up. I have one timer which runs few tasks at an interval of 20seconds. How to start that after waking up??&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Thanks &amp;amp; Regards,&lt;/p&gt;
&lt;p&gt;Snehal&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: NRF52833 SLEEP MODE &amp; WAKEUP THROUGH GPIO INTERRUPT.</title><link>https://devzone.nordicsemi.com/thread/376096?ContentTypeID=1</link><pubDate>Fri, 08 Jul 2022 04:28:23 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:173dfdb3-8c3d-4bcf-9a8f-12792161bdf2</guid><dc:creator>sne_333</dc:creator><description>&lt;p&gt;Hi Jorgen,&lt;/p&gt;
&lt;p&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;I am setting a flag when we first advertise. If error code is 0 then I set the flasg adv_success. I am setting it back to 0 when device enters sleep mode. So I am checking this flag inside the interuupt handler. If flag is set to 0 only then it will advertise after switch is pressed. This is working.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;But what I observed is that the timers are not getting initialized again after waking up. I have one timer which runs few tasks at an interval of 20seconds. How to start that after waking up??&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Thanks &amp;amp; Regards,&lt;/p&gt;
&lt;p&gt;Snehal&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: NRF52833 SLEEP MODE &amp; WAKEUP THROUGH GPIO INTERRUPT.</title><link>https://devzone.nordicsemi.com/thread/376019?ContentTypeID=1</link><pubDate>Thu, 07 Jul 2022 12:49:26 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:e8217918-ab94-4b79-bab0-cb6ef0f63bc7</guid><dc:creator>J&amp;#248;rgen Holmefjord</dc:creator><description>&lt;p&gt;How do you declare and set the flag in your code? Do you unset the flag anywhere?&lt;/p&gt;
&lt;p&gt;Did you check with a debugger/log message that the event handler is not entered, or did you just not see advertising_init() being called?&amp;nbsp;&lt;/p&gt;
&lt;p&gt;The double-trigger may be caused by noise/bouncing signals from the button.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: NRF52833 SLEEP MODE &amp; WAKEUP THROUGH GPIO INTERRUPT.</title><link>https://devzone.nordicsemi.com/thread/375986?ContentTypeID=1</link><pubDate>Thu, 07 Jul 2022 11:07:37 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:147b052c-900f-4688-8b0d-1802e31e8a67</guid><dc:creator>sne_333</dc:creator><description>&lt;p&gt;Hi&amp;nbsp;&lt;span&gt;J&amp;oslash;rgen,&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Thanks for your reply. I tried to change the setting to&amp;nbsp;GPIOTE_CONFIG_IN_SENSE_LOTOHI. After doing this also I am observing it gets interrupt twice and device throws error on 2nd advertising. For this I added one check point flag and if that flag is set only then I advertise. But after adding that the interrupt is not detected when i press the switch button.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;What might be wrong?&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: NRF52833 SLEEP MODE &amp; WAKEUP THROUGH GPIO INTERRUPT.</title><link>https://devzone.nordicsemi.com/thread/375966?ContentTypeID=1</link><pubDate>Thu, 07 Jul 2022 09:22:51 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:7c7b80fc-9c14-4d98-94d1-95a459afbf85</guid><dc:creator>J&amp;#248;rgen Holmefjord</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;I&amp;#39;m not sure if using&amp;nbsp;GPIOTE_CONFIG_IN_SENSE_TOGGLE() will give you the intended behavior. If you are using a button to generate the interrupt, this will trigger the handler both on push and release of the button, which will try to call advertising_init() two times. This may generate error codes and restarts, as the advertising is already&amp;nbsp;started&amp;nbsp;from the button push. If your signal comes from a switch or another device that only generates 1 signal, it may work. You should either way make sure that you keep track of when the advertising is enabled, and only try to enable it when it is not already enabled.&lt;/p&gt;
&lt;p&gt;If you are using a push-button, I would recommend that you rather use&amp;nbsp;&lt;span&gt;GPIOTE_CONFIG_IN_SENSE_LOTOHI() or&amp;nbsp;GPIOTE_CONFIG_IN_SENSE_HITOLO based on your button connections and desired behavior.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Best regards,&lt;br /&gt;Jørgen&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>