X-Git-Url: http://www.average.org/gitweb/?p=pulsecounter.git;a=blobdiff_plain;f=cc3200%2Fpersist.h;fp=cc3200%2Fpersist.h;h=d8e3ed4531edbeed4405b73fba61624723c00967;hp=0000000000000000000000000000000000000000;hb=8613fd8b02c85a60aa23d73ef80bc4f6ed96c3b5;hpb=36578682f3b34efaa08d1cad137558a6060cd200 diff --git a/cc3200/persist.h b/cc3200/persist.h new file mode 100644 index 0000000..d8e3ed4 --- /dev/null +++ b/cc3200/persist.h @@ -0,0 +1,19 @@ +#ifndef _PERSIST_H +#define _PERSIST_H + +#include +#include + +#define PAGE_SIZE 4096 + +struct persist { + uint32_t next:24; + uint32_t cold_status:1; + uint32_t hot_status:1; + uint32_t btn_status:1; + uint32_t base_count; + uint32_t timestamp; + uint32_t event[(PAGE_SIZE - offsetof(struct persist, event)) / sizeof(uint32_t)]; +}; + +#endif