14#ifndef BT_MESH_LIGHT_CTRL_CLI_H__
15#define BT_MESH_LIGHT_CTRL_CLI_H__
36#define BT_MESH_LIGHT_CTRL_CLI_INIT(_handlers) \
38 .handlers = _handlers, \
47#define BT_MESH_MODEL_LIGHT_CTRL_CLI(_cli) \
49 BT_MESH_MODEL_ID_LIGHT_LC_CLI, _bt_mesh_light_ctrl_cli_op, \
51 BT_MESH_MODEL_USER_DATA(struct bt_mesh_light_ctrl_cli, _cli), \
52 &_bt_mesh_light_ctrl_cli_cb)
66 struct bt_mesh_msg_ctx *ctx,
bool enabled);
79 struct bt_mesh_msg_ctx *ctx,
bool enabled);
93 struct bt_mesh_msg_ctx *ctx,
108 struct bt_mesh_msg_ctx *ctx,
123 struct bt_mesh_msg_ctx *ctx,
136 struct bt_mesh_model_pub
pub;
141 BT_MESH_LIGHT_CTRL_OP_PROP_SET,
175 struct bt_mesh_msg_ctx *ctx,
bool *rsp);
202 struct bt_mesh_msg_ctx *ctx,
bool enabled,
222 struct bt_mesh_msg_ctx *ctx,
280 bool enabled,
bool *rsp);
326 struct bt_mesh_msg_ctx *ctx,
356 struct bt_mesh_msg_ctx *ctx,
407 struct bt_mesh_msg_ctx *ctx,
437 struct bt_mesh_msg_ctx *ctx,
461 struct bt_mesh_msg_ctx *ctx,
486 struct bt_mesh_msg_ctx *ctx,
512 struct bt_mesh_msg_ctx *ctx,
514 float val,
float *rsp);
534 struct bt_mesh_msg_ctx *ctx,
539extern const struct bt_mesh_model_op _bt_mesh_light_ctrl_cli_op[];
540extern const struct bt_mesh_model_cb _bt_mesh_light_ctrl_cli_cb;
int bt_mesh_light_ctrl_cli_light_onoff_set_unack(struct bt_mesh_light_ctrl_cli *cli, struct bt_mesh_msg_ctx *ctx, const struct bt_mesh_onoff_set *set)
Tell a Light Lightness Control Server to turn the light on or off without requesting a response.
int bt_mesh_light_ctrl_cli_occupancy_enabled_get(struct bt_mesh_light_ctrl_cli *cli, struct bt_mesh_msg_ctx *ctx, bool *rsp)
Get a Light Lightness Control Server's current Occupancy Mode.
int bt_mesh_light_ctrl_cli_mode_get(struct bt_mesh_light_ctrl_cli *cli, struct bt_mesh_msg_ctx *ctx, bool *rsp)
Get a Light Lightness Control Server's current Mode.
int bt_mesh_light_ctrl_cli_mode_set(struct bt_mesh_light_ctrl_cli *cli, struct bt_mesh_msg_ctx *ctx, bool enabled, bool *rsp)
Set a Light Lightness Control Server's current Mode.
int bt_mesh_light_ctrl_cli_light_onoff_get(struct bt_mesh_light_ctrl_cli *cli, struct bt_mesh_msg_ctx *ctx, struct bt_mesh_onoff_status *rsp)
Get a Light Lightness Control Server's current OnOff state.
int bt_mesh_light_ctrl_cli_coeff_set_unack(struct bt_mesh_light_ctrl_cli *cli, struct bt_mesh_msg_ctx *ctx, enum bt_mesh_light_ctrl_coeff id, float val)
Set a Light Lightness Control Server Regulator Coefficient value without requesting a response.
int bt_mesh_light_ctrl_cli_prop_set(struct bt_mesh_light_ctrl_cli *cli, struct bt_mesh_msg_ctx *ctx, enum bt_mesh_light_ctrl_prop id, const struct bt_mesh_sensor_value *val, struct bt_mesh_sensor_value *rsp)
Set a Light Lightness Control Server property value.
int bt_mesh_light_ctrl_cli_mode_set_unack(struct bt_mesh_light_ctrl_cli *cli, struct bt_mesh_msg_ctx *ctx, bool enabled)
Set a Light Lightness Control Server's current Mode without requesting a response.
int bt_mesh_light_ctrl_cli_prop_set_unack(struct bt_mesh_light_ctrl_cli *cli, struct bt_mesh_msg_ctx *ctx, enum bt_mesh_light_ctrl_prop id, const struct bt_mesh_sensor_value *val)
Set a Light Lightness Control Server property value without requesting a response.
int bt_mesh_light_ctrl_cli_prop_get(struct bt_mesh_light_ctrl_cli *cli, struct bt_mesh_msg_ctx *ctx, enum bt_mesh_light_ctrl_prop id, struct bt_mesh_sensor_value *rsp)
Get a Light Lightness Control Server property value.
int bt_mesh_light_ctrl_cli_occupancy_enabled_set(struct bt_mesh_light_ctrl_cli *cli, struct bt_mesh_msg_ctx *ctx, bool enabled, bool *rsp)
Set a Light Lightness Control Server's current Occupancy Mode.
int bt_mesh_light_ctrl_cli_coeff_get(struct bt_mesh_light_ctrl_cli *cli, struct bt_mesh_msg_ctx *ctx, enum bt_mesh_light_ctrl_coeff id, float *rsp)
Get a Light Lightness Control Server Regulator Coefficient value.
int bt_mesh_light_ctrl_cli_coeff_set(struct bt_mesh_light_ctrl_cli *cli, struct bt_mesh_msg_ctx *ctx, enum bt_mesh_light_ctrl_coeff id, float val, float *rsp)
Set a Light Lightness Control Server Regulator Coefficient value.
int bt_mesh_light_ctrl_cli_light_onoff_set(struct bt_mesh_light_ctrl_cli *cli, struct bt_mesh_msg_ctx *ctx, const struct bt_mesh_onoff_set *set, struct bt_mesh_onoff_status *rsp)
Tell a Light Lightness Control Server to turn the light on or off.
int bt_mesh_light_ctrl_cli_occupancy_enabled_set_unack(struct bt_mesh_light_ctrl_cli *cli, struct bt_mesh_msg_ctx *ctx, bool enabled)
Set a Light Lightness Control Server's current Occupancy Mode without requesting a response.
bt_mesh_light_ctrl_prop
Definition light_ctrl.h:24
bt_mesh_light_ctrl_coeff
Definition light_ctrl.h:153
#define CONFIG_BT_MESH_SENSOR_CHANNEL_ENCODED_SIZE_MAX
Definition sensor.h:26
void(* prop)(struct bt_mesh_light_ctrl_cli *cli, struct bt_mesh_msg_ctx *ctx, enum bt_mesh_light_ctrl_prop id, const struct bt_mesh_sensor_value *value)
Light LC Property status handler.
Definition light_ctrl_cli.h:107
void(* mode)(struct bt_mesh_light_ctrl_cli *cli, struct bt_mesh_msg_ctx *ctx, bool enabled)
Light LC Mode status handler.
Definition light_ctrl_cli.h:65
void(* occupancy_mode)(struct bt_mesh_light_ctrl_cli *cli, struct bt_mesh_msg_ctx *ctx, bool enabled)
Light LC Occupancy Mode status handler.
Definition light_ctrl_cli.h:78
void(* light_onoff)(struct bt_mesh_light_ctrl_cli *cli, struct bt_mesh_msg_ctx *ctx, const struct bt_mesh_onoff_status *status)
Light LC OnOff status handler.
Definition light_ctrl_cli.h:92
void(* coeff)(struct bt_mesh_light_ctrl_cli *cli, struct bt_mesh_msg_ctx *ctx, enum bt_mesh_light_ctrl_coeff id, float value)
Light LC Regulator Coefficient status handler.
Definition light_ctrl_cli.h:122
Definition light_ctrl_cli.h:55
uint8_t pub_data[BT_MESH_MODEL_BUF_LEN(BT_MESH_LIGHT_CTRL_OP_PROP_SET, 2+CONFIG_BT_MESH_SENSOR_CHANNEL_ENCODED_SIZE_MAX)]
Definition light_ctrl_cli.h:142
uint8_t tid
Definition light_ctrl_cli.h:148
struct net_buf_simple pub_buf
Definition light_ctrl_cli.h:138
const struct bt_mesh_model * model
Definition light_ctrl_cli.h:134
struct bt_mesh_model_pub pub
Definition light_ctrl_cli.h:136
struct bt_mesh_msg_ack_ctx ack_ctx
Definition light_ctrl_cli.h:144
const struct bt_mesh_light_ctrl_cli_handlers * handlers
Definition light_ctrl_cli.h:146
Light Lightness Control Client instance.
Definition light_ctrl_cli.h:132
Definition gen_onoff.h:24
Definition gen_onoff.h:40