<?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>Debugging Relay Node operation in Mesh network</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/53459/debugging-relay-node-operation-in-mesh-network</link><description>Hi All, 
 I am testing the performance of a Relay Node in a mesh network.However it seems don&amp;#39;t work. 
 I would like to show that the Relay node operation such as Rx and Re-TX message . Where is the location to indicate the operation in the code, I may</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Fri, 29 Nov 2019 15:34:50 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/53459/debugging-relay-node-operation-in-mesh-network" /><item><title>RE: Debugging Relay Node operation in Mesh network</title><link>https://devzone.nordicsemi.com/thread/222862?ContentTypeID=1</link><pubDate>Fri, 29 Nov 2019 15:34:50 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:45560790-1442-421e-880d-4b360eaa2ebb</guid><dc:creator>tesc</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;The more repeats, the more time the nodes use for repeating the message, and thus the less time they will be listening for other packets on the network. 100 is a very high value, a reasonable value would be only a few repeats, maybe as many as 5 but usually less.&lt;/p&gt;
&lt;p&gt;Proxy nodes spend some time for BLE connections and advertising. We have tuned the proxy node connection settings such that they should use minimal time away from normal mesh operation, while still providing a good connection for the GATT based device.&lt;/p&gt;
&lt;p&gt;Four seconds sounds like a long time. As you monitor node D3 and do not see any packets relayed there between D1 and D2, I assume the TTL settings for the packets sent are 1. E.g. only the packets that can still be heard directly between D1 and D2 receive at their destination. If those devices are close to the edge of radio range of each other, few packets will arrive successfully. That means you need a lot of repeats from the originator and it will take quite some time to get messages across.&lt;/p&gt;
&lt;p&gt;Typically&amp;nbsp;ACCESS_DEFAULT_TTL (which is the setting for default TTL) is defined in nrf_mesh_config_app.h for each example. This can be overridden by configuration by the provisioner. For your example, TTL should be at least 2.&lt;/p&gt;
&lt;p&gt;Regards,&lt;br /&gt;Terje&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Debugging Relay Node operation in Mesh network</title><link>https://devzone.nordicsemi.com/thread/218440?ContentTypeID=1</link><pubDate>Tue, 05 Nov 2019 08:32:49 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:f2ef0e60-9ca8-46e1-aaa9-4e59b39d4a46</guid><dc:creator>Dragon Lai</dc:creator><description>&lt;p&gt;Hi Terje,&lt;/p&gt;
&lt;p&gt;1) I simplified the data payload from 40 to 7, that let the network packet form 4 segment to a un-segment data packet. The performance seems better.&lt;/p&gt;
&lt;p&gt;2) But when I put the target node D1 far away form the Proxy node D2. And I place the relay node D3 between the D1 and D2.&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;e.g.. APP &amp;lt;-&amp;gt; Proxy(D1) &amp;lt;-&amp;gt; Relay(D3) &amp;lt;-&amp;gt; Target(D2)&amp;nbsp;&lt;/p&gt;
&lt;p&gt;I monitor the rx packet on the Relay D3. It don&amp;#39;t receive the packet (D1-&amp;gt; D2) or (D2&amp;lt;-D1)&lt;/p&gt;
&lt;p&gt;3) When I&amp;nbsp; tried to modify the following values, the performance of the relay seems better, that no lost packet. &lt;/p&gt;
&lt;p&gt;CORE_TX_REPEAT_ORIGINATOR_DEFAULT 100&lt;/p&gt;
&lt;p&gt;CORE_TX_REPEAT_RELAY_DEFAULT 100&lt;/p&gt;
&lt;p&gt;4) I am not sure how the effect of the timing (Repeat 1 or 100) e.g. scanning and &lt;span class="st"&gt;&lt;em&gt;advertisement&lt;/em&gt;. &lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span class="st"&gt;or any document figure out the setting and timing e.g interval, scanning windows re-transimit, repeat? &lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span class="st"&gt;5) And the response time seems slow when send reliable set&amp;nbsp; and get back status. It is about 4s. How the speed up the response time? &lt;/span&gt;&lt;/p&gt;
&lt;p&gt;Regards,&lt;/p&gt;
&lt;p&gt;Dragon&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Debugging Relay Node operation in Mesh network</title><link>https://devzone.nordicsemi.com/thread/217182?ContentTypeID=1</link><pubDate>Mon, 28 Oct 2019 17:01:35 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:36fb19b2-4bf5-4ccb-802b-2265a163bfba</guid><dc:creator>tesc</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;You mention a lot of nodes. Please note that the publish settings are distinct on each model, on each element. That means you must configure each model individually, setting both publish address and TTL setting.&lt;/p&gt;
&lt;p&gt;Also, what packet types are the packets that you mention?&lt;/p&gt;
&lt;p&gt;Regards,&lt;br /&gt;Terje&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Debugging Relay Node operation in Mesh network</title><link>https://devzone.nordicsemi.com/thread/216719?ContentTypeID=1</link><pubDate>Fri, 25 Oct 2019 02:19:35 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:de855631-de4c-432d-9597-f706389248f0</guid><dc:creator>Dragon Lai</dc:creator><description>&lt;p&gt;HI,&lt;/p&gt;
&lt;p&gt;I tried to monitor the network_packet_in on the Relay node(ID 7).&amp;nbsp;&lt;/p&gt;
&lt;p&gt;I tried to changed the publish TTL value (e.g 127) on client (ID 1) and I tried to publish reliable to client (ID 3),&amp;nbsp;&lt;/p&gt;
&lt;p&gt;the Relay node (ID7) show the TTL value of packet (ID 1 to ID2) was 127, but the TTL value of packet (ID2 to ID1) was 8 or 4.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;and Found the TTL value of packet ( ID id 1 to&amp;nbsp; 0x7fff)&amp;nbsp; always 4.&lt;/p&gt;
&lt;p&gt;Regards,&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Dragon&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Debugging Relay Node operation in Mesh network</title><link>https://devzone.nordicsemi.com/thread/216496?ContentTypeID=1</link><pubDate>Thu, 24 Oct 2019 06:55:09 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:6356a39c-b008-47ab-bd9c-f6742209c2c3</guid><dc:creator>Dragon Lai</dc:creator><description>&lt;p&gt;HI Terje ,&amp;nbsp;&lt;/p&gt;
&lt;p&gt;There is a strange behavior on a Relay node.&lt;/p&gt;
&lt;p&gt;I connected the testing relay node with a J-Link and use the RTT viewer to view the __log form the relay node.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;If I connect the RTT viewer software with the node, it is work for the Relay node.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;If I disconnect the RTT viewer software with the node, it is show &lt;span&gt;ACCESS_RELIABLE_TRANSFER_TIMEOUT &amp;quot;Acknowledged transfer timeout&amp;quot;.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Regards,&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Dragon&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Debugging Relay Node operation in Mesh network</title><link>https://devzone.nordicsemi.com/thread/216469?ContentTypeID=1</link><pubDate>Thu, 24 Oct 2019 01:52:52 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:5723d6e1-b4a0-4760-aa1a-aaf20ea7c1ab</guid><dc:creator>Dragon Lai</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;1) I tried configure the default&amp;nbsp; (0xff) and 10 on TTL. It seems don&amp;#39;t help the stability transmission through relay.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;And i configured the Retransmission&amp;nbsp; (Count is 7, interval is 22), it seems don&amp;#39;t help the stability.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;And when i set Period, it seems don&amp;#39;t stop&lt;/p&gt;
&lt;p&gt;2)It should have two type of transition fail.&lt;/p&gt;
&lt;p&gt;i) Server did not get the message, and the client (publish) side show&amp;nbsp; ACCESS_RELIABLE_TRANSFER_TIMEOUT &amp;quot;Acknowledged transfer timeout&amp;quot;.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;ii) Server got the message, but the client did not got the status response.&lt;/p&gt;
&lt;p&gt;Regards,&lt;/p&gt;
&lt;p&gt;Dragon&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Debugging Relay Node operation in Mesh network</title><link>https://devzone.nordicsemi.com/thread/216103?ContentTypeID=1</link><pubDate>Tue, 22 Oct 2019 09:35:42 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:4cbeb22a-d888-4e74-b17b-16d649bb17be</guid><dc:creator>tesc</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;You find the TTL setting by selecting the node, then under the element you select the model, then under Publish tap &amp;quot;set publication&amp;quot;. E.g. the same settings page as where you set Publish Address, Publish Period, Publish Retransmission, etc.&lt;/p&gt;
&lt;p&gt;There is also a Default TTL on the main page for the node. Default is used if the Publish TTL of the model is set to 0xFF (which means &amp;quot;use default ttl value).&lt;/p&gt;
&lt;p&gt;Regards,&lt;br /&gt;Terje&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Debugging Relay Node operation in Mesh network</title><link>https://devzone.nordicsemi.com/thread/216094?ContentTypeID=1</link><pubDate>Tue, 22 Oct 2019 09:15:16 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:d6ad2ffb-a52a-4d42-ab43-0ff1bd4d8ee2</guid><dc:creator>Dragon Lai</dc:creator><description>&lt;p&gt;Hi&lt;/p&gt;
&lt;p&gt;I don&amp;#39;t see the interface for show the TTL configuration on the the model configuration such as Generic On Off server /Generic On Off Client. and there is a Relay item on the m model &amp;quot;configuration sever&amp;quot; such as Retransmit Count and Retransmit Interval.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;May I set the TTL value on my code?&lt;/p&gt;
&lt;p&gt;Thanks&lt;/p&gt;
&lt;p&gt;Dragon&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Debugging Relay Node operation in Mesh network</title><link>https://devzone.nordicsemi.com/thread/216091?ContentTypeID=1</link><pubDate>Tue, 22 Oct 2019 08:56:18 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:1279933b-f0be-474e-a46f-a520eac4c4f5</guid><dc:creator>tesc</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;You can configure what TTL should be used. There are both a general setting for the node, and a setting for publications from the particular model. Both of these are easily configured from the nRF Mesh app, if that is what you use for provisioning and configuration.&lt;/p&gt;
&lt;p&gt;Regards,&lt;br /&gt;Terje&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Debugging Relay Node operation in Mesh network</title><link>https://devzone.nordicsemi.com/thread/216033?ContentTypeID=1</link><pubDate>Tue, 22 Oct 2019 01:56:49 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:a837db27-8232-44d6-8f10-e67e01528124</guid><dc:creator>Dragon Lai</dc:creator><description>&lt;p&gt;Hi Terje&lt;/p&gt;
&lt;p&gt;Thank you for your reply, our project is based on the example Light_switch_server and we added the model onoff_switch_client&amp;nbsp; to the project.&lt;/p&gt;
&lt;p&gt;attached picture is the testing structure.&lt;/p&gt;
&lt;p&gt;1) we limited the TX-power to -40dbm to limited the testing space.&lt;/p&gt;
&lt;p&gt;2) the distance between the node1 and node 2 about 30cm . and the distance between the node2 and node 3 about 30cm&lt;/p&gt;
&lt;p&gt;3) the message flow is that:&lt;/p&gt;
&lt;p&gt;i) connected the node1( always send unicast address to the connected node)&lt;/p&gt;
&lt;p&gt;ii) We modified the payload of the mode OnOff_server, that the payload included the target node address.&lt;/p&gt;
&lt;p&gt;iii) App send the message ( genericOnOfftset ) to unicast address node1 , and the data of the message point to send to node 3.&lt;/p&gt;
&lt;p&gt;iv) when the node1 (connected node) received the message, it will publish the message to node3(pointed form message)&lt;/p&gt;
&lt;p&gt;&lt;img alt=" " src="https://devzone.nordicsemi.com/resized-image/__size/320x240/__key/communityserver-discussions-components-files/4/MeshBLE.jpeg" /&gt;&lt;/p&gt;
&lt;p&gt;4) we add the __Log on the code before packet_relay and in the should_relay()&lt;span style="background-color:#000000;color:#ffffff;"&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;#if MESH_FEATURE_RELAY_ENABLED&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (should_relay(&amp;amp;net_metadata))&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; __LOG(LOG_SRC_APP, LOG_LEVEL_INFO, &amp;quot;Relay (packet_relay)&amp;nbsp; ,ttl:%d \n&amp;quot;,net_metadata.ttl);&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; packet_relay(&amp;amp;net_metadata, p_net_payload, payload_len);&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;br /&gt;#endif&lt;/p&gt;
&lt;p&gt;static bool should_relay(const network_packet_metadata_t * p_metadata)&lt;br /&gt;{&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; /* Relay feature must be enabled */&lt;br /&gt;#if EXPERIMENTAL_INSTABURST_ENABLED&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (!core_tx_instaburst_is_enabled(CORE_TX_ROLE_RELAY))&lt;br /&gt;#else&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (!core_tx_adv_is_enabled(CORE_TX_ROLE_RELAY))&lt;br /&gt;#endif&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; __LOG(LOG_SRC_APP, LOG_LEVEL_INFO, &amp;quot;should_relay 1\n&amp;quot;);&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; return false;&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; /* TTL must be 2 or greater */&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (p_metadata-&amp;gt;ttl &amp;lt; 2)&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; __LOG(LOG_SRC_APP, LOG_LEVEL_INFO, &amp;quot;should_relay 2:%d\n&amp;quot;,p_metadata-&amp;gt;ttl);&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; return false;&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/p&gt;
&lt;p&gt;5) we found some case today, and we take the log on Node2 with j-link.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&amp;nbsp; i) when the node1 publish to node 3. It seems work for relay node. and&amp;nbsp; it will log some message when there is packet_in:&lt;span style="background-color:#000000;color:#ffffff;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Relay (packet_relay)&amp;nbsp; ,ttl:4&amp;nbsp;&lt;/p&gt;
&lt;p&gt;of Relay (packet_relay)&amp;nbsp; ,ttl:8&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&amp;nbsp; it seems the ttl will be 4 and 8 if the relay function work.&lt;/p&gt;
&lt;p&gt;ii) when the node3 publish to node 1. It seems don&amp;#39;t work for relay node. and&amp;nbsp; it always log the message as follow when there is packet_in&lt;span style="background-color:#000000;color:#ffffff;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&amp;nbsp; should_relay 2:1&lt;/p&gt;
&lt;p&gt;&amp;nbsp; it seems the ttl always 1.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;best Regards,&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Dragon&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Debugging Relay Node operation in Mesh network</title><link>https://devzone.nordicsemi.com/thread/215942?ContentTypeID=1</link><pubDate>Mon, 21 Oct 2019 13:13:14 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:60e2224e-e312-4e14-b57d-f48bf55fe0e6</guid><dc:creator>tesc</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;How does it not work? (What makes you think it does not work?)&lt;/p&gt;
&lt;p&gt;Remember that you need to provision the node into the network in order for it to participate in the network and relay messages.&lt;/p&gt;
&lt;p&gt;All code needed for relaying packets are behind preprocessor directives checking for MESH_FEATURE_RELAY_ENABLED. One possible location to add a debug log line is in packet_relay() in network.c. You will see there that there is already a warning message if there is not enough memory for storing the packet to be relayed. You could for instance add a log message in the case where a packet is queued up and sent as well.&lt;/p&gt;
&lt;p&gt;Regards,&lt;br /&gt;Terje&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>