Previous 15994 Revisions Next

r11555 Sunday 15th May, 2011 at 23:33:17 UTC by Sandro Ronco
[VSC] Fixed input for the upper 6 buttons. (no whatsnew)
[src/mess/drivers]fidelz80.c

src/mess/drivers/fidelz80.c
r11554r11555
99*  * Figure out why it says the first speech line twice; it shouldn't. (It sometimes does this on the sensory chess challenger real hardware)
1010*  * Get rom locations from pcb (done for UVC, VCC is probably similar)
1111*  * correctly hook up VBC/ABC speech so that the z80 is halted while words are being spoken
12*  * VSC doesn't accept input from row 9 (the buttons beside the display)
1312*
1413***********************************************************************
1514
r11554r11555
766765
767766WRITE8_MEMBER( fidelz80_state::vsc_portc_w )
768767{
769   m_kp_matrix = (m_kp_matrix & 0x100) | data;
768   m_kp_matrix = (m_kp_matrix & 0x300) | data;
770769}
771770
772771static I8255_INTERFACE( vsc_ppi8255_intf )
r11554r11555
805804      data |= (input_port_read(machine(), "COL_H"));
806805   if (m_kp_matrix & 0x100)
807806      data |= (input_port_read(machine(), "COL_I"));
807   if (m_kp_matrix & 0x200)
808      data |= (input_port_read(machine(), "COL_L"));
808809
809810   return data & 0xff;
810811}
r11554r11555
813814{
814815   UINT8 data = 0x00;
815816
816   if (input_port_read(machine(), "ROW_9") & m_kp_matrix)
817      data |= 0x02;
818
819817   if (s14001a_bsy_r(m_speech) == 0)
820818      data |= 0x10;
821819
r11554r11555
824822
825823WRITE8_MEMBER( fidelz80_state::vsc_pio_portb_w )
826824{
827   m_kp_matrix = (m_kp_matrix & 0xff) | (BIT(data, 0)<<8);
825   m_kp_matrix = (m_kp_matrix & 0xff) | ((data & 0x03)<<8);
828826
829827   s14001a_set_volume(m_speech, 15); // hack, s14001a core should assume a volume of 15 unless otherwise stated...
830828   s14001a_rst_w(m_speech, BIT(data, 6));
r11554r11555
12341232      PORT_BIT(0x80, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("RE")      PORT_CODE(KEYCODE_R)
12351233
12361234   //buttons beside the display
1237   PORT_START("ROW_9")
1238      PORT_BIT(0x01, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("Speak")   PORT_CODE(KEYCODE_1_PAD)
1239      PORT_BIT(0x02, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("RV")      PORT_CODE(KEYCODE_2_PAD)
1240      PORT_BIT(0x04, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("TM")      PORT_CODE(KEYCODE_3_PAD)
1241      PORT_BIT(0x08, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("LV")      PORT_CODE(KEYCODE_4_PAD)
1242      PORT_BIT(0x10, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("DM")      PORT_CODE(KEYCODE_5_PAD)
1243      PORT_BIT(0x20, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("ST")      PORT_CODE(KEYCODE_6_PAD)
1235   PORT_START("COL_L")
1236      PORT_BIT(0x01, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("TM")      PORT_CODE(KEYCODE_T)
1237      PORT_BIT(0x02, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("RV")      PORT_CODE(KEYCODE_V)
1238      PORT_BIT(0x04, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("Speak")   PORT_CODE(KEYCODE_SPACE)
1239      PORT_BIT(0x08, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("LV")      PORT_CODE(KEYCODE_L)
1240      PORT_BIT(0x10, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("DM")      PORT_CODE(KEYCODE_M)
1241      PORT_BIT(0x20, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("ST")      PORT_CODE(KEYCODE_S)
12441242INPUT_PORTS_END
12451243
12461244static INPUT_PORTS_START( abc )

Previous 15994 Revisions Next


© 1998-2018 The MESS Team