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

can't Send data to server from client with unicast address of server

I set the publish address of client using function:

static uint32_t set_model_publish_address(uint16_t publish_address, access_model_handle_t model_handle) {
  uint32_t status = NRF_SUCCESS;
  dsm_handle_t publish_address_handle = DSM_HANDLE_INVALID;
  access_model_publish_address_get(model_handle, &publish_address_handle);
  NRF_MESH_ASSERT(dsm_address_publish_remove(publish_address_handle) == NRF_SUCCESS);
  status = dsm_address_publish_add(publish_address, &publish_address_handle);
  if (status != NRF_SUCCESS) {
    return status;
  } else {
    return access_model_publish_address_set(model_handle, publish_address_handle);
  }
}

Unicast address of sever is 0x0003.

After setting publish address by this function, I check publish address from mobile Nrf Mesh App, and it reflects the publish address to 0x0003.

but when I publish data from client it doesn't reach to server.

Dimmer  onoff example works perfectly for client and server, but when I use this method of publication, it didn't work.

But when I use 0xC000 subscribe address (subscribed from mobile for server), it works.

Thank You

Bivay





Parents Reply Children
No Data
Related