<?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>Central connect to Peripheral on potentiometer change</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/59678/central-connect-to-peripheral-on-potentiometer-change</link><description>Hi! 
 A little backstory on my project: Currently I have merged the saadc and peripheral ble_app_uart example. The value from a potentiometer is then sent over ble to the central device, ble_central example. What I want now is to have the central device</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Tue, 31 Mar 2020 10:23:24 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/59678/central-connect-to-peripheral-on-potentiometer-change" /><item><title>RE: Central connect to Peripheral on potentiometer change</title><link>https://devzone.nordicsemi.com/thread/242652?ContentTypeID=1</link><pubDate>Tue, 31 Mar 2020 10:23:24 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:59922532-e4cb-4566-9f2e-6555775f09b9</guid><dc:creator>J&amp;#248;rgen Holmefjord</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;If the potentiometer is connected to the peripheral, you need a way to indicate to the central when it should connect. Off the top of my head, you can use the following approaches:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Do not start advertising in the peripheral until the potentiometer has been turned.&lt;/li&gt;
&lt;li&gt;Do non-connectable advertising in the peripheral until the potentiometer is turned, and then switch to connectable advertising.&lt;/li&gt;
&lt;li&gt;Include a flag in the manufacturer-specific data in the advertising packet, telling the central if the potentiometer has been turned or not.&amp;nbsp;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;You will need to detect the turn of the potentiometer in the SAADC handler, and then do the appropriate action to enable connections.&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>