<?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>Get rss signal</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/68728/get-rss-signal</link><description>Hello 
 I would like to retrieve the signal strength of the Thread messages I receive. To do this, I used the otMessageGetRss (message) command in my request_handler but the returned value is always 0xEA or sometimes 0xE9 ... regardless of the distance</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Tue, 01 Dec 2020 09:59:40 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/68728/get-rss-signal" /><item><title>RE: Get rss signal</title><link>https://devzone.nordicsemi.com/thread/282616?ContentTypeID=1</link><pubDate>Tue, 01 Dec 2020 09:59:40 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:8c3824ca-9869-4b1c-98ac-d664af329baf</guid><dc:creator>Edvin</dc:creator><description>&lt;p&gt;Hello,&lt;/p&gt;
&lt;p&gt;I tested a similar implementation in the example pair simple_coap_server and simple_coap_client. Can you test this example? To trigger the&amp;nbsp;provisioning_request_handler() you need to press button 4 on the DK first on the server, and then on the client. I tried the following implementation of provisioning_request_handler():&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="c_cpp"&gt;static void provisioning_request_handler(void                * p_context,
                                         otMessage           * p_message,
                                         const otMessageInfo * p_message_info)
{
    NRF_LOG_INFO(&amp;quot;**************Provisioning_request_handler**************&amp;quot;);
    UNUSED_PARAMETER(p_message);

    otError       error;
    otMessageInfo message_info;
    
    int8_t signal_strength = OT_RADIO_RSSI_INVALID;
    
    signal_strength = otMessageGetRss(p_message);
    
    NRF_LOG_INFO(&amp;quot;Signal strength = %02x = %d&amp;quot;, signal_strength, signal_strength);

    if (!provisioning_is_enabled())
    {
        return;
    }

    if ((otCoapMessageGetType(p_message) == OT_COAP_TYPE_NON_CONFIRMABLE) &amp;amp;&amp;amp;
        (otCoapMessageGetCode(p_message) == OT_COAP_CODE_GET))
    {
        message_info = *p_message_info;
        memset(&amp;amp;message_info.mSockAddr, 0, sizeof(message_info.mSockAddr));

        error = provisioning_response_send(p_message, &amp;amp;message_info);
        if (error == OT_ERROR_NONE)
        {
            provisioning_enable(false);
        }
    }
}&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;I get varying RSS values printed in the log. Everything from -26 to -35 just by putting my hand over one of the DKs as I do this. Can you test and see if you see the same in these examples?&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;BR,&lt;/p&gt;
&lt;p&gt;Edvin&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Get rss signal</title><link>https://devzone.nordicsemi.com/thread/282224?ContentTypeID=1</link><pubDate>Fri, 27 Nov 2020 10:09:06 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:9ed326c8-59b5-45b7-b9e0-f930682c2296</guid><dc:creator>QuentinD</dc:creator><description>&lt;p&gt;Hi Edvin&lt;br /&gt;&lt;br /&gt;Have you been able to see what is wrong?&lt;br /&gt;&lt;br /&gt;Thank you&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Get rss signal</title><link>https://devzone.nordicsemi.com/thread/281746?ContentTypeID=1</link><pubDate>Wed, 25 Nov 2020 10:14:55 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:a8c3c06a-5cb8-4cde-b5bc-f8189d06bfcf</guid><dc:creator>QuentinD</dc:creator><description>&lt;p&gt;Hi Edvin&lt;/p&gt;
&lt;p&gt;My goal is to be able to display to the installer in a building what is the signal strength of the messages he receives from his neighbors: the objective being to see directly if there is no risk of having too many disconnections of devices because they have too limited range. So it&amp;#39;s not a big deal that the signal strength I get is from a neighbor rather than the one who actually originated the message because I just want to know if the device will be able to receive the messages from the network correctly if it is positioned in this fixed position.&lt;/p&gt;
&lt;p&gt;Here is an example of how I would do it with the provisioning request handler from the example &amp;quot;ble_thread_dyn_mtd_coap_cli_pca10056_s140&amp;quot;:&lt;br /&gt;&lt;br /&gt;&lt;pre class="ui-code" data-mode="c_cpp"&gt;static void provisioning_request_handler(void                * p_context,
                                         otMessage           * p_message,
                                         const otMessageInfo * p_message_info)
{
    UNUSED_PARAMETER(p_message);

    otError       error;
    otMessageInfo message_info;
    int8_t signal_strength = OT_RADIO_RSSI_INVALID;

    signal_strength = otMessageGetRss(p_message);
    set_signal_strength(p_message_info-&amp;gt;mPeerAddr.mFields.m8, signal_strength);//Save the signal strength associated with the ip address

    if (!provisioning_is_enabled())
    {
        return;
    }

    if ((otCoapMessageGetType(p_message) == OT_COAP_TYPE_NON_CONFIRMABLE) &amp;amp;&amp;amp;
        (otCoapMessageGetCode(p_message) == OT_COAP_CODE_GET))
    {
        message_info = *p_message_info;
        memset(&amp;amp;message_info.mSockAddr, 0, sizeof(message_info.mSockAddr));

        error = provisioning_response_send(p_message, &amp;amp;message_info);
        if (error == OT_ERROR_NONE)
        {
            provisioning_enable(false);
        }
    }
}&lt;/pre&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Get rss signal</title><link>https://devzone.nordicsemi.com/thread/281744?ContentTypeID=1</link><pubDate>Wed, 25 Nov 2020 09:51:52 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:bf7c82c0-67c7-4c5a-97a4-bd45a7c8b224</guid><dc:creator>Edvin</dc:creator><description>&lt;p&gt;Please note that since OpenThread is a network, the signal strength on the message is not necessarily the signal strength from the node that the message originated from. If the message is passed via another node, then the signal strength in a message will be the signal strength from the relay node. May I ask why you need the signal strength of the messages?&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;For example if you have 3 nodes, A, B and C:&lt;/p&gt;
&lt;p&gt;A &amp;lt;=&amp;gt; B &amp;lt;=&amp;gt; C&lt;/p&gt;
&lt;p&gt;where B is your network leader, and you want to measure the RSS on the messages&amp;nbsp;received on&amp;nbsp;A on the messages coming from node C, it doesn&amp;#39;t help to move C further away if all the messages are routed through B. The received signal strength on A will always be the signal strength from B to A.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Also, from message.h in the openthread SDK:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="c_cpp"&gt;/**
 * This function returns the average RSS (received signal strength) associated with the message.
 *
 * @returns The average RSS value (in dBm) or OT_RADIO_RSSI_INVALID if no average RSS is available.
 *
 */
int8_t otMessageGetRss(const otMessage *aMessage);&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;The RSS you get from otMessageGetRss() is the average RSS assiciated with the message.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Can you show me where you use the otMessageGetRss() call?&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;BR,&lt;/p&gt;
&lt;p&gt;Edvin&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>