mirror of
https://github.com/holub/mame
synced 2025-04-22 16:31:49 +03:00
Add skeleton AHA-1740 and AHA-1742A ISA devices
This commit is contained in:
parent
c92c0d7d75
commit
c3dc67c1fb
@ -1236,6 +1236,8 @@ if (BUSES["ISA"]~=null) then
|
||||
MAME_DIR .. "src/devices/bus/isa/aha1542b.h",
|
||||
MAME_DIR .. "src/devices/bus/isa/aha1542c.cpp",
|
||||
MAME_DIR .. "src/devices/bus/isa/aha1542c.h",
|
||||
MAME_DIR .. "src/devices/bus/isa/aha174x.cpp",
|
||||
MAME_DIR .. "src/devices/bus/isa/aha174x.h",
|
||||
MAME_DIR .. "src/devices/bus/isa/wd1002a_wx1.cpp",
|
||||
MAME_DIR .. "src/devices/bus/isa/wd1002a_wx1.h",
|
||||
MAME_DIR .. "src/devices/bus/isa/wd1007a.cpp",
|
||||
|
@ -138,7 +138,7 @@ CPUS["CLIPPER"] = true
|
||||
CPUS["CAPRICORN"] = true
|
||||
CPUS["ALPHA"] = true
|
||||
--CPUS["DSPP"] = true
|
||||
--CPUS["HPC"] = true
|
||||
CPUS["HPC"] = true
|
||||
|
||||
--------------------------------------------------
|
||||
-- specify available sound cores; some of these are
|
||||
|
153
src/devices/bus/isa/aha174x.cpp
Normal file
153
src/devices/bus/isa/aha174x.cpp
Normal file
@ -0,0 +1,153 @@
|
||||
// license:BSD-3-Clause
|
||||
// copyright-holders:AJR
|
||||
/***************************************************************************
|
||||
|
||||
Adaptec AHA-1740/44 and AHA-1740A/42A Fast SCSI host adapters
|
||||
|
||||
These are actually EISA cards, though they also have a compatibility
|
||||
mode that provides an interface like the older ISA AHA-154X series.
|
||||
|
||||
The HPC microcode is copied to and then executed out of RAM, allowing
|
||||
it to be reprogrammed by the host.
|
||||
|
||||
The AHA-1740 and AHA-1740A have different board layouts and require
|
||||
different microcode, though they share the following ICs:
|
||||
|
||||
AIC-565 Bus Auxiliary Interface Chip
|
||||
AIC-575 EISA Configuration Chip
|
||||
AIC-4600 HPC (HPC46003V20)
|
||||
AIC-6251A SCSI Interface and Protocol Chip
|
||||
IDT7201 512x9 FIFO (2 on board)
|
||||
Intel 82355 Bus Master Interface Controller
|
||||
|
||||
AHA-1742A is the same as AHA-1740A, only with the FDC populated.
|
||||
|
||||
AHA-1744 uses the same layout as AHA-1740, but populates the area
|
||||
around the SCSI port with DS36F95J differential drivers.
|
||||
|
||||
***************************************************************************/
|
||||
|
||||
#include "emu.h"
|
||||
#include "aha174x.h"
|
||||
|
||||
#include "machine/aic6250.h"
|
||||
//#include "machine/i82355.h"
|
||||
#include "machine/nscsi_bus.h"
|
||||
#include "machine/nscsi_hd.h"
|
||||
|
||||
DEFINE_DEVICE_TYPE(AHA1740, aha1740_device, "aha1740", "AHA-1740 Fast SCSI Host Adapter")
|
||||
DEFINE_DEVICE_TYPE(AHA1742A, aha1742a_device, "aha1742a", "AHA-1742A Fast SCSI Host Adapter")
|
||||
|
||||
|
||||
aha174x_device::aha174x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock)
|
||||
: device_t(mconfig, type, tag, owner, clock)
|
||||
, device_isa16_card_interface(mconfig, *this)
|
||||
, m_hpc(*this, "hpc")
|
||||
, m_bios(*this, "bios")
|
||||
{
|
||||
}
|
||||
|
||||
aha1740_device::aha1740_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock)
|
||||
: aha174x_device(mconfig, AHA1740, tag, owner, clock)
|
||||
{
|
||||
}
|
||||
|
||||
aha1742a_device::aha1742a_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock)
|
||||
: aha174x_device(mconfig, AHA1742A, tag, owner, clock)
|
||||
, m_fdc(*this, "fdc")
|
||||
{
|
||||
}
|
||||
|
||||
void aha174x_device::device_start()
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
void aha174x_device::hpc_map(address_map &map)
|
||||
{
|
||||
map(0x5000, 0x500f).m("scsi:7:scsic", FUNC(aic6251a_device::map));
|
||||
map(0x8000, 0xffff).rom().region("mcode", 0);
|
||||
}
|
||||
|
||||
static void aha174x_scsi_devices(device_slot_interface &device)
|
||||
{
|
||||
device.option_add("harddisk", NSCSI_HARDDISK);
|
||||
device.option_add_internal("scsic", AIC6251A);
|
||||
}
|
||||
|
||||
void aha174x_device::scsic_config(device_t *device)
|
||||
{
|
||||
device->set_clock(40_MHz_XTAL / 2); // divider not verified
|
||||
}
|
||||
|
||||
void aha1740_device::device_add_mconfig(machine_config &config)
|
||||
{
|
||||
HPC46003(config, m_hpc, 40_MHz_XTAL / 2);
|
||||
m_hpc->set_addrmap(AS_PROGRAM, &aha1740_device::hpc_map);
|
||||
|
||||
NSCSI_BUS(config, "scsi");
|
||||
NSCSI_CONNECTOR(config, "scsi:0", aha174x_scsi_devices, nullptr);
|
||||
NSCSI_CONNECTOR(config, "scsi:1", aha174x_scsi_devices, nullptr);
|
||||
NSCSI_CONNECTOR(config, "scsi:2", aha174x_scsi_devices, nullptr);
|
||||
NSCSI_CONNECTOR(config, "scsi:3", aha174x_scsi_devices, nullptr);
|
||||
NSCSI_CONNECTOR(config, "scsi:4", aha174x_scsi_devices, nullptr);
|
||||
NSCSI_CONNECTOR(config, "scsi:5", aha174x_scsi_devices, nullptr);
|
||||
NSCSI_CONNECTOR(config, "scsi:6", aha174x_scsi_devices, nullptr);
|
||||
NSCSI_CONNECTOR(config, "scsi:7", aha174x_scsi_devices, "scsic", true)
|
||||
.set_option_machine_config("scsic", [this] (device_t *device) { scsic_config(device); });
|
||||
}
|
||||
|
||||
void aha1742a_device::device_add_mconfig(machine_config &config)
|
||||
{
|
||||
HPC46003(config, m_hpc, 40_MHz_XTAL / 2);
|
||||
m_hpc->set_addrmap(AS_PROGRAM, &aha1742a_device::hpc_map);
|
||||
|
||||
NSCSI_BUS(config, "scsi");
|
||||
NSCSI_CONNECTOR(config, "scsi:0", aha174x_scsi_devices, nullptr);
|
||||
NSCSI_CONNECTOR(config, "scsi:1", aha174x_scsi_devices, nullptr);
|
||||
NSCSI_CONNECTOR(config, "scsi:2", aha174x_scsi_devices, nullptr);
|
||||
NSCSI_CONNECTOR(config, "scsi:3", aha174x_scsi_devices, nullptr);
|
||||
NSCSI_CONNECTOR(config, "scsi:4", aha174x_scsi_devices, nullptr);
|
||||
NSCSI_CONNECTOR(config, "scsi:5", aha174x_scsi_devices, nullptr);
|
||||
NSCSI_CONNECTOR(config, "scsi:6", aha174x_scsi_devices, nullptr);
|
||||
NSCSI_CONNECTOR(config, "scsi:7", aha174x_scsi_devices, "scsic", true)
|
||||
.set_option_machine_config("scsic", [this] (device_t *device) { scsic_config(device); });
|
||||
|
||||
N82077AA(config, m_fdc, 24_MHz_XTAL);
|
||||
}
|
||||
|
||||
|
||||
ROM_START(aha1740)
|
||||
ROM_REGION(0x4000, "bios", 0)
|
||||
ROM_LOAD("b_dc00.bin", 0x0000, 0x4000, CRC(056d75ec) SHA1(8ca143adfc7d20ad5d49f14dedabc8276454bf9e))
|
||||
|
||||
ROM_REGION(0x8000, "mcode", ROMREGION_ERASE00)
|
||||
ROM_SYSTEM_BIOS(0, "v140st", "BIOS v1.40 (Standard Mode)")
|
||||
ROMX_LOAD("standard.bin", 0x0000, 0x8000, CRC(8c15c6a2) SHA1(77e15b0244e3a814f53f957270e6474a8a839955), ROM_BIOS(0))
|
||||
ROM_SYSTEM_BIOS(1, "v140en", "BIOS v1.40 (Enhanced Mode)")
|
||||
ROMX_LOAD("enhanced.bin", 0x0000, 0x8000, CRC(84b3df89) SHA1(a718c3ea5443a609b4b20bfe48be18193737ad25), ROM_BIOS(1))
|
||||
// Adaptec's help file claims that "the EEPROM on the board can hold firmware for both modes simultaneously."
|
||||
// The AHA-174XA firmware images obviously have this, but the files provided here do not agree.
|
||||
ROM_END
|
||||
|
||||
ROM_START(aha1742a)
|
||||
ROM_REGION(0x4000, "bios", 0)
|
||||
ROM_SYSTEM_BIOS(0, "v140", "BIOS v1.40")
|
||||
ROMX_LOAD("b_dc00.bin", 0x0000, 0x4000, CRC(056d75ec) SHA1(8ca143adfc7d20ad5d49f14dedabc8276454bf9e), ROM_BIOS(0))
|
||||
ROM_SYSTEM_BIOS(1, "v140s", "BIOS v1.40 (Extended Timeout)")
|
||||
ROMX_LOAD("b_f100.bin", 0x0000, 0x4000, CRC(b695acc0) SHA1(683112fafdf83d5eb89237d9215f7d6eacc6eeaf), ROM_BIOS(1))
|
||||
|
||||
ROM_REGION(0x8000, "mcode", 0)
|
||||
ROMX_LOAD("m_b7d6.bin", 0x0000, 0x8000, CRC(0a55a555) SHA1(ff400f56b33f0ad94e34564d7715a0773b335844), ROM_BIOS(0))
|
||||
ROMX_LOAD("m_c7b8.bin", 0x0000, 0x8000, CRC(21282e86) SHA1(18cb3960dc47f2c14beb88f9680c1f66c4652b04), ROM_BIOS(1))
|
||||
ROM_END
|
||||
|
||||
const tiny_rom_entry *aha1740_device::device_rom_region() const
|
||||
{
|
||||
return ROM_NAME(aha1740);
|
||||
}
|
||||
|
||||
const tiny_rom_entry *aha1742a_device::device_rom_region() const
|
||||
{
|
||||
return ROM_NAME(aha1742a);
|
||||
}
|
61
src/devices/bus/isa/aha174x.h
Normal file
61
src/devices/bus/isa/aha174x.h
Normal file
@ -0,0 +1,61 @@
|
||||
// license:BSD-3-Clause
|
||||
// copyright-holders:AJR
|
||||
/***************************************************************************
|
||||
|
||||
Adaptec AHA-1540/42A and AHA-1540/42B SCSI controllers
|
||||
|
||||
***************************************************************************/
|
||||
|
||||
#ifndef MAME_BUS_ISA_AHA174X_H
|
||||
#define MAME_BUS_ISA_AHA174X_H
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "isa.h"
|
||||
#include "cpu/hpc/hpc.h"
|
||||
#include "machine/upd765.h"
|
||||
|
||||
class aha174x_device : public device_t, public device_isa16_card_interface
|
||||
{
|
||||
protected:
|
||||
aha174x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock);
|
||||
|
||||
virtual void device_start() override;
|
||||
|
||||
void hpc_map(address_map &map);
|
||||
void scsic_config(device_t *device);
|
||||
|
||||
required_device<hpc46003_device> m_hpc;
|
||||
required_region_ptr<u8> m_bios;
|
||||
};
|
||||
|
||||
class aha1740_device : public aha174x_device
|
||||
{
|
||||
public:
|
||||
aha1740_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock);
|
||||
|
||||
static constexpr feature_type unemulated_features() { return feature::DISK; }
|
||||
|
||||
protected:
|
||||
virtual void device_add_mconfig(machine_config &config) override;
|
||||
virtual const tiny_rom_entry *device_rom_region() const override;
|
||||
};
|
||||
|
||||
class aha1742a_device : public aha174x_device
|
||||
{
|
||||
public:
|
||||
aha1742a_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock);
|
||||
|
||||
static constexpr feature_type unemulated_features() { return feature::DISK; }
|
||||
|
||||
protected:
|
||||
virtual void device_add_mconfig(machine_config &config) override;
|
||||
virtual const tiny_rom_entry *device_rom_region() const override;
|
||||
|
||||
required_device<upd765_family_device> m_fdc;
|
||||
};
|
||||
|
||||
DECLARE_DEVICE_TYPE(AHA1740, aha1740_device)
|
||||
DECLARE_DEVICE_TYPE(AHA1742A, aha1742a_device)
|
||||
|
||||
#endif // MAME_BUS_ISA_AHA174X_H
|
@ -33,6 +33,7 @@
|
||||
#include "side116.h"
|
||||
#include "aha1542b.h"
|
||||
#include "aha1542c.h"
|
||||
#include "aha174x.h"
|
||||
#include "wd1002a_wx1.h"
|
||||
#include "wd1007a.h"
|
||||
#include "mcd.h"
|
||||
@ -159,6 +160,8 @@ void pc_isa16_cards(device_slot_interface &device)
|
||||
device.option_add("aha1542c", AHA1542C);
|
||||
device.option_add("aha1542cf", AHA1542CF);
|
||||
device.option_add("aha1542cp", AHA1542CP);
|
||||
device.option_add("aha1740", AHA1740); // actually an EISA card
|
||||
device.option_add("aha1742a", AHA1742A); // actually an EISA card
|
||||
device.option_add("gus",ISA16_GUS);
|
||||
device.option_add("sblaster_16", ISA16_SOUND_BLASTER_16);
|
||||
device.option_add("svga_s3", ISA16_SVGA_S3);
|
||||
|
@ -42,12 +42,13 @@
|
||||
#include "logmacro.h"
|
||||
|
||||
DEFINE_DEVICE_TYPE(AIC6250, aic6250_device, "aic6250", "Adaptec AIC-6250 High-Performance SCSI Protocol Chip")
|
||||
DEFINE_DEVICE_TYPE(AIC6251A, aic6251a_device, "aic6251a", "Adaptec AIC-6251A Fast SCSI Protocol Chip")
|
||||
|
||||
static char const *const nscsi_phase[] = { "DATA OUT", "DATA IN", "COMMAND", "STATUS", "*", "*", "MESSAGE OUT", "MESSAGE IN" };
|
||||
static char const *const aic6250_phase[] = { "DATA OUT", "*", "DATA IN", "*", "COMMAND", "MESSAGE OUT", "STATUS", "MESSAGE IN" };
|
||||
|
||||
aic6250_device::aic6250_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock)
|
||||
: nscsi_device(mconfig, AIC6250, tag, owner, clock)
|
||||
aic6250_device::aic6250_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock)
|
||||
: nscsi_device(mconfig, type, tag, owner, clock)
|
||||
, m_int_cb(*this)
|
||||
, m_breq_cb(*this)
|
||||
, m_port_a_r_cb(*this)
|
||||
@ -57,6 +58,16 @@ aic6250_device::aic6250_device(const machine_config &mconfig, const char *tag, d
|
||||
{
|
||||
}
|
||||
|
||||
aic6250_device::aic6250_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock)
|
||||
: aic6250_device(mconfig, AIC6250, tag, owner, clock)
|
||||
{
|
||||
}
|
||||
|
||||
aic6251a_device::aic6251a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock)
|
||||
: aic6250_device(mconfig, AIC6251A, tag, owner, clock)
|
||||
{
|
||||
}
|
||||
|
||||
void aic6250_device::map(address_map &map)
|
||||
{
|
||||
map(0x0, 0x0).rw(FUNC(aic6250_device::dma_count_l_r), FUNC(aic6250_device::dma_count_l_w));
|
||||
|
@ -34,6 +34,8 @@ public:
|
||||
void dma16_w(u16 data);
|
||||
|
||||
protected:
|
||||
aic6250_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock);
|
||||
|
||||
// standard device_interface overrides
|
||||
virtual void device_start() override;
|
||||
virtual void device_reset() override;
|
||||
@ -277,6 +279,13 @@ private:
|
||||
util::fifo <u8, 8> m_fifo;
|
||||
};
|
||||
|
||||
class aic6251a_device : public aic6250_device
|
||||
{
|
||||
public:
|
||||
aic6251a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
|
||||
};
|
||||
|
||||
DECLARE_DEVICE_TYPE(AIC6250, aic6250_device)
|
||||
DECLARE_DEVICE_TYPE(AIC6251A, aic6251a_device)
|
||||
|
||||
#endif // MAME_MACHINE_AIC6250_H
|
||||
|
Loading…
Reference in New Issue
Block a user