nRF Connect SDK API 0.1.0
Loading...
Searching...
No Matches
light_ctrl_reg.h
Go to the documentation of this file.
1/*
2 * Copyright (c) 2021 Nordic Semiconductor ASA
3 *
4 * SPDX-License-Identifier: LicenseRef-Nordic-5-Clause
5 */
6
14#ifndef BT_MESH_LIGHT_CTRL_REG_H__
15#define BT_MESH_LIGHT_CTRL_REG_H__
16
17#include <zephyr/bluetooth/mesh.h>
18
19#ifdef __cplusplus
20extern "C" {
21#endif
22
25 float up;
27 float down;
28};
29
37 float accuracy;
38};
39
46 void (*init)(struct bt_mesh_light_ctrl_reg *reg);
53 void (*start)(struct bt_mesh_light_ctrl_reg *reg, uint16_t lightness);
58 void (*stop)(struct bt_mesh_light_ctrl_reg *reg);
62 float measured;
64 void (*updated)(struct bt_mesh_light_ctrl_reg *reg, float output);
66 void *user_data;
68 float target;
69 float prev_target;
70 int32_t transition_time;
71 int64_t transition_start;
73};
74
89 float target,
90 int32_t transition_time);
91
103
104#ifdef __cplusplus
105}
106#endif
107
108#endif /* BT_MESH_LIGHT_CTRL_REG_H__ */
109
void bt_mesh_light_ctrl_reg_target_set(struct bt_mesh_light_ctrl_reg *reg, float target, int32_t transition_time)
Set the target lightness for the regulator.
float bt_mesh_light_ctrl_reg_target_get(struct bt_mesh_light_ctrl_reg *reg)
Get the target lightness for the regulator.
struct bt_mesh_light_ctrl_reg_coeff ki
Definition: light_ctrl_reg.h:33
float accuracy
Definition: light_ctrl_reg.h:37
struct bt_mesh_light_ctrl_reg_coeff kp
Definition: light_ctrl_reg.h:35
Definition: light_ctrl_reg.h:31
float up
Definition: light_ctrl_reg.h:25
float down
Definition: light_ctrl_reg.h:27
Definition: light_ctrl_reg.h:23
struct bt_mesh_light_ctrl_reg_cfg cfg
Definition: light_ctrl_reg.h:60
void(* updated)(struct bt_mesh_light_ctrl_reg *reg, float output)
Definition: light_ctrl_reg.h:64
void(* init)(struct bt_mesh_light_ctrl_reg *reg)
Definition: light_ctrl_reg.h:46
void * user_data
Definition: light_ctrl_reg.h:66
float measured
Definition: light_ctrl_reg.h:62
void(* stop)(struct bt_mesh_light_ctrl_reg *reg)
Definition: light_ctrl_reg.h:58
void(* start)(struct bt_mesh_light_ctrl_reg *reg, uint16_t lightness)
Definition: light_ctrl_reg.h:53
Definition: light_ctrl_reg.h:41