nforcepc: small update to it8703f, more to come (nw)

This commit is contained in:
yz70s 2019-11-24 17:47:45 +01:00
parent 48393e5de8
commit 6a8ffd5ff4
2 changed files with 33 additions and 11 deletions

View File

@ -362,9 +362,14 @@ it8703f_device::it8703f_device(const machine_config &mconfig, const char *tag, d
, pin_reset_callback(*this)
, pin_gatea20_callback(*this)
, m_kbdc(*this, "pc_kbdc")
, enabled_game_port(false)
, enabled_midi_port(false)
{
memset(global_configuration_registers, 0, sizeof(global_configuration_registers));
memset(configuration_registers, 0, sizeof(configuration_registers));
global_configuration_registers[0x20] = 0x87; // identifies it8703f
global_configuration_registers[0x21] = 1;
global_configuration_registers[0x24] = 4;
for (int n = 0; n < 13; n++)
enabled_logical[n] = false;
}
@ -500,6 +505,21 @@ void it8703f_device::write_logical_configuration_register(int index, int data)
}
}
break;
case LogicalDevice::Serial1:
break;
case LogicalDevice::Serial2:
break;
case LogicalDevice::Parallel:
break;
case LogicalDevice::Gpio1:
if (index == 0x30)
{
if (data & 1)
enabled_game_port = true;
if (data & 2)
enabled_midi_port = true;
}
break;
}
}

View File

@ -209,17 +209,17 @@ private:
} mode;
enum LogicalDevice
{
FDC = 0,
Parallel,
Serial1,
Serial2,
Keyboard = 5,
ConsumerIR,
Gpio1,
Gpio2,
Gpio34,
ACPI,
Gpio567 = 12
FDC = 0, // Floppy disk controller
Parallel, // Parallel port
Serial1, // Serial port 1
Serial2, // Serial port 2
Keyboard = 5, // Keyboard controller
ConsumerIR, // Consumer IR
Gpio1, // Game port, MIDI, GPIO set 1
Gpio2, // GPIO set 2
Gpio34, // GPIO set 3 and 4
ACPI, // ACPI
Gpio567 = 12 // GPIO set 5, 6 and 7
};
int config_key_step;
int config_index;
@ -230,6 +230,8 @@ private:
devcb_write_line pin_gatea20_callback;
required_device<kbdc8042_device> m_kbdc;
bool enabled_logical[13];
bool enabled_game_port;
bool enabled_midi_port;
lpcbus_host_interface *lpchost;
int lpcindex;