Initial Commit`

This commit is contained in:
2018-10-16 21:46:37 +01:00
commit 0359d4e0b2
10 changed files with 421 additions and 0 deletions

24
main.c Normal file
View File

@@ -0,0 +1,24 @@
#include <stdio.h>
#include "vm.h"
#include "string.h"
int main() {
VM* vm = new_vm();
uint8_t data[] = {
0x31, 0x05,
0x32, 0x02,
0x73, 0x12
};
memcpy(&vm->M, data, 6);
printf("%i\n", (uint8_t)0x101);
while(!vm->halted) {
vm_step(vm);
}
free_vm(vm);
return 0;
}