src/mess/drivers/fidelz80.c
| r11554 | r11555 | |
| 9 | 9 | * * Figure out why it says the first speech line twice; it shouldn't. (It sometimes does this on the sensory chess challenger real hardware) |
| 10 | 10 | * * Get rom locations from pcb (done for UVC, VCC is probably similar) |
| 11 | 11 | * * 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) |
| 13 | 12 | * |
| 14 | 13 | *********************************************************************** |
| 15 | 14 | |
| r11554 | r11555 | |
| 766 | 765 | |
| 767 | 766 | WRITE8_MEMBER( fidelz80_state::vsc_portc_w ) |
| 768 | 767 | { |
| 769 | | m_kp_matrix = (m_kp_matrix & 0x100) | data; |
| 768 | m_kp_matrix = (m_kp_matrix & 0x300) | data; |
| 770 | 769 | } |
| 771 | 770 | |
| 772 | 771 | static I8255_INTERFACE( vsc_ppi8255_intf ) |
| r11554 | r11555 | |
| 805 | 804 | data |= (input_port_read(machine(), "COL_H")); |
| 806 | 805 | if (m_kp_matrix & 0x100) |
| 807 | 806 | data |= (input_port_read(machine(), "COL_I")); |
| 807 | if (m_kp_matrix & 0x200) |
| 808 | data |= (input_port_read(machine(), "COL_L")); |
| 808 | 809 | |
| 809 | 810 | return data & 0xff; |
| 810 | 811 | } |
| r11554 | r11555 | |
| 813 | 814 | { |
| 814 | 815 | UINT8 data = 0x00; |
| 815 | 816 | |
| 816 | | if (input_port_read(machine(), "ROW_9") & m_kp_matrix) |
| 817 | | data |= 0x02; |
| 818 | | |
| 819 | 817 | if (s14001a_bsy_r(m_speech) == 0) |
| 820 | 818 | data |= 0x10; |
| 821 | 819 | |
| r11554 | r11555 | |
| 824 | 822 | |
| 825 | 823 | WRITE8_MEMBER( fidelz80_state::vsc_pio_portb_w ) |
| 826 | 824 | { |
| 827 | | m_kp_matrix = (m_kp_matrix & 0xff) | (BIT(data, 0)<<8); |
| 825 | m_kp_matrix = (m_kp_matrix & 0xff) | ((data & 0x03)<<8); |
| 828 | 826 | |
| 829 | 827 | s14001a_set_volume(m_speech, 15); // hack, s14001a core should assume a volume of 15 unless otherwise stated... |
| 830 | 828 | s14001a_rst_w(m_speech, BIT(data, 6)); |
| r11554 | r11555 | |
| 1234 | 1232 | PORT_BIT(0x80, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("RE") PORT_CODE(KEYCODE_R) |
| 1235 | 1233 | |
| 1236 | 1234 | //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) |
| 1244 | 1242 | INPUT_PORTS_END |
| 1245 | 1243 | |
| 1246 | 1244 | static INPUT_PORTS_START( abc ) |