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

What are the constants in nrf_mesh_config_node_app.h used for?

I have a hard time figuring out what some of the constants in nrf_mesh_config_node_app.h for my Bluetooth Mesh application should be set as. Instead of writing a question for each of the constants i have listed the ones i don't understand here.

I am making a Bluetooth beacon connecting to a mesh network. It broadcasts data received from the provisioner. I have therefore implemented a beacon model for the client and server. There is also going to another type of device that will receive the broadcast data and send messages to the provisioner according the beacon data and real world events. If it is possible to describe the constants according to the specification, i think i will easier to understand.

DEVICE_PRODUCT_ID & DEVICE_VENDOR_ID In all examples these are both set as 0x0000, what could these constants be used for?

DSM_SUBNET_MAX Is this the maximum number of subnetworks in the network or the maximum number of subnetworks this node can be a part of?

DSM_APP_MAX The description for this is "Maximum number of applications" but what counts as a application? And is it the number of applications in this node or the whole network?

DSM_DEVICE_MAX I am no sure what this is used for? In the Light Switch client example it set to SERVER_COUNT so does i count the number of devices this node will know about?

DSM_KEY_REFRESH_KEYS_MAX I have no idea of what this is used for?

DSM_VIRTUAL_ADDR_MAX I am not completely sure what a Virtual address is and what it is used for?

DSM_FLASH_PAGE_COUNT When should this not be set as 1?

  • Hi Søren,

    Please be aware that our SDK is the implementation of the Bluetooth Mesh spec (check Mesh profile). We assume that users should have some basic understanding of the Bluetooth Mesh spec when they start using the SDK.

    Most of the question can be answered with the information from the spec:

    DEVICE_PRODUCT_ID & DEVICE_VENDOR_ID: are the information should be included in the composition data (Section 4.2). This is defined by the vendor, and used by the configuration client. It's up to the developer of the configuration client on what to do with it. For example product ID == Door bell then assign door bell application key for.

    DSM_SUBNET_MAX: Section 2.2.1

    DSM_APP_MAX: limit the max number of application key.

    DSM_DEVICE_MAX: Max number of device key (for provisioning)

    DSM_KEY_REFRESH_KEYS_MAX: We don't support key refresh yet so it = 1

    DSM_VIRTUAL_ADDR_MAX: Please check the spec (2.3.5)

    DSM_FLASH_PAGE_COUNT: When you use flash for your application, not only 1 page for DSM data storage.

Related