<?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>mesh unreliable and reliable</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/36389/mesh-unreliable-and-reliable</link><description>Hi Nordic 
 For mesh-sdk-2.1.1, there are two APIs &amp;quot; simple_on_off_client_set &amp;quot; and &amp;quot;simple_on_off_client_set_unreliable&amp;quot; , that can send packet with acknowledge or unacknowledge, 
 
 I want to ask how to set the interval time between every repeated-sending</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Fri, 13 Jul 2018 07:38:32 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/36389/mesh-unreliable-and-reliable" /><item><title>RE: mesh unreliable and reliable</title><link>https://devzone.nordicsemi.com/thread/140016?ContentTypeID=1</link><pubDate>Fri, 13 Jul 2018 07:38:32 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:4fcf5421-9135-4b02-ad36-fe9760febf2d</guid><dc:creator>jowei</dc:creator><description>&lt;p&gt;Hi Rick&lt;/p&gt;
&lt;p&gt;It&amp;#39;s helpful to me, thanks for the answer.&lt;/p&gt;
&lt;p&gt;Joseph&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: mesh unreliable and reliable</title><link>https://devzone.nordicsemi.com/thread/140004?ContentTypeID=1</link><pubDate>Fri, 13 Jul 2018 06:46:09 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:4d1d2fad-20a6-4f73-807a-be5360289b4a</guid><dc:creator>Jui-Chou (Rick) Chung</dc:creator><description>&lt;p&gt;Hello Joseph,&lt;/p&gt;
&lt;p&gt;Basically, the time between every repeated-sending of &amp;quot;simple_on_off_client_set_unreliable&amp;quot; should be minimum advertising interval (20ms) plus a random time (0 ~ 10ms).&lt;/p&gt;
&lt;p&gt;And for the acknowledge timeout, we can check the &amp;quot;access_reliable.h&amp;quot;, line 70:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;#define ACCESS_RELIABLE_TIMEOUT_MIN  (SEC_TO_US(30))&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;Please note that in the Bluetooth mesh specification p.96, mentioned that:&lt;/p&gt;
&lt;p&gt;&amp;quot;The acknowledge message timeout should be set to a minimum of 30 seconds. The exact value is application specific.&amp;quot;&lt;/p&gt;
&lt;p&gt;For the number of retry, we may not able to set a specific number, but you may have interested to check the code in &amp;quot;access_reliable.c&amp;quot;, line 240, which shows how the retry interval be calculated.&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="c_cpp"&gt;static uint32_t calculate_interval(const access_reliable_t * p_message)
{
    uint8_t ttl;
    /* The model handle should already been checked by the TX attempt. */
    NRF_MESH_ERROR_CHECK(access_model_publish_ttl_get(p_message-&amp;gt;model_handle, &amp;amp;ttl));

    uint16_t length = access_utils_opcode_size_get(p_message-&amp;gt;message.opcode) + p_message-&amp;gt;message.length;

    uint32_t interval = (ttl * ACCESS_RELIABLE_HOP_PENALTY) + ACCESS_RELIABLE_INTERVAL_DEFAULT;
    if (NRF_MESH_UNSEG_PAYLOAD_SIZE_MAX &amp;lt; length)
    {
        interval += ((length + (NRF_MESH_SEG_SIZE - 1))/ NRF_MESH_SEG_SIZE) * ACCESS_RELIABLE_SEGMENT_COUNT_PENALTY;
    }
    return interval;
}&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;Hope the upon information can do help &lt;span class="emoticon" data-url="https://devzone.nordicsemi.com/cfs-file/__key/system/emoji/1f642.svg" title="Slight smile"&gt;&amp;#x1f642;&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>