Trying to get the realm local address, and verifying the multicast functionality of OTBR

hi there,

I am currently trying to use the samples of "ncs/nrf/samples/openthread/coap_server" and "coap_client". I have flashed them onto two nrf52840dk_nrf52840 development boards. I have called the API to attempt to obtain the realm local multicast address and tried to use OTBR running on a Raspberry Pi to send multicast packets to the realm local multicast address. My ultimate goal is to verify whether messages sent to the realm local address in the Thread network will be resent twice due to the MPL mechanism. At the moment, I have the following questions:

  1. When I obtain the realm local multicast address, does it mean that devices in the Thread network composed of coap_server and coap_client have all subscribed to this realm local address? If I send multicast packet information to this address, can they receive it? if they still not subscribe the address, what should i do to let them subscribe it?

  2. How can I verify the information sent to the multicast address? The methods I am currently considering are using a dongle to capture packets in the air(sniffer) for verification or printing the received multicast information in the RTT viewer window. However, I lack experience in this and would like to know if there are similar samples that I can refer to.

Thank you very much. If more information is needed, please reply, and I will provide it immediately.

best regards,

Zhou

ps. this is how i get the realm local address

		switch(deviceRole){
			case OT_DEVICE_ROLE_CHILD:
				printk("THREAD_CONNECTED\n");
				printk("CHILD Role.\n");
				break;
			case OT_DEVICE_ROLE_ROUTER:
				printk("THREAD_CONNECTED\n");
				printk("ROUTER Role.\n");
				//when the coap_server become the router in the thread network, try to get the realm local address
				ipaddress = otThreadGetRealmLocalAllThreadNodesMulticastAddress(ot);
				for (int i = 0; i < 8; ++i){
					ipv6_16bit[i] = ipaddress->mFields.m16[i];
				}
				printk("Realm Local ipv6 address listed below:\n");
				printk("%04x:%04x:%04x:%04x:%04x:%04x:%04x:%04x\n",
						ipv6_16bit[0],ipv6_16bit[1],ipv6_16bit[2],ipv6_16bit[3],
						ipv6_16bit[4],ipv6_16bit[5],ipv6_16bit[6],ipv6_16bit[7]);
				break;

Parents
  • hi, just for additional information, i have tested that for both the client and the server example, they will all get the same realm local address, which should be the good news? cause i need them to  be in the same realm local area, but i realized one wired thing, which is that, everytime i start two nrf52840dk board, they will get the same realm local address for ALL THE TIME, every time they got the same result.
    the realm local address will be : 33ff:4000:d9fd:08a6:197b:899a:0000:0100, but as far as i know,  the realm local addrees depneds on the mesh local prefix,Could it be that every time I start two development boards, their mesh local prefixes are the same?Maybe there are some deviations in my understanding. I hope you can correct me. Thank you very much.

Reply
  • hi, just for additional information, i have tested that for both the client and the server example, they will all get the same realm local address, which should be the good news? cause i need them to  be in the same realm local area, but i realized one wired thing, which is that, everytime i start two nrf52840dk board, they will get the same realm local address for ALL THE TIME, every time they got the same result.
    the realm local address will be : 33ff:4000:d9fd:08a6:197b:899a:0000:0100, but as far as i know,  the realm local addrees depneds on the mesh local prefix,Could it be that every time I start two development boards, their mesh local prefixes are the same?Maybe there are some deviations in my understanding. I hope you can correct me. Thank you very much.

Children
No Data
Related