eOTA_Create
teZCL_Status eOTA_Create(
tsZCL_ClusterInstance *psClusterInstance,
bool_t bIsServer,
tsZCL_ClusterDefinition *psClusterDefinition,
void *pvEndPointSharedStructPtr,
uint8 u8Endpoint,
uint8 *pu8AttributeControlBits,
tsOTA_Common *psCustomDataStruct);
Description
This function creates an instance of the OTA Upgrade cluster on the specified endpoint. The cluster instance can act as a server or a client, as specified. The shared structure of the device associated with cluster must also be specified.
The function must be the first OTA function called in the application, and must be called after the stack has been started and after the ZCL has been initialized.
Parameters
psClusterInstance: Pointer to structure containing information about the cluster instance to be created (see Section 6.1.16)
bIsServer: Side of cluster to be implemented on this device:
TRUE - Server
FALSE - Client
psClusterDefinition: Pointer to structure indicating the type of cluster (see Section 6.1.2) - this structure must contain the details of the OTA Upgrade cluster
pvEndPointSharedStructPtr: Pointer to shared device structure for relevant endpoint (depends on device type, e.g. Door Lock)
u8Endpoint: Number of endpoint with which cluster will be associated
pu8AttributeControlBits: Pointer to an array of bitmaps, one for each attribute in the relevant cluster - for internal cluster definition use only, array should be initialised to 0
tpsCustomDataStruct: Pointer to structure containing custom data for OTA Upgrade cluster (see Section 49.11.2)
Returns
E_ZCL_SUCCESS
E_ZCL_FAIL
Parent topic:General Functions