<?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>OpenThread provisioning response</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/64989/openthread-provisioning-response</link><description>Hello, 
 I have a device which sends a provisioning request to two other devices in a Thread network. They both receive the request and both send a provisioning response, i.e. both devices receiving the provisioning requests calls provisioning_response_send</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Fri, 04 Sep 2020 06:42:02 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/64989/openthread-provisioning-response" /><item><title>RE: OpenThread provisioning response</title><link>https://devzone.nordicsemi.com/thread/267951?ContentTypeID=1</link><pubDate>Fri, 04 Sep 2020 06:42:02 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:9c6d21ed-f5cb-4a69-a7f7-13666c244203</guid><dc:creator>Amadeus</dc:creator><description>&lt;p&gt;Hello,&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Since the IP addresses I want to acquire is supposed to be from child nodes, the router table probably won&amp;#39;t help. From J&amp;oslash;rgen&amp;#39;s answer in the other ticket, it looks like the way of acquiring other devices IP addresses is the same as I am doing now, i.e. sending a multicast message and listen to the responses. This is a bit surprising to me, as I thought these addresses should be available after the mesh link discovery and network creation. In any case, thank you for your help. I will open another ticket regarding Coap confirmable/non-confirmable messages.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: OpenThread provisioning response</title><link>https://devzone.nordicsemi.com/thread/267885?ContentTypeID=1</link><pubDate>Thu, 03 Sep 2020 14:33:30 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:7af92586-ebb4-4176-923d-d22ad1e1177c</guid><dc:creator>Edvin</dc:creator><description>&lt;p&gt;Hello,&lt;/p&gt;
&lt;p&gt;First of all, sorry for the late reply.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Have you checked out the&amp;nbsp;CLI example? (NB: If you use the NCS one, you need to add &amp;quot;ot &amp;quot; before the CLI commands.&lt;/p&gt;
&lt;p&gt;You can use commands like &amp;quot;ot cli router table&amp;quot; to see a table of all the routers, with some parameters like number of hops, extended MAC address, and RLOC address.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;The RLOC address can be used to reach the node from within the network using a &lt;a href="https://openthread.io/guides/thread-primer/ipv6-addressing#scopes" rel="noopener noreferrer" target="_blank"&gt;Mesh Local address&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;I used the following cli commands to ping another device:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="c_cpp"&gt;uart:~$ ot router table
| ID | RLOC16 | Next Hop | Path Cost | LQ In | LQ Out | Age | Extended MAC     |
+----+--------+----------+-----------+-------+--------+-----+------------------+
|  9 | 0x2400 |       43 |         1 |     3 |      3 |   6 | b643fd5dc3a95b44 |
| 25 | 0x6400 |       63 |         0 |     0 |      0 |   0 | e6c92d2a39ea47b3 |
| 43 | 0xac00 |        9 |         1 |     3 |      3 |   5 | e6675f027885bdf7 |

Done
uart:~$ ot ping fdde:ad00:beef::ff:fe00:2400
Done
16 bytes from fdde:ad00:beef:0:0:ff:fe00:2400: icmp_seq=2 hlim=64 time=22ms
uart:~$
&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;As you can see from Jørgen&amp;#39;s answer &lt;a href="https://devzone.nordicsemi.com/f/nordic-q-a/63167/thread-border-router-networking-fail/267230#267230" rel="noopener noreferrer" target="_blank"&gt;here&lt;/a&gt;, the mesh local address will always be:&amp;nbsp;&lt;/p&gt;
&lt;p&gt;fdde:ad00:beef::ff:fe00:&amp;lt;RLOC&amp;gt;&lt;/p&gt;
&lt;p&gt;You can access the openthread cli implementation from the openthread github. E.g. the router table command is implemented here:&lt;/p&gt;
&lt;p&gt;&lt;a href="https://github.com/openthread/openthread/blob/b940baf9b6cad48feaab60848f6e006bffe79d4e/src/cli/cli.cpp#L3425"&gt;https://github.com/openthread/openthread/blob/b940baf9b6cad48feaab60848f6e006bffe79d4e/src/cli/cli.cpp#L3425&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;You can use this api from your application.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Is this something you can use?&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Edvin&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: OpenThread provisioning response</title><link>https://devzone.nordicsemi.com/thread/266676?ContentTypeID=1</link><pubDate>Thu, 27 Aug 2020 09:28:39 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:d3fc7595-f7d4-43e0-9c2b-30301cbaa1e6</guid><dc:creator>Amadeus</dc:creator><description>&lt;p&gt;Update: I temporary fixed the problem by, instead of sending an&amp;nbsp;otCoapSendResponse() in&amp;nbsp;&lt;span&gt;&lt;span&gt;provisioning_response_send(), I use the Zephyr Thread Api and&amp;nbsp;call&amp;nbsp;&lt;/span&gt;&lt;/span&gt;coap_send_request(). This way, the client who sent the provisioning request receives a message from both (currently) two servers. I tried first using the OpenThread API and&amp;nbsp;&lt;span&gt;&lt;span&gt;otCoapSendRequest() instead of&amp;nbsp;&lt;/span&gt;&lt;/span&gt;otCoapSendResponse(), but that does not work; the client does not receive any messages. Any takes on why?&lt;/p&gt;
&lt;div&gt;However, I still think that the thread network IP addresses should be available somewhere without the need of this provisioning procedure.&lt;/div&gt;
&lt;div&gt;&lt;/div&gt;
&lt;div&gt;Furthermore, coap_send_request() calls coap_init_request() in ncs/nrf/subsys/net/lib/coap_utils.c. This function takes a coap_msgtype argument but this is set to COAP_TYPE_NON_CON. Why is this? Why doesn&amp;#39;t coap_send_request() take a coap_msgtype argument so that this could be specified at the application level without the need of changing the SDK? Is there any reason for this, i.e. that confirmable messages not are stable or anything like that?&lt;/div&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: OpenThread provisioning response</title><link>https://devzone.nordicsemi.com/thread/266322?ContentTypeID=1</link><pubDate>Tue, 25 Aug 2020 18:42:11 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:429ae4b2-25a7-464b-9d6a-14fd37200a80</guid><dc:creator>Amadeus</dc:creator><description>&lt;p&gt;Thank you for your answer.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;The outlined procedure, however, only works with one server at a time. E.g. if I enable provisioning on two servers simultaneously, and&amp;nbsp;send a multicast provisioning request with a client, both servers receive this message and sends a provisioning unicast response. However, the client only receives one of these responses, and I reckon this is due to how&amp;nbsp;&lt;em&gt;coap_set_response_callback() &lt;/em&gt;is&lt;em&gt; &lt;/em&gt;defined; that the callback is cleared after the first call or something like that. Thus, only one server can be provisioned at a time. If possible, I want to be able to acquire the IPv6 addresses of several servers without needing to provision one by one like this.&lt;/p&gt;
&lt;p&gt;Since the thread network already is established before this provisioning routine, shouldn&amp;#39;t the IPv6 addresses be readily available for the thread routers somewhere?&amp;nbsp; E.g. the link and mesh local addresses? I was of the impression that such information was exchanged during the&amp;nbsp;thread network creation and that the routers could address any node in the network by its IPv6 address without the need of &amp;quot;extra&amp;quot; provisioning by making the servers reply with their address upon receiving a multicast provisioning request like in the sample. Is this possible?&lt;/p&gt;
&lt;p&gt;Yes, I can observe any IPv6 address of any node by uart commands in the console, but I cannot find a way to observe all nodes and their corresponding IPv6 addresses from one particular (router) device. I.e. I need to call&amp;nbsp;&lt;em&gt;ot ipaddr&lt;/em&gt; on the separate nodes to see their addresses, but ideally I want to observe all addresses from one device.&lt;/p&gt;
&lt;p&gt;For instance, in the OpenThread specification, it says &amp;quot;&lt;span&gt;&lt;em&gt;A Full Thread Device (FTD) always has its radio on, subscribes to the all-routers multicast address, &lt;strong&gt;and maintains IPv6 address mappings&lt;/strong&gt;&lt;/em&gt;.&amp;quot; Doesn&amp;#39;t this mean that addresses of the network nodes should be available (for the FTD&amp;#39;s) somewhere?&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;Thank you for the ML-EUD advice. I have also found a way to retrieve the EUI64 addresses of my devices, which I think is static and does not change, which is useful to me.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: OpenThread provisioning response</title><link>https://devzone.nordicsemi.com/thread/266284?ContentTypeID=1</link><pubDate>Tue, 25 Aug 2020 14:30:26 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b22a0bda-e023-4103-9be6-20ba37a6808b</guid><dc:creator>Edvin</dc:creator><description>&lt;p&gt;Hello,&lt;/p&gt;
&lt;p&gt;I spoke to our thread team regarding your ticket. Here is a summary of what they said:&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Provisioning&amp;nbsp;works like this in the coap server/client examples:&lt;br /&gt;1. The Coap server enables provisioning, now it listens to the multicast message from coap clients.&lt;br /&gt;2. The Coap client sends a multicast provisioning request.&lt;br /&gt;3. The Coap server receives the request, and executes&amp;nbsp;&lt;em&gt;on provisioning_request&lt;/em&gt;&lt;em&gt;()&lt;/em&gt;:&amp;nbsp;&lt;br /&gt;&lt;a href="https://github.com/nrfconnect/fw-nrfconnect-nrf/blob/master/samples/openthread/coap_server/src/ot_coap_utils.c#L184"&gt;https://github.com/nrfconnect/fw-nrfconnect-nrf/blob/master/samples/openthread/coap_server/src/ot_coap_utils.c#L184&lt;/a&gt;&amp;nbsp;&lt;br /&gt;4. In our case&amp;nbsp;&lt;em&gt;on provisioning_request()&lt;/em&gt; calls&amp;nbsp;&lt;em&gt;deactivate_provisioning&lt;/em&gt;&lt;em&gt;()&lt;/em&gt;:&amp;nbsp;&lt;br /&gt;&lt;a title="https://github.com/nrfconnect/fw-nrfconnect-nrf/blob/master/samples/openthread/coap_server/src/coap_server.c#l62" href="https://github.com/nrfconnect/fw-nrfconnect-nrf/blob/master/samples/openthread/coap_server/src/coap_server.c#L62" rel="noopener noreferrer" target="_blank"&gt;https://github.com/nrfconnect&lt;/a&gt;&lt;a title="https://github.com/nrfconnect/fw-nrfconnect-nrf/blob/master/samples/openthread/coap_server/src/coap_server.c#l62" href="https://github.com/nrfconnect/fw-nrfconnect-nrf/blob/master/samples/openthread/coap_server/src/coap_server.c#L62" rel="noopener noreferrer" target="_blank"&gt;/fw-nrfconnect-nrf/blob/master/samples/openthread/coap_server/src/coap_server.c#L62&lt;/a&gt;&lt;br /&gt;5. The Coap server replies to the coap server with a unicast message.&lt;br /&gt;6. The Coap client receives the unicast message, now it knows the unicast address of the coap server and sends light toggle requests directly to it.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;So the functions that you need to change are in the files that are linked.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;You say that you know &amp;quot;how to find them (the addresses) via uart and openthread commands&amp;quot;. You can look at the implementation of the CLI commands in the openthread repo on github:&lt;/p&gt;
&lt;p&gt;&lt;a href="https://github.com/openthread/openthread/blob/8370395c47333a612e117b38c3b034e61e3b8597/src/cli/cli.cpp"&gt;https://github.com/openthread/openthread/blob/8370395c47333a612e117b38c3b034e61e3b8597/src/cli/cli.cpp&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;For example the ipaddr command is found here:&lt;br /&gt;&lt;a href="https://github.com/openthread/openthread/blob/8370395c47333a612e117b38c3b034e61e3b8597/src/cli/cli.cpp#L1639"&gt;https://github.com/openthread/openthread/blob/8370395c47333a612e117b38c3b034e61e3b8597/src/cli/cli.cpp#L1639&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;I assume you are using OpenThread in NCS. All the header files comes from this repo:&lt;/p&gt;
&lt;p&gt;&lt;a href="https://github.com/nrfconnect/sdk-nrfxlib/tree/master/openthread/include/openthread"&gt;https://github.com/nrfconnect/sdk-nrfxlib/tree/master/openthread/include/openthread&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;So you can use this to check the OT API.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;One extra note on addressing:&lt;/p&gt;
&lt;p&gt;There is something called ML-EID, which you can use when communicating between the nodes. This is a randomly assigned address that is provided after provisioning. This address remains the same over power cycles and is never changed during the lifetime of the device, unlike the IP address, which may change if the device is powered off, and then reconnected to the network.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Hopefully there are some useful pointers here.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Edvin&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: OpenThread provisioning response</title><link>https://devzone.nordicsemi.com/thread/265586?ContentTypeID=1</link><pubDate>Thu, 20 Aug 2020 13:57:27 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:10ab7a85-e60c-4763-bdb6-78dbcbf83d71</guid><dc:creator>Edvin</dc:creator><description>&lt;p&gt;Hello,&lt;/p&gt;
&lt;p&gt;I am sorry for the late reply (on your other ticket as well). Most of our Thread team is on vacation right now, but some are coming back on Monday. I was hoping to hand your tickets over to him when he returns. I am sorry for the delay. In the meantime, I will try to check with some different people and see if I can find someone who can answer your questions.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Edvin&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>