Trident IoT Zigbee SDK
Loading...
Searching...
No Matches
Collaboration diagram for Thermostat server Callbacks:

Functions

void tr_thermostat_server_init_cb (zb_uint8_t endpoint)
 Callback fires when the Thermostat server cluster plugin is initialized.
zb_bool_t tr_thermostat_server_command_received_cb (zb_zcl_parsed_hdr_t *cmd_info)
 Callback that user can declare to handle any Thermostat server commands.
void tr_thermostat_server_write_attr_cb (zb_uint8_t endpoint, zb_uint16_t attr_id, zb_uint8_t *new_value, zb_uint16_t manuf_code)
 Callback fires when an Thermostat server attribute is about to be written.
zb_bool_t tr_thermostat_server_setpoint_raise_lower_cb (zb_zcl_parsed_hdr_t *cmd_info, zb_uint8_t endpoint, zb_uint8_t mode, zb_int8_t amount)
 Callback that user can declare to handle thermostat cluster setpoint raise lower command.
zb_bool_t tr_thermostat_server_set_weekly_schedule_cb (zb_zcl_parsed_hdr_t *cmd_info, zb_uint8_t endpoint, zb_uint8_t number_of_transitions_for_sequence, zb_uint8_t day_of_week_for_sequence, zb_uint8_t mode_for_sequence, zb_uint8_t *payload)
 Callback that user can declare to handle thermostat cluster set weekly schedule command.
zb_bool_t tr_thermostat_server_get_weekly_schedule_cb (zb_zcl_parsed_hdr_t *cmd_info, zb_uint8_t endpoint, zb_uint8_t days_to_return, zb_uint8_t mode_to_return)
 Callback that user can declare to handle thermostat cluster get weekly schedule command.
zb_bool_t tr_thermostat_server_clear_weekly_schedule_cb (zb_zcl_parsed_hdr_t *cmd_info, zb_uint8_t endpoint)
 Callback that user can declare to handle thermostat cluster clear weekly schedule command.
zb_bool_t tr_thermostat_server_get_relay_status_log_cb (zb_zcl_parsed_hdr_t *cmd_info, zb_uint8_t endpoint)
 Callback that user can declare to handle thermostat cluster get relay status log command.
zb_bool_t tr_thermostat_server_get_time_day_cb (zb_uint16_t *curr_time_in_mins, zb_uint8_t *curr_day_of_the_week, zb_uint8_t *curr_day, zb_uint8_t *curr_month)
 Callback that happens when the thermostat server needs to check the current time (in minutes) and day (as day bitmap).
zb_bool_t tr_thermostat_server_next_schedule_cb (zb_uint16_t mins_until_schedule)
 Callback that happens when the thermostat server is about to schedule a ZBOSS alarm to run the next pending schedule.

Detailed Description



Function Documentation

◆ tr_thermostat_server_clear_weekly_schedule_cb()

zb_bool_t tr_thermostat_server_clear_weekly_schedule_cb ( zb_zcl_parsed_hdr_t * cmd_info,
zb_uint8_t endpoint )

Callback that user can declare to handle thermostat cluster clear weekly schedule command.

Parameters
cmd_infostruct that contains zcl header info
endpointdevice endpoint

◆ tr_thermostat_server_command_received_cb()

zb_bool_t tr_thermostat_server_command_received_cb ( zb_zcl_parsed_hdr_t * cmd_info)

Callback that user can declare to handle any Thermostat server commands.

Parameters
cmd_infostruct that contains zcl header info
Returns
ZB_FALSE to allow framework to continue processing the command

◆ tr_thermostat_server_get_relay_status_log_cb()

zb_bool_t tr_thermostat_server_get_relay_status_log_cb ( zb_zcl_parsed_hdr_t * cmd_info,
zb_uint8_t endpoint )

Callback that user can declare to handle thermostat cluster get relay status log command.

Parameters
cmd_infostruct that contains zcl header info
endpointdevice endpoint

◆ tr_thermostat_server_get_time_day_cb()

zb_bool_t tr_thermostat_server_get_time_day_cb ( zb_uint16_t * curr_time_in_mins,
zb_uint8_t * curr_day_of_the_week,
zb_uint8_t * curr_day,
zb_uint8_t * curr_month )

Callback that happens when the thermostat server needs to check the current time (in minutes) and day (as day bitmap).

Parameters
curr_time_in_minsapp is expected to set this to the current number of minutes since midnight
curr_day_of_the_weekapp is expected to set this to the current day using the day bitmap
curr_dayapp is expected to set this to the current date of the current day
curr_monthapp is expected to set this to the current month
Returns
ZB_TRUE if the app sets the curr_time_in_mins and curr_day
ZB_FALSE if the app did not set the curr_time_in_mins and curr_day

◆ tr_thermostat_server_get_weekly_schedule_cb()

zb_bool_t tr_thermostat_server_get_weekly_schedule_cb ( zb_zcl_parsed_hdr_t * cmd_info,
zb_uint8_t endpoint,
zb_uint8_t days_to_return,
zb_uint8_t mode_to_return )

Callback that user can declare to handle thermostat cluster get weekly schedule command.

Parameters
cmd_infostruct that contains zcl header info
endpointdevice endpoint
days_to_returnthis is a bitmap of which of days to return the set point values for. Can be any combination of single days or the entire week
mode_to_returnwhich setpoint to return: Heat Setpoint, Cool Setpoint, or Both

◆ tr_thermostat_server_init_cb()

void tr_thermostat_server_init_cb ( zb_uint8_t endpoint)

Callback fires when the Thermostat server cluster plugin is initialized.

Parameters
endpointdevice endpoint being initialized

◆ tr_thermostat_server_next_schedule_cb()

zb_bool_t tr_thermostat_server_next_schedule_cb ( zb_uint16_t mins_until_schedule)

Callback that happens when the thermostat server is about to schedule a ZBOSS alarm to run the next pending schedule.

Parameters
mins_until_schedulethe number of minutes until the next schedule is going to run. This is less than 7 days x 1440 minutes in a day
Returns
ZB_TRUE if the app handles the scheduling and then will call tr_thermostat_server_schedule_run
ZB_FALSE if the app wants the plugin to handle the next schedule

◆ tr_thermostat_server_set_weekly_schedule_cb()

zb_bool_t tr_thermostat_server_set_weekly_schedule_cb ( zb_zcl_parsed_hdr_t * cmd_info,
zb_uint8_t endpoint,
zb_uint8_t number_of_transitions_for_sequence,
zb_uint8_t day_of_week_for_sequence,
zb_uint8_t mode_for_sequence,
zb_uint8_t * payload )

Callback that user can declare to handle thermostat cluster set weekly schedule command.

Parameters
cmd_infostruct that contains zcl header info
endpointdevice endpoint
number_of_transitions_for_sequencehow many individual transitions to expect for this commands
day_of_week_for_sequencethe day of the week at which all the transitions within the payload of the command SHOULD be associated to
mode_for_sequenceif the Heat Setpoint is present and if the Cool Setpoint is present in each transition for this command
payloadlist of the transitions for this command, containing: Transition Time(2), Heat Setpoint(2/0), Cool Setpoint (2/0)

◆ tr_thermostat_server_setpoint_raise_lower_cb()

zb_bool_t tr_thermostat_server_setpoint_raise_lower_cb ( zb_zcl_parsed_hdr_t * cmd_info,
zb_uint8_t endpoint,
zb_uint8_t mode,
zb_int8_t amount )

Callback that user can declare to handle thermostat cluster setpoint raise lower command.

Parameters
cmd_infostruct that contains zcl header info
endpointdevice endpoint
modespecifies which set point is changed: heat(0), cool(1), or both(2)
amountsigned 8 bit value specifies the amount to change in 0.1 degrees Celsius

◆ tr_thermostat_server_write_attr_cb()

void tr_thermostat_server_write_attr_cb ( zb_uint8_t endpoint,
zb_uint16_t attr_id,
zb_uint8_t * new_value,
zb_uint16_t manuf_code )

Callback fires when an Thermostat server attribute is about to be written.

Parameters
endpointdevice endpoint
attr_idZCL attribute id
new_valuepointer to the new attribute value
manuf_codemanufacturer specific code