<?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>Rare occurrences of interrupt from Accelerometer not waking system from sd_app_evt_wait()</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/37466/rare-occurrences-of-interrupt-from-accelerometer-not-waking-system-from-sd_app_evt_wait</link><description>We have an application running on a custom board with the following configuration: 
 nrf52832 
 SDK v12.3 
 Softdevice S132 v3.1.0 and S332 v2.0.0 (different variants of PCB) 
 
 During sleep operation, the nrf52832 is configured to have two wake sources</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Tue, 14 Aug 2018 12:55:38 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/37466/rare-occurrences-of-interrupt-from-accelerometer-not-waking-system-from-sd_app_evt_wait" /><item><title>RE: Rare occurrences of interrupt from Accelerometer not waking system from sd_app_evt_wait()</title><link>https://devzone.nordicsemi.com/thread/144180?ContentTypeID=1</link><pubDate>Tue, 14 Aug 2018 12:55:38 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:9bc08375-b819-4524-85c4-d814d19566cb</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;The GPIOTE PORT event has one signal, named &amp;quot;DETECT&amp;quot;, which does not differentiate between pins. If this signal is set, the firmware (nrf_drv_gpiote in this case) is responsible for checking which source has triggered the signal. In mode &amp;quot;GPIOTE_CONFIG_IN_SENSE_TOGGLE&amp;quot;, the nrf_drv_gpiote will also reverse the SENSE of the pin, to be able to provide a &amp;quot;software emulated edge triggering&amp;quot; (ie: event on both falling and rising edge), as compared to the level triggered operation.&lt;/p&gt;
&lt;p&gt;In this mode, you are technically vulnerable to other interrupts (as the SoftDevice or other interrupts in your application), as you might be blocked when detecting one of the edges. As you have a pulse that is 12.5 ms, it is very unlikely that the softdevice will block this event from executing on both edges. Do you have other interrupts that might postpone the execution of the GPIOTE_IRQHandler?&lt;/p&gt;
&lt;p&gt;You mention that these pins are configured with _SENSE_HI_TO_LO, but the code you attached is _SENSE_TOGGLE. Is the define &amp;quot;GPIOTE_CONFIG_NUM_OF_LOW_POWER_EVENTS&amp;quot; (located in sdk_config.h) set to the appropriate amount of GPIOTE pins configured with low accuracy?&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Best 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>