ZCL_ReadAttributeValue Function
C
ZCL_Status_t ZCL_ReadAttributeValue(Endpoint_t endpointId, ClusterId_t clusterId,uint8_t clusterSide,
ZCL_AttributeId_t attrId, uint8_t *attrType, uint8_t *attrValue);
Description
Finds an attribute in ZCL and returns its valu
The function may be used to obtain only local attributes. To access an attribute on a remote device, send a read attributes general cluster command via the ZCL_AttributeReq() function.
Parameters
Param | Description |
---|---|
endpointId | endpoint on which cluster is registered |
clusterId | cluster unique identifier |
clusterSide | detects the cluster's side (client or server) |
attrId | attribute unique identifier |
attrType | pointer to attribute type determined and returned |
attrValue | read out attribute value pointer Caller is responsible for providing big enough attrValue buffer. |
Returns
The status of the operation: ::ZCL_SUCCESS_STATUS (0x00) - attribute value has been obtained successfully
::ZCL_UNSUPPORTED_ATTRIBUTE_STATUS (0x86) - the specified attribute is not supported