![]() |
Energy Micro IEC60355 Library Example Project 1.0 (internal use only!) GCC-Version
Example project demonstrating POST and BIST library functions
|
00001 /***************************************************************************/ 00030 #ifndef __IEC60335_CLASS_B_FLASH_TEST_H__ 00031 #define __IEC60335_CLASS_B_FLASH_TEST_H__ 00032 00039 #include "iec60335_class_b_typedef.h" 00040 00041 #ifdef __cplusplus 00042 extern "C" { 00043 #endif 00044 00048 #define dynamic_CRC_table 0 00049 00053 #define SIZE32K 0x00007FFF 00054 #define SIZE64K 0x0000FFFF 00055 #define SIZE128K 0x0001FFFF 00056 00057 #define FLASHSIZE SIZE128K 00058 00059 #define FLASH_SIGN1 1 00060 #define FLASH_SIGN2 2 00061 00062 #define CRC_block_size 1024 00063 00064 #define FLASH_CRC_Done 1 00065 #define FLASH_CRC_InProg 2 00066 #define FLASH_CRC_Missing 3 00067 #define FLASH_CRC_Valid 4 00068 #define FLASH_CRC_Restart 5 00069 00079 /* predefined CRC32Val , MemLenght, NextAddress, BlockSize, Status; */ 00080 #define ENTRY_FLASH_CRC { 0x0A59B834, FLASHSIZE, (uint32_t) __STEXT, FLASHSIZE, FLASH_CRC_Valid } 00081 00095 uint32_t crc32(uint32_t crc,uint8_t ** const pp_src, uint32_t len); 00096 00104 testResult_t IEC60335_ClassB_FLASHtest_POST(void); 00105 00114 testResult_t IEC60335_ClassB_FLASHtest_BIST(uint8_t StartMode); 00115 00116 #ifdef __cplusplus 00117 } 00118 #endif /* __cplusplus */ 00119 00124 #endif /* __IEC60335_CLASS_B_FLASH_TEST_H__ */ 00125 00126 /************************************** EOF *********************************/