Implement memory wear leveling algorithm
This commit is contained in:
@@ -1,15 +1,13 @@
|
||||
#ifndef MAD_CORE_COMMON_MEMORY_H
|
||||
#define MAD_CORE_COMMON_MEMORY_H
|
||||
|
||||
typedef struct mem_data_s mem_data_t;
|
||||
#define M_TEMPERATURE 0
|
||||
#define M_DEWPOINT 1
|
||||
|
||||
struct mem_data_s {
|
||||
byte sentinel; // Data marker bit
|
||||
word value[2]; // Values to be written
|
||||
};
|
||||
|
||||
int MEM_Read(mem_data_t *out);
|
||||
int MEM_Write(mem_data_t *in);
|
||||
void MEM_Init(void);
|
||||
void MEM_Write(word temp, word dewp);
|
||||
void MEM_Read(word *temp, word *dewp);
|
||||
void MEM_Free(void);
|
||||
void MEM_Dump(void);
|
||||
|
||||
#endif // MAD_CORE_COMMON_MEMORY_H
|
||||
|
||||
Reference in New Issue
Block a user