eCLD_AlarmsGetAlarmFromLog

teZCL_Status eCLD_AlarmsGetAlarmFromLog(
  tsZCL_EndPointDefinition *psEndPointDefinition,
  tsZCL_ClusterInstance *psClusterInstance,
  uint8 *pu8AlarmCode,
  uint16 *pu16ClusterId,
  uint32 *pu32TimeStamp);

Description

This function can be called on the Alarms cluster server to obtain an entry from the local Alarms table. Information on the logged alarm with the earliest timestamp in the device’s Alarms table is returned - pointers to memory locations to receive the retrieved alarm data must be provided. As a result of this command, the retrieved entry is also deleted from the table.

Parameters

  • psEndPointDefinition: Pointer to the ZCL endpoint definition structure for the application (see Section 6.1.1)

  • psClusterInstance: Pointer to structure containing information about the Alarms cluster instance (see Section 6.1.16)

  • pu8AlarmCode: Pointer to location to receive the alarm code which identifies the retrieved alarm type

  • pu16ClusterId: Pointer to location to receive the Cluster ID of the cluster which generated the alarm

  • pu32TimeStamp: Pointer to location to receive timestamp (UTC) of the retrieved alarm (a value of 0XFFFFFFFF indicates that no timestamp is available for the alarm)

Returns

  • E_ZCL_SUCCESS

  • E_ZCL_ERR_PARAMETER_NULL

  • E_ZCL_ERR_EP_RANGE

  • E_ZCL_ERR_EP_UNKNOWN

  • E_ZCL_ERR_CLUSTER_NOT_FOUND

  • E_ZCL_ERR_ZBUFFER_FAIL

  • E_ZCL_ERR_ZTRANSMIT_FAIL

If an error is returned by the ZigBee PRO stack function which is invoked by this function to transmit the data, this error may be obtained by calling eZCL_GetLastZpsError().

Parent topic:Functions