diff --git a/examples/matter/matter_controller_with_touchscreen/main/read_node_info.cpp b/examples/matter/matter_controller_with_touchscreen/main/read_node_info.cpp index 2ccda42..d47ce0f 100644 --- a/examples/matter/matter_controller_with_touchscreen/main/read_node_info.cpp +++ b/examples/matter/matter_controller_with_touchscreen/main/read_node_info.cpp @@ -526,7 +526,7 @@ static void parse_cb_response(cb_data* _data) ep_cluster* curr_cluster = node_ptr->get_cluster_ptr[_data->attr_path.mClusterId]; - cl_attribute* nattribute = new cl_attribute(_data->attr_path.mAttributeId,&esp_val); + cl_attribute* nattribute = new cl_attribute(_data->attr_path.mAttributeId,esp_val); curr_cluster->get_attribute_ptr[_data->attr_path.mAttributeId] = nattribute; diff --git a/examples/matter/matter_controller_with_touchscreen/main/read_node_info.h b/examples/matter/matter_controller_with_touchscreen/main/read_node_info.h index d3e1535..9e0d21c 100644 --- a/examples/matter/matter_controller_with_touchscreen/main/read_node_info.h +++ b/examples/matter/matter_controller_with_touchscreen/main/read_node_info.h @@ -23,10 +23,10 @@ typedef struct attributes esp_matter_attr_val_t esp_value; - attributes(uint32_t attributeid, esp_matter_attr_val_t* esp_val) + attributes(uint32_t attributeid, esp_matter_attr_val_t& esp_val) { this->attribute_id = attributeid; - this->esp_value = *esp_val; + this->esp_value = *(&esp_val); } }cl_attribute;