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

Show Subscription and Publishing addresses list for a mesh node using Mesh SDK 3.1.0

Dear dev community,

I've got a very simple question: How can I see the subscription and publishing addresses list in any mesh node for any model?

Thank you!

Regards,

//EA

Parents Reply
  • Hi Bjorn. Thanks for replying. I apologize for not replying earlier, I was in vacations and arrived today back to office.
    I appreciate your reply. But my question was different. Perhaps I wasn't clear enough. My question is:

    How can I show the subscription and publishing addresses within the mesh node FIRMWARE (such that I could share that date via UART or RTT or any other data-link/ flash storage). 

    I just need to know can I expose these lists from the DSM or any other mesh protocol-stack layer where that information is kept...

    Thank you very much!

    Regards,

    //EA

Children
  • Hi EA, 

    Bjørn is on vacation so I will take over the case. 

    Actually what Bjørn suggested is relevant. You can use CONFIG_OPCODE_MODEL_PUBLICATION_GET opcode to get the current publication configuration of the model via the config server. 

    In your case you want to get the publication address locally, you can actually follow what we have inside send_publication_status() (called by handle_config_model_publication_get() ) in config_server.c to know how to get the value out. 

    Basically you would need to get the publish address handler of the model, and then from that find the actual address in dsm database, using dsm_address_get(). You can find other publication configuration inside send_publication_status() code as well. 

Related