<?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>Fail to use gpiote edge triggering to wake the system up</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/86022/fail-to-use-gpiote-edge-triggering-to-wake-the-system-up</link><description>I am now developing nRF52805 with SDK 17.1.0. I am trying to use long pressing to enter the sleeping mode and wake the system up using the short press. However, there is an issue that if I long-press the button, the system will enter the system off as</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Thu, 24 Mar 2022 22:28:55 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/86022/fail-to-use-gpiote-edge-triggering-to-wake-the-system-up" /><item><title>RE: Fail to use gpiote edge triggering to wake the system up</title><link>https://devzone.nordicsemi.com/thread/359892?ContentTypeID=1</link><pubDate>Thu, 24 Mar 2022 22:28:55 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:e2da1550-aa14-4fe3-8098-5ec525b67960</guid><dc:creator>XIANGYU YU</dc:creator><description>&lt;p&gt;Thank you for your reply Jorgen. Actually, in the HW, there is a bypass C to avoid the notch or glitch of the button bouncing issue. Finally, I change my code format, and activate the system off function only after the button released from long-pressing action. Thank you again for your help. Best!&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Fail to use gpiote edge triggering to wake the system up</title><link>https://devzone.nordicsemi.com/thread/359548?ContentTypeID=1</link><pubDate>Wed, 23 Mar 2022 09:51:01 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:2dd35ed6-a3c9-48db-a671-dc089f5ef4df</guid><dc:creator>J&amp;#248;rgen Holmefjord</dc:creator><description>&lt;p&gt;If the wakeup is caused by bounce noise from the button/switch (you should be able to see this if you look at the signal from the button on a scope), there is no other workaround you can do in the code to go directly to System OFF and prevent wakeup when the button is released.&lt;/p&gt;
&lt;p&gt;You may consider adding a R-C filter on the button in your HW, to prevent the bounce signals in the first place. Google &amp;quot;switch bouncing&amp;quot; should give you some nice articles with suggestions.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Fail to use gpiote edge triggering to wake the system up</title><link>https://devzone.nordicsemi.com/thread/359501?ContentTypeID=1</link><pubDate>Wed, 23 Mar 2022 07:34:10 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:49fe774a-8458-44dc-a267-f13f27fb777a</guid><dc:creator>XIANGYU YU</dc:creator><description>&lt;p&gt;Thank you for your reply Jorgen. Exactly, that is the way I consider before. For example, I set a 1-second delay and show the reminder that &amp;#39;the machine will enter sleep mode, please release the button&amp;#39; something like that, to prevent the restart issue. Or I move the system off function to the release event. Only when the user long-pressing the button and then release it, the system off function will be activated as expected. Both methods could definitely solve the restart issue to some extent. But is it possible to activate the system off function without releasing the button once the user is long-pressing the button, and also, prevent the restart issue? I am sorry to make it tricky, but thank you for your help.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;XIANGYU YU&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Fail to use gpiote edge triggering to wake the system up</title><link>https://devzone.nordicsemi.com/thread/359369?ContentTypeID=1</link><pubDate>Tue, 22 Mar 2022 12:53:54 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:683554f9-c93e-4859-914a-65e119112f57</guid><dc:creator>J&amp;#248;rgen Holmefjord</dc:creator><description>&lt;p&gt;If you need to use the same button to enter and exit System OFF mode, you should probably read the state of the pin before entering System OFF, to make sure the button is in the &amp;quot;released&amp;quot; state. You may also schedule the entering of System OFF mode a few seconds in the future (for instance using a app_timer) when receiving the long press button event, to give the user some time to release the button. During this time you may configure the button for a normal pressed interrupt and enter normal System ON idle mode. In case the user press the button to wake the device before it enters System OFF mode, you should cancel the scheduled entering System OFF mode action/timer.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Fail to use gpiote edge triggering to wake the system up</title><link>https://devzone.nordicsemi.com/thread/359260?ContentTypeID=1</link><pubDate>Tue, 22 Mar 2022 03:33:45 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b0ebf7e7-1264-4a92-add5-2f184fcd7337</guid><dc:creator>XIANGYU YU</dc:creator><description>&lt;p&gt;&lt;span style="font-family:arial, helvetica, sans-serif;font-size:inherit;"&gt;Thank you for your reply Jorgen. To make the point more specific, my setting is that when I press the button for 3 seconds, the button_long_push event will be activated, and then, it will go to the system off mode. But in fact, for the general case, I could not exactly press the button for 3 seconds, it will often be longer than 3 seconds, say 3.1 seconds. Therefore, I guess that 3 seconds long press will make the system off and enable the wake-up button setting, and then a 0.1-second press will generate the DETECT signal and trigger the active-low sense, finally waking the system up.&amp;nbsp;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family:arial, helvetica, sans-serif;font-size:inherit;"&gt;If it is the issue, how could I&amp;nbsp;avoid the system waking up before I release the button from the long pressing, and then only I&amp;nbsp; press the button again to wake the system up? Thank you for your help.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family:arial, helvetica, sans-serif;font-size:inherit;"&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family:arial, helvetica, sans-serif;font-size:inherit;"&gt;Best regards,&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family:arial, helvetica, sans-serif;font-size:inherit;"&gt;XIANGYU YU&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Fail to use gpiote edge triggering to wake the system up</title><link>https://devzone.nordicsemi.com/thread/359196?ContentTypeID=1</link><pubDate>Mon, 21 Mar 2022 15:36:16 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:66354359-b129-4c4a-9ffc-1445d6435919</guid><dc:creator>J&amp;#248;rgen Holmefjord</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;Have you checked the pin with a scope, to see if there is any bouncing signals from the button that can wake the chip too early? If you enter System OFF immediately when the long button press is detected, the chip may haven entered System OFF before you release the button. If there is then some bouncing signals on the pin when the long press is released, the chip may wake up from this.&lt;/p&gt;
&lt;p&gt;Configuring the GPIO with hi_accuracy will not work, as this will configure the pin using GPIOTE IN event, which is not active in System OFF mode. Setting hi_accuracy to false will use the GPIOTE PORT event, which will also configure the GPIO in sense mode. GPIO Sense mode is what is used to wakeup from System OFF.&lt;/p&gt;
&lt;p&gt;Best regards,&lt;br /&gt;Jørgen&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>