This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Mesh SDK 2.2.0 Group Address

Hi Developers, 

I am exploring the light switch examples, client, server and provisioner, every time a node is provisioned it uses a unicast address, what if I want to use different groups for different nodes functionalities 

what changes should I do to manage multiple group address?

what changes should I do to node_setup.c inside the provisioner example, and/or the client and server examples?

  • Hi,

    I might be wrong here, but what you want to do is to publish/subscribe to a group address right? 

    Not sure what you mean by " manage multiple group address"? Do want to publish/subscribe to multiple group addresses?

    Inside node_setup.c, if you have a look at NODE_SETUP_CONFIG_PUBLICATION_ONOFF_CLIENT1 and NODE_SETUP_CONFIG_PUBLICATION_ONOFF_CLIENT2, you can see how the example configure the client to publish to two different group addresses. Inside NODE_SETUP_CONFIG_SUBSCRIPTION_ONOFF_SERVER you will find how the example configure the servers to subscribe to the group addresses.

  • Hi , I am planning to have a couple of nodes being clients and 3 or 4 relaying messages (all them being e.g group address A), then all end nodes being e,g group address B, C, D...

    Then subscribe all the nodes in the network to receive messages from the Group address A, and be able to receive the sensor data from all my groups in both clients (group address A)

  • I think you might have misunderstood how group addresses work. A group address can be published or subscribed to, it is not assigned to a node like with unicast addresses. So, in my understanding, you want all your end nodes to receive messages from your clients and both your clients to receive from all of your end nodes? 

  • Hi that is exactly what I want to do, all my end nodes (sensors) receiving messages from my clients and all my clients receiving messages from my end nodes, I think the easier way to do it is using groups addresses instead of unicast address, at this time it does not matter if I get duplicates on the clients nodes I am going to filter it using a high-level app

  • Yes, it will be easier if you use group addresses. You should let both your clients publish to a group address and then have your end nodes(sensors) subscribe to the same address. The same should be done with your end nodes, publish to another group address and have your clients subscribe to this address. You can see here which group addresses that can be used.

Related