From 3f09e719e31319042b6f94455ade22e545cffc73 Mon Sep 17 00:00:00 2001 From: Val Date: Sun, 11 Dec 2022 23:14:46 -0600 Subject: [PATCH] mem_size in hex --- common/mem.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/common/mem.h b/common/mem.h index 8899e35..37d6343 100644 --- a/common/mem.h +++ b/common/mem.h @@ -4,7 +4,7 @@ #include void * mem; -const int mem_size = 65536; +const int mem_size = 0x10000; void mem_create() __attribute__ ((constructor)); void mem_destroy() __attribute__ ((destructor)); @@ -18,7 +18,7 @@ void mem_destroy() { } void * mem_get(short addr) { - return mem+(addr%mem_size); + return mem + (addr % mem_size); } #endif // __uC_MEM_H__