nRF Connect SDK API 2.8.99
|
int bt_mesh_onoff_srv_pub | ( | struct bt_mesh_onoff_srv * | srv, |
struct bt_mesh_msg_ctx * | ctx, | ||
const struct bt_mesh_onoff_status * | status ) |
#include <include/bluetooth/mesh/gen_onoff_srv.h>
Publish the Generic OnOff Server model status.
Asynchronously publishes a Generic OnOff status message with the configured publish parameters.
[in] | srv | Server instance to publish on. |
[in] | ctx | Message context to send with, or NULL to send with the default publish parameters. |
[in] | status | Current status. |
0 | Successfully published a Generic OnOff Status message. |
-EADDRNOTAVAIL | A message context was not provided and publishing is not configured. |
-EAGAIN | The device has not been provisioned. |