diff svp_util.c @ 1621:ca158bc091f9

Implement program ROM reads
author Michael Pavone <pavone@retrodev.com>
date Sat, 06 Oct 2018 17:33:15 -0700
parents a172f97d873f
children
line wrap: on
line diff
--- a/svp_util.c	Thu Oct 04 19:12:56 2018 -0700
+++ b/svp_util.c	Sat Oct 06 17:33:15 2018 -0700
@@ -1,5 +1,6 @@
 
-void svp_read_16(svp_context *context)
+void svp_prog_read_16(svp_context *context)
 {
-	context->internal[0] = 0;
+	uint16_t address = context->scratch1 >> 1;
+	context->scratch1 = context->rom[address];
 }