<?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>GPIOTE INPUT simple use with SDK 11.0.0</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/16010/gpiote-input-simple-use-with-sdk-11-0-0</link><description>Hi, everyone. 
 I have read the nRF5 SDK --&amp;gt; GPIOTE part in the infocenter. However, I have not get anything useful. 
 I just want to recieve a interrupt from an external sensor and do something in a handler function. So I tried some code like this</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Mon, 29 Aug 2016 06:10:51 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/16010/gpiote-input-simple-use-with-sdk-11-0-0" /><item><title>RE: GPIOTE INPUT simple use with SDK 11.0.0</title><link>https://devzone.nordicsemi.com/thread/61063?ContentTypeID=1</link><pubDate>Mon, 29 Aug 2016 06:10:51 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:8c8da5dc-d4cc-49c6-9a86-d75e3578d851</guid><dc:creator>Bee</dc:creator><description>&lt;p&gt;I&amp;#39;ve tried your codes. Thank you for help. It works!&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: GPIOTE INPUT simple use with SDK 11.0.0</title><link>https://devzone.nordicsemi.com/thread/61062?ContentTypeID=1</link><pubDate>Fri, 26 Aug 2016 14:49:05 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b1ace5d3-8149-4f41-bce1-fe7e8795d86a</guid><dc:creator>Bee</dc:creator><description>&lt;p&gt;Thank you. So it means that the event function I wrote is in the right type, is it?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: GPIOTE INPUT simple use with SDK 11.0.0</title><link>https://devzone.nordicsemi.com/thread/61061?ContentTypeID=1</link><pubDate>Fri, 26 Aug 2016 14:25:15 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:17d9543d-3c55-4422-b741-76d61d42403d</guid><dc:creator>Petter Myhre</dc:creator><description>&lt;p&gt;Firstly I recommend you to test peripheral without the SoftDevice first. Secondly I recommend checking the returned error codes of functions calls. Anyways:&lt;/p&gt;
&lt;p&gt;On PCA10028 Button 1 is not connected to pin 13, but pin 17.&lt;/p&gt;
&lt;p&gt;Pin 17 will be high when the button is not pushed, and it will be low when the button is pushed, so maybe you want to use HITOLO instead of LOTOHI.&lt;/p&gt;
&lt;p&gt;You should check the returned error code of nrf_drv_gpiote_in_init(), it will give an error because the BSP module has connected a GPIOTE channel to pin 17. Comment out buttons_leds_init() to avoid this.&lt;/p&gt;
&lt;p&gt;You need to enable the in event for the pin.&lt;/p&gt;
&lt;p&gt;You should have something like this:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;//buttons_leds_init(&amp;amp;erase_bonds);

const nrf_drv_gpiote_in_config_t config = GPIOTE_CONFIG_IN_SENSE_HITOLO(true);

err_code = nrf_drv_gpiote_init();
APP_ERROR_CHECK(err_code);

err_code = nrf_drv_gpiote_in_init(17, &amp;amp;config, event);
APP_ERROR_CHECK(err_code);

nrf_drv_gpiote_in_event_enable(17, true);  
&lt;/code&gt;&lt;/pre&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>