From 1b3081129da5927c5f594022f664118a02840265 Mon Sep 17 00:00:00 2001 From: Robbbert Date: Wed, 27 Apr 2022 19:50:12 +1000 Subject: [PATCH] swtpc8212: fixed crash on exit if you adjust a dipswitch. Validation should mark switch 0 as invalid but doesn't. --- src/devices/machine/swtpc8212.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/devices/machine/swtpc8212.cpp b/src/devices/machine/swtpc8212.cpp index 68d433e1186..92a084b2880 100644 --- a/src/devices/machine/swtpc8212.cpp +++ b/src/devices/machine/swtpc8212.cpp @@ -456,7 +456,7 @@ INPUT_PORTS_START(swtpc8212) PORT_BIT(0x8000U, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("+ / CR") PORT_CHANGED_MEMBER(DEVICE_SELF, swtpc8212_device, keypad_changed, 0) PORT_START("DIP_SWITCHES") - PORT_DIPNAME(0x1f, 0x19, "Baud Rate") PORT_DIPLOCATION("DIP:4,3,2,1,0") + PORT_DIPNAME(0x1f, 0x19, "Baud Rate") PORT_DIPLOCATION("DIP:5,4,3,2,1") PORT_DIPSETTING(0x04, "110") PORT_DIPSETTING(0x0a, "300") PORT_DIPSETTING(0x0d, "600") @@ -467,13 +467,13 @@ INPUT_PORTS_START(swtpc8212) PORT_DIPSETTING(0x19, "9600") PORT_DIPSETTING(0x1c, "19200") PORT_DIPSETTING(0x1f, "38400") - PORT_DIPNAME(0x20, 0x00, "Mode switch") PORT_DIPLOCATION("DIP:5") + PORT_DIPNAME(0x20, 0x00, "Mode switch") PORT_DIPLOCATION("DIP:6") PORT_DIPSETTING(0x00, "Conversational") PORT_DIPSETTING(0x20, "Page edit") - PORT_DIPNAME(0x40, 0x00, "No Parity") PORT_DIPLOCATION("DIP:6") + PORT_DIPNAME(0x40, 0x00, "No Parity") PORT_DIPLOCATION("DIP:7") PORT_DIPSETTING(0x00, "No Parity") PORT_DIPSETTING(0x40, "Parity") - PORT_DIPNAME(0x80, 0x00, "Parity Select") PORT_DIPLOCATION("DIP:7") + PORT_DIPNAME(0x80, 0x00, "Parity Select") PORT_DIPLOCATION("DIP:8") PORT_DIPSETTING(0x00, "Odd or Mark") PORT_DIPSETTING(0x80, "Even or Space")