summaryrefslogtreecommitdiff
path: root/digital/zigbit/bitcloud/stack/Components/PersistDataServer/include/private/pdsCrcService.h
diff options
context:
space:
mode:
Diffstat (limited to 'digital/zigbit/bitcloud/stack/Components/PersistDataServer/include/private/pdsCrcService.h')
-rw-r--r--digital/zigbit/bitcloud/stack/Components/PersistDataServer/include/private/pdsCrcService.h73
1 files changed, 73 insertions, 0 deletions
diff --git a/digital/zigbit/bitcloud/stack/Components/PersistDataServer/include/private/pdsCrcService.h b/digital/zigbit/bitcloud/stack/Components/PersistDataServer/include/private/pdsCrcService.h
new file mode 100644
index 00000000..cf00f9f4
--- /dev/null
+++ b/digital/zigbit/bitcloud/stack/Components/PersistDataServer/include/private/pdsCrcService.h
@@ -0,0 +1,73 @@
+/***************************************************************************//**
+ \file pdsCrcService.h
+
+ \brief The header file describes the interface of crc counting
+
+ \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:
+ 22/01/08 A. Khromykh - Created
+ 01/11/10 A. Razinkov - Modified
+*****************************************************************************/
+
+#ifndef _PDSCRCSERVICE_H
+#define _PDSCRCSERVICE_H
+
+/******************************************************************************
+ Includes section
+******************************************************************************/
+#include <pdsDataServer.h>
+#include <pdsAuxService.h>
+
+#ifdef _COMMISSIONING_
+/******************************************************************************
+ Prototypes section
+******************************************************************************/
+/******************************************************************************
+\brief Calculate CRC of persistent data stored in persist memory
+\
+\param[out] crcStation - pointer to CRC service structure
+******************************************************************************/
+void pdsCalculateCrc(PDS_ServiceCrc_t *crcStation);
+
+/******************************************************************************
+\brief Read CRC of stored data from persist memory
+\
+\param[out] crcStation - pointer to CRC service structure
+******************************************************************************/
+void pdsReadCrc(PDS_ServiceCrc_t *crcStation);
+
+/******************************************************************************
+\brief Write CRC of stored data to persist memory. The ring buffer used
+\ to increase persist memory life cycle
+\
+\param[out] crcStation - pointer to CRC service structure
+******************************************************************************/
+PDS_DataServerState_t pdsWriteCrc(void);
+
+/******************************************************************************
+\brief Clears whole CRC area in persist memory
+\
+\return operation result
+******************************************************************************/
+PDS_DataServerState_t pdsClearCrcArea(void);
+
+/******************************************************************************
+\brief Check if any valid data exists in persist memory
+\
+\return operation result
+******************************************************************************/
+PDS_DataServerState_t pdsCheckPersistMemory(void);
+
+#ifdef __DBG_PDS__
+ void pdsDbgReadAllEeprom(void);
+#endif
+
+#endif /* _COMMISSIONING_ */
+#endif /*_PDSCRCSERVICE_H*/