<?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>how to get and send the RSSI value over ble</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/68548/how-to-get-and-send-the-rssi-value-over-ble</link><description>Hi, 
 I am working nRF52832 and sdk 16 version. I want to get the RSSI value of my peripheral device nRF52832 and send it to central (phone) over ble ? how to do that ? 
 
 
 
 
 Best Regards 
 pspavi</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Mon, 23 Nov 2020 09:34:51 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/68548/how-to-get-and-send-the-rssi-value-over-ble" /><item><title>RE: how to get and send the RSSI value over ble</title><link>https://devzone.nordicsemi.com/thread/281262?ContentTypeID=1</link><pubDate>Mon, 23 Nov 2020 09:34:51 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:551707fe-6349-4a38-840e-652ceed0a6ae</guid><dc:creator>Vidar Berg</dc:creator><description>&lt;p&gt;Measured RSSI will vary quite a bit when tested in uncontrolled environments, so the variation you see is probably as expected. To limit this variation you could try calculate an average RSSI from multiple samples.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: how to get and send the RSSI value over ble</title><link>https://devzone.nordicsemi.com/thread/280882?ContentTypeID=1</link><pubDate>Thu, 19 Nov 2020 12:25:15 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:cea1e811-8490-46a8-b023-d4ff6ec6437f</guid><dc:creator>ps_anu</dc:creator><description>&lt;p&gt;yes I did , but i am not getting the RSSI stable value , it is varying&amp;nbsp; ..please let me know how to rectify&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;img alt=" " src="https://devzone.nordicsemi.com/resized-image/__size/320x240/__key/communityserver-discussions-components-files/4/rssi.JPG" /&gt;&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="c_cpp"&gt;  switch (p_ble_evt-&amp;gt;header.evt_id)
    {
        case BLE_GAP_EVT_CONNECTED:
            NRF_LOG_INFO(&amp;quot;Connected&amp;quot;);
            err_code = bsp_indication_set(BSP_INDICATE_CONNECTED);
            APP_ERROR_CHECK(err_code);
            m_conn_handle = p_ble_evt-&amp;gt;evt.gap_evt.conn_handle;
            err_code = nrf_ble_qwr_conn_handle_assign(&amp;amp;m_qwr, m_conn_handle);
            APP_ERROR_CHECK(err_code);

            uint32_t err_code;  
m_conn_handle  = p_ble_evt-&amp;gt;evt.gap_evt.conn_handle;  
err_code = sd_ble_gap_rssi_start(m_conn_handle, 10, 0);  
APP_ERROR_CHECK(err_code);  


            break;
 case BLE_GAP_EVT_RSSI_CHANGED:
         
       rssi = p_ble_evt-&amp;gt;evt.gap_evt.params.rssi_changed.rssi;
    
NRF_LOG_INFO(&amp;quot;rssi:%d&amp;quot;,rssi);
&lt;/pre&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: how to get and send the RSSI value over ble</title><link>https://devzone.nordicsemi.com/thread/280876?ContentTypeID=1</link><pubDate>Thu, 19 Nov 2020 12:15:06 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:9cd25db2-5b02-40eb-a18b-49a3c521ed97</guid><dc:creator>Vidar Berg</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;Just to make sure, did you consider the option of just reading the RSSI on the phone instead? I don&amp;#39;t think it&amp;#39;s common to have a peripheral send measured RSSI to the central, and it does complicate things a bit. In any case, you can use the following SD APIs to control RSSI sampling:&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;a title="sd_ble_gap_rssi_get" href="https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.s132.api.v7.2.0/group___b_l_e___g_a_p___f_u_n_c_t_i_o_n_s.html?cp=4_7_3_1_2_1_3_34#ga63b6ec4b1af260085b8dfe5c7b02b724"&gt;sd_ble_gap_rssi_get&lt;/a&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;a title="sd_ble_gap_rssi_start" href="https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.s132.api.v7.2.0/group___b_l_e___g_a_p___f_u_n_c_t_i_o_n_s.html?cp=4_7_3_1_2_1_3_35#gac369253b7f5ce0fc0093a6133faa791f"&gt;sd_ble_gap_rssi_start&lt;/a&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>