From f86d973b2f5318b5e761e2f682c2aa57d61eb0d6 Mon Sep 17 00:00:00 2001 From: alekseiplusplus Date: Thu, 27 Apr 2023 11:19:33 +1000 Subject: Major progress on interpreter --- headers/apple.h | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'headers/apple.h') diff --git a/headers/apple.h b/headers/apple.h index f5cac5c..cfcc879 100644 --- a/headers/apple.h +++ b/headers/apple.h @@ -1,6 +1,11 @@ #define MEMORY_SIZE 4096 void AppleOn(){ - //Memory = malloc(MEMORY_SIZE); + Memory = calloc(MEMORY_SIZE, sizeof(byte)); initInstructionTable(); +} + +void AppleReset(){ //Firt few Zp addresses have gibberish, need to fix + free(Memory); + Memory = calloc(MEMORY_SIZE, sizeof(byte)); } \ No newline at end of file -- cgit v1.2.3