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,
96#if !defined(CONFIG_BT_MESH_SENSOR_USE_LEGACY_SENSOR_VALUE) || defined(__DOXYGEN__)
109 struct bt_mesh_msg_ctx *ctx,
125 struct bt_mesh_msg_ctx *ctx,
127 const struct sensor_value *value);
141 struct bt_mesh_msg_ctx *ctx,
154 struct bt_mesh_model_pub
pub;
159 BT_MESH_LIGHT_CTRL_OP_PROP_SET,
193 struct bt_mesh_msg_ctx *ctx,
bool *rsp);
220 struct bt_mesh_msg_ctx *ctx,
bool enabled,
240 struct bt_mesh_msg_ctx *ctx,
298 bool enabled,
bool *rsp);
344 struct bt_mesh_msg_ctx *ctx,
374 struct bt_mesh_msg_ctx *ctx,
400#if !defined(CONFIG_BT_MESH_SENSOR_USE_LEGACY_SENSOR_VALUE) || defined(__DOXYGEN__)
426 struct bt_mesh_msg_ctx *ctx,
456 struct bt_mesh_msg_ctx *ctx,
480 struct bt_mesh_msg_ctx *ctx,
509 struct bt_mesh_msg_ctx *ctx,
511 struct sensor_value *rsp);
539 struct bt_mesh_msg_ctx *ctx,
541 const struct sensor_value *val,
542 struct sensor_value *rsp);
562 struct bt_mesh_msg_ctx *ctx,
564 const struct sensor_value *val);
588 struct bt_mesh_msg_ctx *ctx,
614 struct bt_mesh_msg_ctx *ctx,
616 float val,
float *rsp);
636 struct bt_mesh_msg_ctx *ctx,
641extern const struct bt_mesh_model_op _bt_mesh_light_ctrl_cli_op[];
642extern 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:108
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:140
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:160
uint8_t tid
Definition: light_ctrl_cli.h:166
struct net_buf_simple pub_buf
Definition: light_ctrl_cli.h:156
const struct bt_mesh_model * model
Definition: light_ctrl_cli.h:152
struct bt_mesh_model_pub pub
Definition: light_ctrl_cli.h:154
struct bt_mesh_msg_ack_ctx ack_ctx
Definition: light_ctrl_cli.h:162
const struct bt_mesh_light_ctrl_cli_handlers * handlers
Definition: light_ctrl_cli.h:164
Light Lightness Control Client instance.
Definition: light_ctrl_cli.h:150
Definition: gen_onoff.h:24
Definition: gen_onoff.h:40