2 * Copyright (c) 2016 Samsung Electronics Co., Ltd. All rights reserved.
4 * Contact: Suresh Kumar N (suresh.n@samsung.com)
6 * Licensed under the Apache License, Version 2.0 (the "License");
7 * you may not use this file except in compliance with the License.
8 * You may obtain a copy of the License at
10 * http://www.apache.org/licenses/LICENSE-2.0
12 * Unless required by applicable law or agreed to in writing, software
13 * distributed under the License is distributed on an "AS IS" BASIS,
14 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15 * See the License for the specific language governing permissions and
16 * limitations under the License.
19 #include "zigbee_service_interface_common.h"
21 #include <zblib_driver_zcl_group.h>
24 static void *_service_interface_ref_zigbee_zcl_group(ZigBeeServiceInterface *service_interface)
26 ZigbeeObjectSkeleton *zigbee_object = NULL;
27 ZigbeeCustomData_t *custom_data = NULL;
28 ZigbeeZcl_group *group_object = NULL;
30 custom_data = (ZigbeeCustomData_t *)zblib_service_interface_ref_user_data(service_interface);
31 if (NULL == custom_data) {
32 Z_LOGE("D-BUS service interface custom_data is NULL!");
36 /* Get zigbee object */
37 zigbee_object = g_hash_table_lookup(custom_data->objects, ZIGBEE_SERVICE_PATH);
38 if (NULL == zigbee_object) {
39 Z_LOGW("Cannot find ZigBee D-BUS interface object!");
43 group_object = zigbee_object_get_zcl_group(ZIGBEE_OBJECT(zigbee_object));
47 static void on_zcl_group_add_group_resp(ZigBeeServiceInterface *service_interface,
48 guint request_id, gpointer resp_data, guint resp_data_len, gpointer resp_cb_data)
50 ZigbeeServiceInterfaceRespCbData_t *cb_data =
51 (ZigbeeServiceInterfaceRespCbData_t *)resp_cb_data;
53 ZigbeeZcl_group *group_object = NULL;
54 GDBusMethodInvocation *invocation = NULL;
56 ZigbeeGeneralResp_t *payload = (ZigbeeGeneralResp_t *)resp_data;
58 NOT_USED(service_interface);
61 if (NULL == resp_data || 0 == resp_data_len) {
62 Z_LOGE("resp_data=%p or resp_data_len=%d is null", resp_data, resp_data_len);
67 group_object = zigbee_service_dbus_interface_ref_interface_object(cb_data);
68 zblib_check_null_free_and_ret("group_object", group_object, cb_data);
70 invocation = zigbee_service_dbus_interface_ref_invocation(cb_data);
71 zblib_check_null_free_and_ret("invocation", invocation, cb_data);
73 zigbee_zcl_group_complete_add_group(group_object, invocation, payload->result);
78 static gboolean on_zcl_group_add_group(ZigbeeZcl_group *zcl_group_object,
79 GDBusMethodInvocation *invocation,
86 ZigBeeServiceInterface *service_interface = (ZigBeeServiceInterface *)user_data;
87 ZigbeeZclGroupAddGroup_t req;
88 ZigbeeServiceInterfaceRespCbData_t *resp_cb_data = NULL;
90 GVariantIter *iter = NULL;
95 memset(&req, 0x0, sizeof(ZigbeeZclGroupAddGroup_t));
97 /* Update request structure */
98 req.node_id = node_id;
99 req.dest_ep = dest_ep;
100 req.group_id = group_id;
103 g_variant_get(group_name, "a(y)", &iter);
104 while (g_variant_iter_loop(iter, "(y)", &req.group_name[i])) {
106 if (i >= ZIGBEE_ZCL_GROUP_NAME_MAX_LEN + 1)
110 /* Allocate response callback data */
112 zigbee_service_dbus_interface_create_resp_cb_data(zcl_group_object,
113 invocation, NULL, 0);
114 if (NULL == resp_cb_data) {
115 Z_LOGE("zigbee_service_dbus_interface_create_resp_cb_data failed!");
117 /* Send failure response */
118 ZIGBEE_DBUS_FAIL_RESPONSE(invocation, ZIGBEE_DBUS_DEFAULT_REQ_FAILED_MSG);
123 /* Dispatch request */
124 ret = zigbee_service_dbus_interface_dispatch_request(service_interface,
125 ZBLIB_DRIVER_TYPE_ZCL_GROUP,
126 ZBLIB_ZCL_GROUP_OPS_ADD_GROUP,
128 on_zcl_group_add_group_resp, resp_cb_data);
130 Z_LOGE("zigbee_service_dbus_interface_dispatch_request failed!");
132 /* Free response callback data */
133 zigbee_service_dbus_interface_destroy_resp_cb_data(resp_cb_data);
135 /* Send failure response */
136 ZIGBEE_DBUS_FAIL_RESPONSE(invocation, ZIGBEE_DBUS_DEFAULT_REQ_FAILED_MSG);
144 static void on_zcl_group_view_group_resp(ZigBeeServiceInterface *service_interface,
145 guint request_id, gpointer resp_data, guint resp_data_len, gpointer resp_cb_data)
147 ZigbeeServiceInterfaceRespCbData_t *cb_data =
148 (ZigbeeServiceInterfaceRespCbData_t *)resp_cb_data;
150 ZigbeeZcl_group *group_object = NULL;
151 GDBusMethodInvocation *invocation = NULL;
153 ZigbeeGeneralResp_t *payload = (ZigbeeGeneralResp_t *)resp_data;
155 NOT_USED(service_interface);
156 NOT_USED(request_id);
158 if (NULL == resp_data || 0 == resp_data_len) {
159 Z_LOGE("resp_data=%p or resp_data_len=%d is null", resp_data, resp_data_len);
164 group_object = zigbee_service_dbus_interface_ref_interface_object(cb_data);
165 zblib_check_null_free_and_ret("group_object", group_object, cb_data);
167 invocation = zigbee_service_dbus_interface_ref_invocation(cb_data);
168 zblib_check_null_free_and_ret("invocation", invocation, cb_data);
170 zigbee_zcl_group_complete_view_group(group_object, invocation, payload->result);
175 static gboolean on_zcl_group_view_group(ZigbeeZcl_group *zcl_group_object,
176 GDBusMethodInvocation *invocation,
182 ZigBeeServiceInterface *service_interface = (ZigBeeServiceInterface *)user_data;
183 ZigbeeZclGroupViewGroup_t req;
184 ZigbeeServiceInterfaceRespCbData_t *resp_cb_data = NULL;
188 memset(&req, 0x0, sizeof(ZigbeeZclGroupViewGroup_t));
190 /* Update request structure */
191 req.node_id = node_id;
192 req.dest_ep = dest_ep;
193 req.group_id = group_id;
195 /* Allocate response callback data */
197 zigbee_service_dbus_interface_create_resp_cb_data(zcl_group_object,
198 invocation, NULL, 0);
199 if (NULL == resp_cb_data) {
200 Z_LOGE("zigbee_service_dbus_interface_create_resp_cb_data failed!");
202 /* Send failure response */
203 ZIGBEE_DBUS_FAIL_RESPONSE(invocation, ZIGBEE_DBUS_DEFAULT_REQ_FAILED_MSG);
208 /* Dispatch request */
209 ret = zigbee_service_dbus_interface_dispatch_request(service_interface,
210 ZBLIB_DRIVER_TYPE_ZCL_GROUP,
211 ZBLIB_ZCL_GROUP_OPS_VIEW_GROUP,
213 on_zcl_group_view_group_resp, resp_cb_data);
215 Z_LOGE("zigbee_service_dbus_interface_dispatch_request failed!");
217 /* Free response callback data */
218 zigbee_service_dbus_interface_destroy_resp_cb_data(resp_cb_data);
220 /* Send failure response */
221 ZIGBEE_DBUS_FAIL_RESPONSE(invocation, ZIGBEE_DBUS_DEFAULT_REQ_FAILED_MSG);
229 static void on_zcl_group_get_group_membership_resp(ZigBeeServiceInterface *service_interface,
230 guint request_id, gpointer resp_data, guint resp_data_len, gpointer resp_cb_data)
232 ZigbeeServiceInterfaceRespCbData_t *cb_data =
233 (ZigbeeServiceInterfaceRespCbData_t *)resp_cb_data;
235 ZigbeeZcl_group *group_object = NULL;
236 GDBusMethodInvocation *invocation = NULL;
238 ZigbeeGeneralResp_t *payload = (ZigbeeGeneralResp_t *)resp_data;
240 NOT_USED(service_interface);
241 NOT_USED(request_id);
243 if (NULL == resp_data || 0 == resp_data_len) {
244 Z_LOGE("resp_data=%p or resp_data_len=%d is null", resp_data, resp_data_len);
249 group_object = zigbee_service_dbus_interface_ref_interface_object(cb_data);
250 zblib_check_null_free_and_ret("group_object", group_object, cb_data);
252 invocation = zigbee_service_dbus_interface_ref_invocation(cb_data);
253 zblib_check_null_free_and_ret("invocation", invocation, cb_data);
255 zigbee_zcl_group_complete_get_group_membership(group_object, invocation, payload->result);
260 static gboolean on_zcl_group_get_group_membership(ZigbeeZcl_group *zcl_group_object,
261 GDBusMethodInvocation *invocation,
265 GVariant *group_list,
268 ZigBeeServiceInterface *service_interface = (ZigBeeServiceInterface *)user_data;
269 ZigbeeZclGroupGetGroupMembership_t req;
270 ZigbeeServiceInterfaceRespCbData_t *resp_cb_data = NULL;
272 GVariantIter *iter = NULL;
278 memset(&req, 0x0, sizeof(ZigbeeZclGroupGetGroupMembership_t));
280 /* Update request structure */
281 req.node_id = node_id;
282 req.dest_ep = dest_ep;
283 req.group_count = group_count;
284 req.group_list = g_malloc0(sizeof(gushort) * group_count);
285 g_variant_get(group_list, "aq", &iter);
286 while (i < group_count && g_variant_iter_loop(iter, "q", &value)) {
287 Z_LOGD(" cluster: [%d]", value);
288 req.group_list[i] = value;
292 /* Allocate response callback data */
294 zigbee_service_dbus_interface_create_resp_cb_data(zcl_group_object,
295 invocation, NULL, 0);
296 if (NULL == resp_cb_data) {
297 Z_LOGE("zigbee_service_dbus_interface_create_resp_cb_data failed!");
299 g_free(req.group_list);
301 /* Send failure response */
302 ZIGBEE_DBUS_FAIL_RESPONSE(invocation, ZIGBEE_DBUS_DEFAULT_REQ_FAILED_MSG);
307 /* Dispatch request */
308 ret = zigbee_service_dbus_interface_dispatch_request(service_interface,
309 ZBLIB_DRIVER_TYPE_ZCL_GROUP,
310 ZBLIB_ZCL_GROUP_OPS_GET_GROUP_MEMBERSHIP,
312 on_zcl_group_get_group_membership_resp, resp_cb_data);
315 g_free(req.group_list);
318 Z_LOGE("zigbee_service_dbus_interface_dispatch_request failed!");
320 /* Free response callback data */
321 zigbee_service_dbus_interface_destroy_resp_cb_data(resp_cb_data);
323 /* Send failure response */
324 ZIGBEE_DBUS_FAIL_RESPONSE(invocation, ZIGBEE_DBUS_DEFAULT_REQ_FAILED_MSG);
332 static void on_zcl_group_remove_group_resp(ZigBeeServiceInterface *service_interface,
333 guint request_id, gpointer resp_data, guint resp_data_len, gpointer resp_cb_data)
335 ZigbeeServiceInterfaceRespCbData_t *cb_data =
336 (ZigbeeServiceInterfaceRespCbData_t *)resp_cb_data;
338 ZigbeeZcl_group *group_object = NULL;
339 GDBusMethodInvocation *invocation = NULL;
341 ZigbeeGeneralResp_t *payload = (ZigbeeGeneralResp_t *)resp_data;
343 NOT_USED(service_interface);
344 NOT_USED(request_id);
346 if (NULL == resp_data || 0 == resp_data_len) {
347 Z_LOGE("resp_data=%p or resp_data_len=%d is null", resp_data, resp_data_len);
352 group_object = zigbee_service_dbus_interface_ref_interface_object(cb_data);
353 zblib_check_null_free_and_ret("group_object", group_object, cb_data);
355 invocation = zigbee_service_dbus_interface_ref_invocation(cb_data);
356 zblib_check_null_free_and_ret("invocation", invocation, cb_data);
358 zigbee_zcl_group_complete_remove_group(group_object, invocation, payload->result);
363 static gboolean on_zcl_group_remove_group(ZigbeeZcl_group *zcl_group_object,
364 GDBusMethodInvocation *invocation,
370 ZigBeeServiceInterface *service_interface = (ZigBeeServiceInterface *)user_data;
371 ZigbeeZclGroupRemoveGroup_t req;
372 ZigbeeServiceInterfaceRespCbData_t *resp_cb_data = NULL;
376 memset(&req, 0x0, sizeof(ZigbeeZclGroupRemoveGroup_t));
378 /* Update request structure */
379 req.node_id = node_id;
380 req.dest_ep = dest_ep;
381 req.group_id = group_id;
383 /* Allocate response callback data */
385 zigbee_service_dbus_interface_create_resp_cb_data(zcl_group_object,
386 invocation, NULL, 0);
387 if (NULL == resp_cb_data) {
388 Z_LOGE("zigbee_service_dbus_interface_create_resp_cb_data failed!");
390 /* Send failure response */
391 ZIGBEE_DBUS_FAIL_RESPONSE(invocation, ZIGBEE_DBUS_DEFAULT_REQ_FAILED_MSG);
396 /* Dispatch request */
397 ret = zigbee_service_dbus_interface_dispatch_request(service_interface,
398 ZBLIB_DRIVER_TYPE_ZCL_GROUP,
399 ZBLIB_ZCL_GROUP_OPS_REMOVE_GROUP,
401 on_zcl_group_remove_group_resp, resp_cb_data);
403 Z_LOGE("zigbee_service_dbus_interface_dispatch_request failed!");
405 /* Free response callback data */
406 zigbee_service_dbus_interface_destroy_resp_cb_data(resp_cb_data);
408 /* Send failure response */
409 ZIGBEE_DBUS_FAIL_RESPONSE(invocation, ZIGBEE_DBUS_DEFAULT_REQ_FAILED_MSG);
417 static void on_zcl_group_remove_all_group_resp(ZigBeeServiceInterface *service_interface,
418 guint request_id, gpointer resp_data, guint resp_data_len, gpointer resp_cb_data)
420 ZigbeeServiceInterfaceRespCbData_t *cb_data =
421 (ZigbeeServiceInterfaceRespCbData_t *)resp_cb_data;
423 ZigbeeZcl_group *group_object = NULL;
424 GDBusMethodInvocation *invocation = NULL;
426 ZigbeeGeneralResp_t *payload = (ZigbeeGeneralResp_t *)resp_data;
428 NOT_USED(service_interface);
429 NOT_USED(request_id);
431 if (NULL == resp_data || 0 == resp_data_len) {
432 Z_LOGE("resp_data=%p or resp_data_len=%d is null", resp_data, resp_data_len);
437 group_object = zigbee_service_dbus_interface_ref_interface_object(cb_data);
438 zblib_check_null_free_and_ret("group_object", group_object, cb_data);
440 invocation = zigbee_service_dbus_interface_ref_invocation(cb_data);
441 zblib_check_null_free_and_ret("invocation", invocation, cb_data);
443 zigbee_zcl_group_complete_remove_all_group(group_object, invocation, payload->result);
448 static gboolean on_zcl_group_remove_all_group(ZigbeeZcl_group *zcl_group_object,
449 GDBusMethodInvocation *invocation,
454 ZigBeeServiceInterface *service_interface = (ZigBeeServiceInterface *)user_data;
455 ZigbeeZclGroupRemoveAllGroup_t req;
456 ZigbeeServiceInterfaceRespCbData_t *resp_cb_data = NULL;
460 memset(&req, 0x0, sizeof(ZigbeeZclGroupRemoveAllGroup_t));
462 /* Update request structure */
463 req.node_id = node_id;
464 req.dest_ep = dest_ep;
466 /* Allocate response callback data */
468 zigbee_service_dbus_interface_create_resp_cb_data(zcl_group_object,
469 invocation, NULL, 0);
470 if (NULL == resp_cb_data) {
471 Z_LOGE("zigbee_service_dbus_interface_create_resp_cb_data failed!");
473 /* Send failure response */
474 ZIGBEE_DBUS_FAIL_RESPONSE(invocation, ZIGBEE_DBUS_DEFAULT_REQ_FAILED_MSG);
479 /* Dispatch request */
480 ret = zigbee_service_dbus_interface_dispatch_request(service_interface,
481 ZBLIB_DRIVER_TYPE_ZCL_GROUP,
482 ZBLIB_ZCL_GROUP_OPS_REMOVE_ALL_GROUP,
484 on_zcl_group_remove_all_group_resp, resp_cb_data);
486 Z_LOGE("zigbee_service_dbus_interface_dispatch_request failed!");
488 /* Free response callback data */
489 zigbee_service_dbus_interface_destroy_resp_cb_data(resp_cb_data);
491 /* Send failure response */
492 ZIGBEE_DBUS_FAIL_RESPONSE(invocation, ZIGBEE_DBUS_DEFAULT_REQ_FAILED_MSG);
500 static void on_zcl_group_add_group_if_identifying_resp(ZigBeeServiceInterface *service_interface,
501 guint request_id, gpointer resp_data, guint resp_data_len, gpointer resp_cb_data)
503 ZigbeeServiceInterfaceRespCbData_t *cb_data =
504 (ZigbeeServiceInterfaceRespCbData_t *)resp_cb_data;
506 ZigbeeZcl_group *group_object = NULL;
507 GDBusMethodInvocation *invocation = NULL;
509 ZigbeeGeneralResp_t *payload = (ZigbeeGeneralResp_t *)resp_data;
511 NOT_USED(service_interface);
512 NOT_USED(request_id);
514 if (NULL == resp_data || 0 == resp_data_len) {
515 Z_LOGE("resp_data=%p or resp_data_len=%d is null", resp_data, resp_data_len);
520 group_object = zigbee_service_dbus_interface_ref_interface_object(cb_data);
521 zblib_check_null_free_and_ret("group_object", group_object, cb_data);
523 invocation = zigbee_service_dbus_interface_ref_invocation(cb_data);
524 zblib_check_null_free_and_ret("invocation", invocation, cb_data);
526 zigbee_zcl_group_complete_add_group_if_identifying(group_object, invocation, payload->result);
531 static gboolean on_zcl_group_add_group_if_identifying(ZigbeeZcl_group *zcl_group_object,
532 GDBusMethodInvocation *invocation,
536 GVariant *group_name,
539 ZigBeeServiceInterface *service_interface = (ZigBeeServiceInterface *)user_data;
540 ZigbeeZclGroupAddGroupIfIdentifying_t req;
541 ZigbeeServiceInterfaceRespCbData_t *resp_cb_data = NULL;
543 GVariantIter *iter = NULL;
548 memset(&req, 0x0, sizeof(ZigbeeZclGroupAddGroupIfIdentifying_t));
550 /* Update request structure */
551 req.node_id = node_id;
552 req.dest_ep = dest_ep;
553 req.group_id = group_id;
554 g_variant_get(group_name, "a(y)", &iter);
555 while (g_variant_iter_loop(iter, "(y)", &req.group_name[i])) {
557 if (i >= ZIGBEE_ZCL_GROUP_NAME_MAX_LEN + 1)
561 /* Allocate response callback data */
563 zigbee_service_dbus_interface_create_resp_cb_data(zcl_group_object,
564 invocation, NULL, 0);
565 if (NULL == resp_cb_data) {
566 Z_LOGE("zigbee_service_dbus_interface_create_resp_cb_data failed!");
568 /* Send failure response */
569 ZIGBEE_DBUS_FAIL_RESPONSE(invocation, ZIGBEE_DBUS_DEFAULT_REQ_FAILED_MSG);
574 /* Dispatch request */
575 ret = zigbee_service_dbus_interface_dispatch_request(service_interface,
576 ZBLIB_DRIVER_TYPE_ZCL_GROUP,
577 ZBLIB_ZCL_GROUP_OPS_ADD_GROUP_IF_IDENTIFYING,
579 on_zcl_group_add_group_if_identifying_resp, resp_cb_data);
581 Z_LOGE("zigbee_service_dbus_interface_dispatch_request failed!");
583 /* Free response callback data */
584 zigbee_service_dbus_interface_destroy_resp_cb_data(resp_cb_data);
586 /* Send failure response */
587 ZIGBEE_DBUS_FAIL_RESPONSE(invocation, ZIGBEE_DBUS_DEFAULT_REQ_FAILED_MSG);
595 void zigbee_service_dbus_interface_zcl_group_notification(ZigBeeServiceInterface *service_interface,
596 guint noti_id, gpointer noti_data, guint noti_data_len, gpointer noti_cb_data)
598 ZigbeeZcl_group *group_object;
600 zblib_check_null_ret("service_interface", service_interface);
602 if (NULL == noti_data || 0 == noti_data_len) {
603 Z_LOGE("noti_data=%p or noti_data_len=%d is null", noti_data, noti_data_len);
607 group_object = _service_interface_ref_zigbee_zcl_group(service_interface);
608 zblib_check_null_ret("group_object", group_object);
610 NOT_USED(noti_cb_data);
613 case ZBLIB_SERVICE_NOTI_ADD_GROUP_RSP: {
614 ZigbeeZclGroupAddGroupNoti_t *rsp =
615 (ZigbeeZclGroupAddGroupNoti_t*)noti_data;
617 Z_LOGD("add_group_rsp from : [0x%X]", rsp->node_id);
619 zigbee_zcl_group_emit_add_group_rsp(group_object, rsp->node_id, rsp->src_ep,
620 rsp->status, rsp->group_id);
623 case ZBLIB_SERVICE_NOTI_VIEW_GROUP_RSP: {
624 ZigbeeZclGroupViewGroupNoti_t *rsp =
625 (ZigbeeZclGroupViewGroupNoti_t*)noti_data;
627 Z_LOGD("view_group_rsp from : [0x%X]", rsp->node_id);
629 zigbee_zcl_group_emit_view_group_rsp(group_object, rsp->node_id, rsp->src_ep,
630 rsp->status, rsp->group_id, rsp->group_name);
633 case ZBLIB_SERVICE_NOTI_GET_GROUP_MEMBERSHIP_RSP: {
635 GVariant* group_list = NULL;
636 GVariantBuilder *attr_builder = NULL;
638 ZigbeeZclGroupGetGroupMembershipNoti_t *rsp =
639 (ZigbeeZclGroupGetGroupMembershipNoti_t*)noti_data;
641 Z_LOGD("get_group_membership_rsp from : [0x%X]", rsp->node_id);
643 attr_builder = g_variant_builder_new(G_VARIANT_TYPE("aq"));
645 for (i = 0; i < rsp->group_count; i++)
646 g_variant_builder_add(attr_builder, "q", rsp->group_list[i]);
647 group_list = g_variant_builder_end(attr_builder);
648 g_variant_builder_unref(attr_builder);
650 zigbee_zcl_group_emit_get_group_membership_rsp(group_object, rsp->node_id,
651 rsp->src_ep, rsp->capacity, rsp->group_count, group_list);
654 case ZBLIB_SERVICE_NOTI_REMOVE_GROUP_RSP: {
655 ZigbeeZclGroupRemoveGroupNoti_t *rsp =
656 (ZigbeeZclGroupRemoveGroupNoti_t*)noti_data;
658 Z_LOGD("remove_group_rsp from : [0x%X]", rsp->node_id);
660 zigbee_zcl_group_emit_remove_group_rsp(group_object, rsp->node_id, rsp->src_ep,
661 rsp->status, rsp->group_id);
665 Z_LOGE("Unexpected notification [%x]", noti_id);
669 /* ZigbeeZcl_group should be dereferenced */
670 g_object_unref(group_object);
674 gboolean zigbee_service_dbus_interface_zcl_group_init(ZigBeeServiceInterface *service_interface,
675 ZigbeeObjectSkeleton *zigbee_object)
677 ZigbeeZcl_group *zcl_group_object;
679 if (NULL == service_interface) {
680 /* LCOV_EXCL_START */
681 Z_LOGE("service_interface is NULL");
686 zcl_group_object = zigbee_zcl_group_skeleton_new();
687 zigbee_object_skeleton_set_zcl_group(zigbee_object, zcl_group_object);
688 g_object_unref(zcl_group_object);
690 Z_LOGI("zcl_group_object: [%p]", zcl_group_object);
693 * Register signal handlers for 'zcl_group' interface
695 g_signal_connect(zcl_group_object,
697 G_CALLBACK(on_zcl_group_add_group), service_interface);
699 g_signal_connect(zcl_group_object,
701 G_CALLBACK(on_zcl_group_view_group), service_interface);
703 g_signal_connect(zcl_group_object,
704 "handle-get-group-membership",
705 G_CALLBACK(on_zcl_group_get_group_membership), service_interface);
707 g_signal_connect(zcl_group_object,
708 "handle-remove-group",
709 G_CALLBACK(on_zcl_group_remove_group), service_interface);
711 g_signal_connect(zcl_group_object,
712 "handle-remove-all-group",
713 G_CALLBACK(on_zcl_group_remove_all_group), service_interface);
715 g_signal_connect(zcl_group_object,
716 "handle-add-group-if-identifying",
717 G_CALLBACK(on_zcl_group_add_group_if_identifying), service_interface);