nimble/mesh: Fix Light Lightness Status

We were sending Light lightness status with a wrong
opcode.
This commit is contained in:
Michał Narajowski
2019-11-14 09:21:15 +01:00
parent 81ab69c74d
commit 9cb587e534
2 changed files with 2 additions and 1 deletions
+1
View File
@@ -32,6 +32,7 @@ struct bt_mesh_net;
#define OP_LIGHT_LIGHTNESS_GET BT_MESH_MODEL_OP_2(0x82, 0x4b)
#define OP_LIGHT_LIGHTNESS_SET BT_MESH_MODEL_OP_2(0x82, 0x4c)
#define OP_LIGHT_LIGHTNESS_SET_UNACK BT_MESH_MODEL_OP_2(0x82, 0x4d)
#define OP_LIGHT_LIGHTNESS_STATUS BT_MESH_MODEL_OP_2(0x82, 0x4e)
bool bt_mesh_is_provisioned(void);
+1 -1
View File
@@ -128,7 +128,7 @@ static void light_lightness_status(struct bt_mesh_model *model,
struct os_mbuf *msg = NET_BUF_SIMPLE(4);
s16_t *lightness;
bt_mesh_model_msg_init(msg, OP_GEN_LEVEL_STATUS);
bt_mesh_model_msg_init(msg, OP_LIGHT_LIGHTNESS_STATUS);
lightness = net_buf_simple_add(msg, 2);
if (cb && cb->get) {
cb->get(model, lightness);