X-Git-Url: https://git.martlubbers.net/?a=blobdiff_plain;f=client%2Fmem.c;fp=client%2Fmem.c;h=f4cdf2cebe1fcd881fed6afa6780aa7f9ee3d9fb;hb=cc93aff1c0867a33c41b4120c001b407d1b8850a;hp=38bd6bd0198ced76b665ca4bd04a699c98ff8312;hpb=09b207a39b7791098daafd7d87c3ad9d3db3e19f;p=mTask.git diff --git a/client/mem.c b/client/mem.c index 38bd6bd..f4cdf2c 100644 --- a/client/mem.c +++ b/client/mem.c @@ -1,3 +1,16 @@ #include +#include -struct task *task_head = NULL; +#include "mem.h" + +uint8_t mem[MEMSIZE] = {0}; + +uint8_t *mem_top = &mem[MEMSIZE-1]; +uint8_t *mem_bottom = &mem[0]; +uint8_t *mem_task = &mem[0]; +uint8_t *mem_sds = &mem[MEMSIZE-1]; + +uint16_t mem_free(void) +{ + return mem_sds-mem_task; +}