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

Provisioning problem with Mesh SDK 2.0

I try to make a simple project based on a "simple message model" (https://devzone.nordicsemi.com/f/nordic-q-a/29836/send-and-receive-a-string-via-access-layer) with Mesh SDK 2.0 and S132 ver. 6.0. I implemented logging on both sides (see attached file).

I was able to trace the problem to the following issue (check last 6 lines of the attached file): A number of configured devices is increased to 1 in provisioner_helper.c, however the main.c still reads the value as 0. How is this possible and how to fix this?

Server side:

<t:          0>, main.c,  343, ----- BLE Mesh Light Switch Server Demo -----
<t:          0>, mesh_softdevice_init.c,  107, Initializing SoftDevice...
<t:          0>, mesh_softdevice_init.c,   72, Enabling BLE...
<t:          2>, mesh_softdevice_init.c,   83, Ram base: 0x20006000
<t:         18>, mesh_softdevice_init.c,   99, sd_ble_enable: app_ram_base should be adjusted to 0x200032C8
<t:        532>, main.c,  317, Initializing and adding models
<t:       5389>, main.c,  374, Device UUID : 0059FFFF000000001FBA307C8E0811BF
<t:     531088>, main.c,  192, Successfully provisioned

Client & provisioner:

<t:          0>, mesh_softdevice_init.c,  107, Initializing SoftDevice...
<t:          0>, mesh_softdevice_init.c,   72, Enabling BLE...
<t:          2>, mesh_softdevice_init.c,   83, Ram base: 0x20006000
<t:         18>, mesh_softdevice_init.c,   99, sd_ble_enable: app_ram_base should be adjusted to 0x200032C8
<t:        531>, main.c,  508, Initializing and adding models
<t:        543>, main.c,  600, Load cleared app data
<t:        545>, main.c,  618, Configured & provisioned devices set to 0
<t:        549>, main.c,  722, Setup defaults: Adding keys, addresses, and bindings 
<t:        694>, provisioner_helper.c,  292, netkey_handle: 0
<t:        705>, main.c,  689, Waiting for Server node to be provisioned ...
<t:       5556>, provisioner_helper.c,  217, Scanning For Unprovisioned Devices
<t:       5559>, main.c,  762, <start> 
<t:       5671>, main.c,  652, Flash write complete
<t:       5967>, main.c,  652, Flash write complete
<t:      53994>, provisioner_helper.c,  125, UUID seen: 0059FFFF000000001FBA307C8E0811BF
<t:      53997>, provisioner_helper.c,   77, Any UUID accepted
<t:      54534>, provisioner_helper.c,  196, Provisioning link established
<t:      67500>, provisioner_helper.c,  191, Static authentication data provided
<t:      79053>, provisioner_helper.c,  160, Provisioning completed received
<t:      79056>, provisioner_helper.c,  412, Provisioning complete. Adding address 0x0100.
<t:      79062>, provisioner_helper.c,  311, Getting composition data
<t:      83012>, provisioner_helper.c,  135, Local provisioning link closed: prov_state: 4  remaining retries: 2
<t:     135077>, provisioner_helper.c,  441, Config client event
<t:     135080>, provisioner_helper.c,  454, Composition data: 0059000000000020000100000002010000020059000000
<t:     135084>, provisioner_helper.c,  318, Adding appkey
<t:     138854>, provisioner_helper.c,  441, Config client event
<t:     138857>, provisioner_helper.c,  326, Binding appkey to the Health model
<t:     139686>, provisioner_helper.c,  441, Config client event
<t:     139689>, provisioner_helper.c,  337, Binding appkey to the Simple On/Off model
<t:     140614>, provisioner_helper.c,  441, Config client event
<t:     140616>, provisioner_helper.c,  361, Setting publication address for the health server to 0x0001
<t:     143736>, provisioner_helper.c,  441, Config client event
<t:     143738>, provisioner_helper.c,  382, Setting publication address for the On/Off server to 0x0001
<t:     147294>, provisioner_helper.c,  441, Config client event
<t:     147297>, provisioner_helper.c,  390, Adding subscription
<t:     149178>, provisioner_helper.c,  441, Config client event
<t:     149517>, main.c,  170, 4.55 : Configuration of device 0 successful
<t:     149521>, provisioner_helper.c,  509, Configured devices++, now 1
<t:     149524>, provisioner_helper.c,  217, Scanning For Unprovisioned Devices
<t:     373040>, main.c,  170, 11.37 : Button 0 pressed
<t:     373043>, main.c,  340, Configured devices = 0
<t:     373378>, main.c,  170, 11.38 : No devices provisioned

Related