<?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>Use Button Handler in Zephyr environment</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/84862/use-button-handler-in-zephyr-environment</link><description>Hello, guys. 
 We are using nRF51822 SoC and Zephyr OS to develop our application. 
 I wonder if it will be possible to use Nordic&amp;#39;s Button Handler module in the Zephyr environment? I noticed it is using GPIOTE Handler + app_timer + scheduler so not sure</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Tue, 22 Feb 2022 16:14:25 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/84862/use-button-handler-in-zephyr-environment" /><item><title>RE: Use Button Handler in Zephyr environment</title><link>https://devzone.nordicsemi.com/thread/354412?ContentTypeID=1</link><pubDate>Tue, 22 Feb 2022 16:14:25 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:f0dcf1a2-797d-41b8-90b7-9559f0b51d5c</guid><dc:creator>SwRa</dc:creator><description>&lt;p&gt;Hi Bojan,&lt;/p&gt;
&lt;p&gt;It is not easy to port the nRF 5 SDK API to that compatible with Zephyr.. It should be possible to do this the way you mentioned in theory. But It&amp;#39;s always be better to use the drivers and libraries that are already part of nRF Connect SDK instead of porting... We have the DK button and LED library instead of this in nRF Connect SDK:&amp;nbsp;&lt;a href="https://developer.nordicsemi.com/nRF_Connect_SDK/doc/1.8.0/nrf/libraries/others/dk_buttons_and_leds.html"&gt;https://developer.nordicsemi.com/nRF_Connect_SDK/doc/1.8.0/nrf/libraries/others/dk_buttons_and_leds.html&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Kind Regards,&lt;/p&gt;
&lt;p&gt;Swathy&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Use Button Handler in Zephyr environment</title><link>https://devzone.nordicsemi.com/thread/353984?ContentTypeID=1</link><pubDate>Sat, 19 Feb 2022 13:24:58 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:31574286-6a96-4008-bccd-154bb2f83b38</guid><dc:creator>bojan</dc:creator><description>&lt;p&gt;Hello, &lt;a href="https://devzone.nordicsemi.com/members/swra"&gt;SwRa&lt;/a&gt;. &lt;/p&gt;
&lt;p&gt;Thanks for your feedback.&lt;/p&gt;
&lt;p&gt;I am aware we can&amp;#39;t use &lt;a href="https://infocenter.nordicsemi.com/index.jsp?topic=%2Fcom.nordic.infocenter.sdk5.v12.2.0%2Fgroup__app__button.html" rel="noopener noreferrer" target="_blank"&gt;Button Handler module&lt;/a&gt; as it is in the Zephyr environment. Would it be possible to port it to the Zephyr environment somehow? For example, to use Zephyr timers instead of SDK app_timers and &lt;span style="background-color:#00ffff;"&gt;nrfx_gpiote&lt;/span&gt; drivers instead of&lt;span style="background-color:#ccffff;"&gt; nrf_drv_gpiote. &lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="background-color:#ffffff;"&gt;Thanks in advance.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="background-color:#ffffff;"&gt;Sincerely,&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="background-color:#ffffff;"&gt;Bojan.&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Use Button Handler in Zephyr environment</title><link>https://devzone.nordicsemi.com/thread/353895?ContentTypeID=1</link><pubDate>Fri, 18 Feb 2022 14:53:07 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:c11145a8-649a-4718-b1f4-36b6427cbe52</guid><dc:creator>SwRa</dc:creator><description>&lt;p&gt;Hi Bojan,&lt;/p&gt;
&lt;p&gt;The Button Handler module cannot be used to build applications with Zephyr OS (nRF Connect SDK). It is used in nRF 5 SDK and the API for this platforms&amp;nbsp;is completely different from that used with nRF Connect for Desktop. Kindly take a look at this:&amp;nbsp;&lt;a href="https://developer.nordicsemi.com/nRF_Connect_SDK/doc/latest/nrf/libraries/caf/buttons.html?highlight=button%20handler"&gt;https://developer.nordicsemi.com/nRF_Connect_SDK/doc/latest/nrf/libraries/caf/buttons.html?highlight=button%20handler&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Best Regards,&lt;/p&gt;
&lt;p&gt;Swathy&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>