update spec to support normal io pins
[mTask.git] / client / mem.c
index f4cdf2c..42fb500 100644 (file)
@@ -1,6 +1,7 @@
 #include <stdlib.h>
 #include <stdint.h>
 
+#include "interface.h"
 #include "mem.h"
 
 uint8_t mem[MEMSIZE] = {0};
@@ -14,3 +15,11 @@ uint16_t mem_free(void)
 {
        return mem_sds-mem_task;
 }
+
+void mem_reset(void)
+{
+       mem_top = &mem[MEMSIZE-1];
+       mem_bottom = &mem[0];
+       mem_task = &mem[0];
+       mem_sds = &mem[MEMSIZE-1];
+}