Infineon Logo AIROC BTSDK v4.9 - Documentation
 
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Mesh Light HSL Client

The AIROC Mesh Light HSL Client module of the Mesh Models library provides a way for an application to configure and control color lights that support Hue/Saturation control. More...

Macros

#define WICED_BT_MESH_MODEL_LIGHT_HSL_CLIENT   { MESH_COMPANY_ID_BT_SIG, WICED_BT_MESH_CORE_MODEL_ID_LIGHT_HSL_CLNT, wiced_bt_mesh_model_light_hsl_client_message_handler, NULL, NULL }
 

Typedefs

typedef void( wiced_bt_mesh_light_hsl_client_callback_t )(uint16_t event, wiced_bt_mesh_event_t *p_event, void *p_data)
 Light HSL Client callback is called by the Mesh Models library on receiving a message from the peer. More...
 

Functions

wiced_bool_t wiced_bt_mesh_model_light_hsl_client_message_handler (wiced_bt_mesh_event_t *p_event, uint8_t *p_data, uint16_t data_len)
 Light HSL Client Message Handler. More...
 
void wiced_bt_mesh_model_light_hsl_client_init (uint8_t element_idx, wiced_bt_mesh_light_hsl_client_callback_t *p_callback, wiced_bool_t is_provisioned)
 Light HSL Client Module initialization. More...
 
wiced_result_t wiced_bt_mesh_model_light_hsl_client_send_get (wiced_bt_mesh_event_t *p_event)
 The application can call this function to send Light HSL Get message to the server. More...
 
wiced_result_t wiced_bt_mesh_model_light_hsl_client_send_set (wiced_bt_mesh_event_t *p_event, wiced_bt_mesh_light_hsl_set_t *p_data)
 The application can call this function to send Light HSL Set client message to the server. More...
 
wiced_result_t wiced_bt_mesh_model_light_hsl_client_send_hue_get (wiced_bt_mesh_event_t *p_event)
 The application can call this function to send Light HSL Hue Get message to the server. More...
 
wiced_result_t wiced_bt_mesh_model_light_hsl_client_send_hue_set (wiced_bt_mesh_event_t *p_event, wiced_bt_mesh_light_hsl_hue_set_t *p_data)
 The application can call this function to send Light HSL Hue Set client message to the server. More...
 
wiced_result_t wiced_bt_mesh_model_light_hsl_client_send_saturation_get (wiced_bt_mesh_event_t *p_event)
 The application can call this function to send Light HSL Saturation Get message to the server. More...
 
wiced_result_t wiced_bt_mesh_model_light_hsl_client_send_saturation_set (wiced_bt_mesh_event_t *p_event, wiced_bt_mesh_light_hsl_saturation_set_t *p_data)
 The application can call this function to send Light HSL Saturation Set client message to the server. More...
 
wiced_result_t wiced_bt_mesh_model_light_hsl_client_send_target_get (wiced_bt_mesh_event_t *p_event)
 The application can call this function to send Light HSL Target Get message to the server. More...
 
wiced_result_t wiced_bt_mesh_model_light_hsl_client_send_default_get (wiced_bt_mesh_event_t *p_event)
 The application can call this function to send Light HSL Get Default client message to the server. More...
 
wiced_result_t wiced_bt_mesh_model_light_hsl_client_send_default_set (wiced_bt_mesh_event_t *p_event, wiced_bt_mesh_light_hsl_default_data_t *p_data)
 The application can call this function to send Light HSL Set Default client message to the server. More...
 
wiced_result_t wiced_bt_mesh_model_light_hsl_client_send_range_get (wiced_bt_mesh_event_t *p_event)
 The application can call this function to send Light HSL Range Get client message to the server. More...
 
wiced_result_t wiced_bt_mesh_model_light_hsl_client_send_range_set (wiced_bt_mesh_event_t *p_event, wiced_bt_mesh_light_hsl_range_set_data_t *p_data)
 The application can call this function to send Light HSL Range Set client message to the server. More...
 

Detailed Description

The AIROC Mesh Light HSL Client module of the Mesh Models library provides a way for an application to configure and control color lights that support Hue/Saturation control.

To include Light HSL Client functionality, the device description shall contain WICED_BT_MESH_MODEL_LIGHT_HSL_CLIENT.

Typedef Documentation

typedef void( wiced_bt_mesh_light_hsl_client_callback_t)(uint16_t event, wiced_bt_mesh_event_t *p_event, void *p_data)

Light HSL Client callback is called by the Mesh Models library on receiving a message from the peer.

Parameters
eventThe event that the application should process (see Light HSL Events)
p_eventinformation about the message received. The same pointer should be used in the reply if required.
p_dataPointer to the level data
Returns
None

Function Documentation

void wiced_bt_mesh_model_light_hsl_client_init ( uint8_t  element_idx,
wiced_bt_mesh_light_hsl_client_callback_t p_callback,
wiced_bool_t  is_provisioned 
)

Light HSL Client Module initialization.

Parameters
element_idxDevice element to where model is used
p_callbackThe application callback function that will be executed by the mesh models library when application action is required, or when a reply for the application request has been received.
is_provisionedIf TRUE, the application is being restarted after being provisioned or after a power loss. If FALSE the model cleans up NVRAM on startup.
Returns
None
wiced_bool_t wiced_bt_mesh_model_light_hsl_client_message_handler ( wiced_bt_mesh_event_t p_event,
uint8_t *  p_data,
uint16_t  data_len 
)

Light HSL Client Message Handler.

The Mesh Core library calls this function for each message received. The function returns WICED_TRUE if the message is destined for this specific model and successfully processed, and returns WICED_FALSE otherwise. The function parses the message and if appropriate calls the parent back to perform functionality.

Parameters
p_eventMesh event with information about received message.
p_dataPointer to the data portion of the message
data_lenLength of the data in the message
Returns
WICED_TRUE if the message is for this company ID/Model/Element Index combination, WICED_FALSE otherwise.
wiced_result_t wiced_bt_mesh_model_light_hsl_client_send_default_get ( wiced_bt_mesh_event_t p_event)

The application can call this function to send Light HSL Get Default client message to the server.

Parameters
p_eventMesh event with the information about the message that has been created by the app for unsolicited message.
p_dataPointer to the data to send
Returns
WICED_BT_SUCCESS if message has been queued for transmission.
wiced_result_t wiced_bt_mesh_model_light_hsl_client_send_default_set ( wiced_bt_mesh_event_t p_event,
wiced_bt_mesh_light_hsl_default_data_t p_data 
)

The application can call this function to send Light HSL Set Default client message to the server.

Parameters
p_eventMesh event with the information about the message that has been created by the app for unsolicited message.
p_dataPointer to the data to send
Returns
WICED_BT_SUCCESS if message has been queued for transmission.
wiced_result_t wiced_bt_mesh_model_light_hsl_client_send_get ( wiced_bt_mesh_event_t p_event)

The application can call this function to send Light HSL Get message to the server.

Parameters
p_eventMesh event with the information about the message that has been created by the app for unsolicited message.
Returns
WICED_BT_SUCCESS if message has been queued for transmission.
wiced_result_t wiced_bt_mesh_model_light_hsl_client_send_hue_get ( wiced_bt_mesh_event_t p_event)

The application can call this function to send Light HSL Hue Get message to the server.

Parameters
p_eventMesh event with the information about the message that has been created by the app for unsolicited message.
Returns
WICED_BT_SUCCESS if message has been queued for transmission.
wiced_result_t wiced_bt_mesh_model_light_hsl_client_send_hue_set ( wiced_bt_mesh_event_t p_event,
wiced_bt_mesh_light_hsl_hue_set_t p_data 
)

The application can call this function to send Light HSL Hue Set client message to the server.

Parameters
p_eventMesh event with the information about the message that has been created by the app for unsolicited message.
p_dataPointer to the data to send
Returns
WICED_BT_SUCCESS if message has been queued for transmission.
wiced_result_t wiced_bt_mesh_model_light_hsl_client_send_range_get ( wiced_bt_mesh_event_t p_event)

The application can call this function to send Light HSL Range Get client message to the server.

Parameters
p_eventMesh event with the information about the message that has been created by the app for unsolicited message.
p_dataPointer to the data to send
Returns
WICED_BT_SUCCESS if message has been queued for transmission.
wiced_result_t wiced_bt_mesh_model_light_hsl_client_send_range_set ( wiced_bt_mesh_event_t p_event,
wiced_bt_mesh_light_hsl_range_set_data_t p_data 
)

The application can call this function to send Light HSL Range Set client message to the server.

Parameters
p_eventMesh event with the information about the message that has been created by the app for unsolicited message.
p_dataPointer to the data to send
Returns
WICED_BT_SUCCESS if message has been queued for transmission.
wiced_result_t wiced_bt_mesh_model_light_hsl_client_send_saturation_get ( wiced_bt_mesh_event_t p_event)

The application can call this function to send Light HSL Saturation Get message to the server.

Parameters
p_eventMesh event with the information about the message that has been created by the app for unsolicited message.
Returns
WICED_BT_SUCCESS if message has been queued for transmission.
wiced_result_t wiced_bt_mesh_model_light_hsl_client_send_saturation_set ( wiced_bt_mesh_event_t p_event,
wiced_bt_mesh_light_hsl_saturation_set_t p_data 
)

The application can call this function to send Light HSL Saturation Set client message to the server.

Parameters
p_eventMesh event with the information about the message that has been created by the app for unsolicited message.
p_dataPointer to the data to send
Returns
WICED_BT_SUCCESS if message has been queued for transmission.
wiced_result_t wiced_bt_mesh_model_light_hsl_client_send_set ( wiced_bt_mesh_event_t p_event,
wiced_bt_mesh_light_hsl_set_t p_data 
)

The application can call this function to send Light HSL Set client message to the server.

Parameters
p_eventMesh event with the information about the message that has been created by the app for unsolicited message.
p_dataPointer to the data to send
Returns
WICED_BT_SUCCESS if message has been queued for transmission.
wiced_result_t wiced_bt_mesh_model_light_hsl_client_send_target_get ( wiced_bt_mesh_event_t p_event)

The application can call this function to send Light HSL Target Get message to the server.

Parameters
p_eventMesh event with the information about the message that has been created by the app for unsolicited message.
Returns
WICED_BT_SUCCESS if message has been queued for transmission.