diff sms.c @ 1379:65f1d6558e9e

Update SMS code for changes supporting slow rise time emulation in IO code
author Michael Pavone <pavone@retrodev.com>
date Mon, 29 May 2017 18:25:11 -0700
parents e587f16e7d3d
children 1df16f5985f3
line wrap: on
line diff
--- a/sms.c	Mon May 29 17:30:40 2017 -0700
+++ b/sms.c	Mon May 29 18:25:11 2017 -0700
@@ -13,9 +13,9 @@
 	sms_context *sms = z80->system;
 	if (location & 1) {
 		uint8_t fuzzy_ctrl_0 = sms->io.ports[0].control, fuzzy_ctrl_1 = sms->io.ports[1].control;
-		sms->io.ports[0].control = (~value) << 5 & 0x60;
+		io_control_write(sms->io.ports, (~value) << 5 & 0x60, z80->current_cycle);
 		fuzzy_ctrl_0 |= sms->io.ports[0].control;
-		sms->io.ports[1].control = (~value) << 3 & 0x60;
+		io_control_write(sms->io.ports+1, (~value) << 3 & 0x60, z80->current_cycle);
 		fuzzy_ctrl_1 |= sms->io.ports[1].control;
 		if (
 			(fuzzy_ctrl_0 & 0x40 & (sms->io.ports[0].output ^ (value << 1)) & (value << 1))