summaryrefslogtreecommitdiff
path: root/digital/zigbit/bitcloud/stack/Components/ZCL/include/zclOtauDiscovery.h
diff options
context:
space:
mode:
Diffstat (limited to 'digital/zigbit/bitcloud/stack/Components/ZCL/include/zclOtauDiscovery.h')
-rw-r--r--digital/zigbit/bitcloud/stack/Components/ZCL/include/zclOtauDiscovery.h100
1 files changed, 100 insertions, 0 deletions
diff --git a/digital/zigbit/bitcloud/stack/Components/ZCL/include/zclOtauDiscovery.h b/digital/zigbit/bitcloud/stack/Components/ZCL/include/zclOtauDiscovery.h
new file mode 100644
index 00000000..54365690
--- /dev/null
+++ b/digital/zigbit/bitcloud/stack/Components/ZCL/include/zclOtauDiscovery.h
@@ -0,0 +1,100 @@
+/**************************************************************************//**
+ \file zclOTAUCluster.h
+
+ \brief Declaration of the private OTAU interface
+
+ \author
+ Atmel Corporation: http://www.atmel.com \n
+ Support email: avr@atmel.com
+
+ Copyright (c) 2008-2011, Atmel Corporation. All rights reserved.
+ Licensed under Atmel's Limited License Agreement (BitCloudTM).
+
+ \internal
+ History:
+ 13.05.10 A. Khromykh - Created.
+*******************************************************************************/
+#ifndef _ZCLOTAUDISCOVERY_H
+#define _ZCLOTAUDISCOVERY_H
+
+/******************************************************************************
+ Includes section
+******************************************************************************/
+#include <zcl.h>
+#include <clusters.h>
+#include <zdo.h>
+
+/******************************************************************************
+ Types section
+******************************************************************************/
+typedef union
+{
+ ZDO_ZdpReq_t zdpOtauReq;
+#ifdef _ZCL_SECURITY_
+ APS_RequestKeyReq_t apsKeyReq;
+#endif // _ZCL_SECURITY_
+ ZCL_Request_t zclCommandReq;
+} OtauReqMemory_t;
+
+typedef union
+{
+ ZCL_OtauQueryNextImageReq_t uQueryNextImageReq;
+ ZCL_OtauImageBlockReq_t uImageBlockReq;
+ ZCL_OtauImagePageReq_t uImagePageReq;
+ ZCL_OtauUpgradeEndReq_t uUpgradeEndReq;
+} OtauZclReqMemory_t;
+
+typedef struct
+{
+ uint32_t imageInternalLength;
+ uint8_t internalAddressStatus;
+ uint32_t currentFileOffset;
+ uint8_t currentDataSize;
+ uint32_t imageRemainder;
+ uint32_t imagePageOffset;
+} OtauImageAuxVar_t;
+
+/***************************************************************************//**
+ \brief
+ ZCL OTAU Cluster parametres.
+*******************************************************************************/
+typedef struct
+{
+ uint32_t imageSize;
+ uint8_t imageBlockData[OFD_BLOCK_SIZE];
+ uint8_t *imagePageData;
+
+} ZclOtauClientImageBuffer_t;
+
+/******************************************************************************
+ Prototypes section
+******************************************************************************/
+/***************************************************************************//**
+\brief Restart poll timer
+
+\param[in] period - timer fired time
+\param[in] cb - pointer to fired method
+******************************************************************************/
+void otauStartGenericTimer(uint32_t period, void (* cb)(void));
+
+/***************************************************************************//**
+\brief Restart discovery service with context gap
+******************************************************************************/
+void otauStartPollDiscovery(void);
+
+/***************************************************************************//**
+\brief Entry point to client process
+******************************************************************************/
+void otauClientEntryPoint(void);
+
+/***************************************************************************//**
+\brief Start discovery of upgrade server
+******************************************************************************/
+void ZCL_OtauUpgradeServerDiscovery(void);
+
+/***************************************************************************//**
+\brief Server IEEE addresses request
+******************************************************************************/
+void otauServerExtAddrReq(void);
+
+#endif /* _ZCLOTAUDISCOVERY_H */