38 #ifndef LIGHT_LIGHTNESS_CLIENT_H__ 39 #define LIGHT_LIGHTNESS_CLIENT_H__ 44 #include "access_reliable.h" 45 #include "light_lightness_common.h" 46 #include "light_lightness_messages.h" 56 #define LIGHT_LIGHTNESS_CLIENT_MODEL_ID 0x1302 uint32_t light_lightness_client_linear_set(light_lightness_client_t *p_client, const light_lightness_linear_set_params_t *p_params, const model_transition_t *p_transition)
Sends a Linear Set message to the server.
uint32_t light_lightness_client_default_get(light_lightness_client_t *p_client)
Sends a Default Get message to the server.
Message format for the light_lightness Linear set message.
const light_lightness_client_callbacks_t * p_callbacks
Callback list.
uint16_t access_model_handle_t
Access layer handle type.
uint32_t light_lightness_client_set_unack(light_lightness_client_t *p_client, const light_lightness_set_params_t *p_params, const model_transition_t *p_transition, uint8_t repeats)
Sends a Set Unacknowledged message to the server.
light_lightness_linear_set_msg_pkt_t linear_set
Storage for the Light Lightness Linear Set message.
light_lightness_last_state_status_cb_t lightness_last_status_cb
Callback for the Light Lightness Last Status message.
uint32_t light_lightness_client_range_set(light_lightness_client_t *p_client, const light_lightness_range_set_params_t *p_params)
Sends a Range Set message to the server.
Parameters for the light_lightness Linear Status message.
light_lightness_state_status_cb_t lightness_status_cb
Client model response message callback.
nrf_mesh_transmic_size_t transmic_size
TransMIC size used by the outgoing server messages.
void(* light_lightness_linear_state_status_cb_t)(const light_lightness_client_t *p_self, const access_message_rx_meta_t *p_meta, const light_lightness_linear_status_params_t *p_in)
Callback type for linear lightness state related transactions.
Message format for the light_lightness Default set message.
Parameters for the light_lightness Last Status message.
light_lightness_client_msg_data_t msg_pkt
Holds the raw message packet data for transactions.
access_model_handle_t model_handle
Model handle assigned to this instance.
void(* access_publish_timeout_cb_t)(access_model_handle_t handle, void *p_args)
Access layer publish timeout event callback.
uint32_t light_lightness_client_range_set_unack(light_lightness_client_t *p_client, const light_lightness_range_set_params_t *p_params, uint8_t repeats)
Sends a Range Set Unacknowledged message to the server.
light_lightness_range_state_status_cb_t lightness_range_status_cb
Callback for the Light Lightness Range Status message.
Unpacked message structure typedefs are used for API interfaces and for implementing model code...
uint32_t light_lightness_client_default_set_unack(light_lightness_client_t *p_client, const light_lightness_default_set_params_t *p_params, uint8_t repeats)
Sends a Default Set Unacknowledged message to the server.
Message format for the Light Lightness Default Set message.
light_lightness_range_set_msg_pkt_t range_set
Storage for the Light Lightness Range Set message.
uint32_t light_lightness_client_init(light_lightness_client_t *p_client, uint8_t element_index)
Initializes Light Lightness client.
void(* light_lightness_state_status_cb_t)(const light_lightness_client_t *p_self, const access_message_rx_meta_t *p_meta, const light_lightness_status_params_t *p_in)
Callback type for lightness state related transactions.
uint32_t light_lightness_client_set(light_lightness_client_t *p_client, const light_lightness_set_params_t *p_params, const model_transition_t *p_transition)
Sends a Set message to the server.
access_reliable_cb_t ack_transaction_status_cb
Callback to call after the acknowledged transaction has ended.
uint32_t light_lightness_client_linear_set_unack(light_lightness_client_t *p_client, const light_lightness_linear_set_params_t *p_params, const model_transition_t *p_transition, uint8_t repeats)
Sends a Linear Set Unacknowledged message to the server.
uint32_t light_lightness_client_linear_get(light_lightness_client_t *p_client)
Sends a Linear Get message to the server.
Packed message structure typedefs are used for packing and unpacking byte stream. ...
void(* light_lightness_last_state_status_cb_t)(const light_lightness_client_t *p_self, const access_message_rx_meta_t *p_meta, const light_lightness_last_status_params_t *p_in)
Callback type for last state related transactions.
light_lightness_linear_state_status_cb_t lightness_linear_status_cb
Callback for the Light Lightness Linear Status message.
Parameters for the light_lightness Default Status message.
Union for holding current message packet.
Message format for the Light Lightness Linear Set message.
Access layer acknowledged publish parameter structure.
bool force_segmented
If server should force outgoing messages as segmented messages.
light_lightness_default_set_msg_pkt_t default_set
Storage for the Light Lightness Default Set message.
nrf_mesh_transmic_size_t
Message MIC size selection.
light_lightness_default_state_status_cb_t lightness_default_status_cb
Callback for the Light Lightness Default Status message.
light_lightness_client_settings_t settings
Model settings and callbacks for this instance.
access_publish_timeout_cb_t periodic_publish_cb
callback called at the end of the each period for the publishing
uint32_t timeout
Reliable message timeout in microseconds.
uint32_t light_lightness_client_last_get(light_lightness_client_t *p_client)
Sends a Last Get message to the server.
void(* access_reliable_cb_t)(access_model_handle_t model_handle, void *p_args, access_reliable_status_t status)
Access layer acknowledged message callback type.
uint32_t light_lightness_client_default_set(light_lightness_client_t *p_client, const light_lightness_default_set_params_t *p_params)
Sends a Default Set message to the server.
Message format for the light_lightness Range set message.
Parameters for the light_lightness Status message.
Message format for the Light Lightness Range Set message.
Parameters for the light_lightness Range Status message.
void(* light_lightness_range_state_status_cb_t)(const light_lightness_client_t *p_self, const access_message_rx_meta_t *p_meta, const light_lightness_range_status_params_t *p_in)
Callback type for range state related transactions.
Generic Transition parameters for the model messages.
uint32_t light_lightness_client_range_get(light_lightness_client_t *p_client)
Sends a Range Get message to the server.
User provided settings and callbacks for the model instance.
void(* light_lightness_default_state_status_cb_t)(const light_lightness_client_t *p_self, const access_message_rx_meta_t *p_meta, const light_lightness_default_status_params_t *p_in)
Callback type for default state related transactions.
uint32_t light_lightness_client_get(light_lightness_client_t *p_client)
Sends a Get message to the server.