mirror of
https://github.com/holub/mame
synced 2025-04-19 15:11:37 +03:00
bbc: Added various 2nd processors as Tube slot devices:
- Acorn 6502 2nd Processor, Acorn 65C102 Co-Processor, Acorn Z80 2nd Processor, Acorn 80186 Co-Processor, Casper 68000 2nd Processor
This commit is contained in:
parent
c967171c7a
commit
d9297807e2
@ -294,6 +294,16 @@ if (BUSES["BBC_TUBE"]~=null) then
|
||||
files {
|
||||
MAME_DIR .. "src/devices/bus/bbc/tube/tube.cpp",
|
||||
MAME_DIR .. "src/devices/bus/bbc/tube/tube.h",
|
||||
MAME_DIR .. "src/devices/bus/bbc/tube/tube_6502.cpp",
|
||||
MAME_DIR .. "src/devices/bus/bbc/tube/tube_6502.h",
|
||||
MAME_DIR .. "src/devices/bus/bbc/tube/tube_65c102.cpp",
|
||||
MAME_DIR .. "src/devices/bus/bbc/tube/tube_65c102.h",
|
||||
MAME_DIR .. "src/devices/bus/bbc/tube/tube_80186.cpp",
|
||||
MAME_DIR .. "src/devices/bus/bbc/tube/tube_80186.h",
|
||||
MAME_DIR .. "src/devices/bus/bbc/tube/tube_casper.cpp",
|
||||
MAME_DIR .. "src/devices/bus/bbc/tube/tube_casper.h",
|
||||
MAME_DIR .. "src/devices/bus/bbc/tube/tube_z80.cpp",
|
||||
MAME_DIR .. "src/devices/bus/bbc/tube/tube_z80.h",
|
||||
}
|
||||
end
|
||||
|
||||
|
@ -54,7 +54,18 @@ device_bbc_tube_interface::~device_bbc_tube_interface()
|
||||
|
||||
bbc_tube_slot_device::bbc_tube_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) :
|
||||
device_t(mconfig, BBC_TUBE_SLOT, tag, owner, clock),
|
||||
device_slot_interface(mconfig, *this)
|
||||
device_slot_interface(mconfig, *this),
|
||||
m_card(nullptr),
|
||||
m_irq_handler(*this)
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
//-------------------------------------------------
|
||||
// bbc_tube_slot_device - destructor
|
||||
//-------------------------------------------------
|
||||
|
||||
bbc_tube_slot_device::~bbc_tube_slot_device()
|
||||
{
|
||||
}
|
||||
|
||||
@ -66,6 +77,9 @@ bbc_tube_slot_device::bbc_tube_slot_device(const machine_config &mconfig, const
|
||||
void bbc_tube_slot_device::device_start()
|
||||
{
|
||||
m_card = dynamic_cast<device_bbc_tube_interface *>(get_card_device());
|
||||
|
||||
// resolve callbacks
|
||||
m_irq_handler.resolve_safe();
|
||||
}
|
||||
|
||||
|
||||
@ -83,44 +97,75 @@ void bbc_tube_slot_device::device_reset()
|
||||
|
||||
|
||||
//-------------------------------------------------
|
||||
// SLOT_INTERFACE( bbc_tube_ext_devices )
|
||||
// host_r
|
||||
//-------------------------------------------------
|
||||
|
||||
READ8_MEMBER(bbc_tube_slot_device::host_r)
|
||||
{
|
||||
if (m_card)
|
||||
return m_card->host_r(space, offset);
|
||||
else
|
||||
return 0xfe;
|
||||
}
|
||||
|
||||
//-------------------------------------------------
|
||||
// host_w
|
||||
//-------------------------------------------------
|
||||
|
||||
WRITE8_MEMBER(bbc_tube_slot_device::host_w)
|
||||
{
|
||||
if (m_card)
|
||||
m_card->host_w(space, offset, data);
|
||||
}
|
||||
|
||||
|
||||
// slot devices
|
||||
//#include "6502copro.h"
|
||||
//#include "z80copro.h"
|
||||
//#include "32016copro.h"
|
||||
//#include "cambcopro.h"
|
||||
//#include "armcopro.h"
|
||||
//#include "unicopro.h"
|
||||
#include "tube_6502.h"
|
||||
#include "tube_65c102.h"
|
||||
#include "tube_80186.h"
|
||||
//#include "tube_80286.h"
|
||||
//#include "tube_arm.h"
|
||||
#include "tube_casper.h"
|
||||
//#include "tube_x25.h"
|
||||
#include "tube_z80.h"
|
||||
//#include "tube_zep100.h"
|
||||
|
||||
|
||||
SLOT_INTERFACE_START( bbc_tube_ext_devices )
|
||||
// SLOT_INTERFACE("6502copro", BBC_6502_COPRO) /* Acorn ANC01 6502 2nd processor */
|
||||
// SLOT_INTERFACE("z80copro", BBC_Z80_COPRO) /* Acorn ANC04 Z80 2nd processor */
|
||||
// SLOT_INTERFACE("32016copro", BBC_32016_COPRO) /* Acorn ANC05 32016 2nd processor */
|
||||
// SLOT_INTERFACE("cambcopro", BBC_CAMB_COPRO) /* Acorn ANC06 Cambridge Co-Processor */
|
||||
// SLOT_INTERFACE("armcopro", BBC_ARM_COPRO) /* Acorn ANC13 ARM Evaluation System */
|
||||
// SLOT_INTERFACE("unicopro", BBC_UNIVERSAL) /* Acorn ANC21 Universal 2nd Processor Unit */
|
||||
// SLOT_INTERFACE("a500copro", BBC_A500_COPRO) /* Acorn A500 2nd Processor */
|
||||
//-------------------------------------------------
|
||||
// SLOT_INTERFACE( bbc_extube_devices )
|
||||
//-------------------------------------------------
|
||||
|
||||
SLOT_INTERFACE_START( bbc_extube_devices )
|
||||
SLOT_INTERFACE("6502", BBC_TUBE_6502) /* Acorn ANC01 6502 2nd processor */
|
||||
SLOT_INTERFACE("z80", BBC_TUBE_Z80) /* Acorn ANC04 Z80 2nd processor */
|
||||
// SLOT_INTERFACE("32016", BBC_TUBE_32016) /* Acorn ANC05 32016 2nd processor */
|
||||
// SLOT_INTERFACE("camb", BBC_TUBE_CAMB) /* Acorn ANC06 Cambridge Co-Processor */
|
||||
// SLOT_INTERFACE("arm", BBC_TUBE_ARM) /* Acorn ANC13 ARM Evaluation System */
|
||||
// SLOT_INTERFACE("80286", BBC_TUBE_80286) /* Acorn 80286 2nd Processor */
|
||||
// SLOT_INTERFACE("a500", BBC_TUBE_A500) /* Acorn A500 2nd Processor */
|
||||
SLOT_INTERFACE("casper", BBC_TUBE_CASPER) /* Casper 68000 2nd Processor */
|
||||
// SLOT_INTERFACE("zep100", BBC_TUBE_ZEP100) /* Torch Z80 Communicator (ZEP100) */
|
||||
/* Acorn ANC21 Universal 2nd Processor Unit */
|
||||
SLOT_INTERFACE("65c102", BBC_TUBE_65C102) /* Acorn ADC06 65C102 co-processor */
|
||||
SLOT_INTERFACE("80186", BBC_TUBE_80186) /* Acorn ADC08 80186 co-processor */
|
||||
SLOT_INTERFACE_END
|
||||
|
||||
|
||||
//-------------------------------------------------
|
||||
// SLOT_INTERFACE( bbc_tube_int_devices )
|
||||
// SLOT_INTERFACE( bbc_intube_devices )
|
||||
//-------------------------------------------------
|
||||
|
||||
|
||||
// slot devices
|
||||
//#include "65c102copro.h"
|
||||
//#include "80186copro.h"
|
||||
//#include "arm7copro.h"
|
||||
|
||||
|
||||
SLOT_INTERFACE_START( bbc_tube_int_devices )
|
||||
// SLOT_INTERFACE("65c102copro", BBC_65C102_COPRO) /* Acorn ADC06 6502 co-processor */
|
||||
// SLOT_INTERFACE("80186copro", BBC_80186_COPRO) /* Acorn ADC08 80186 co-processor */
|
||||
// SLOT_INTERFACE("80286copro", BBC_80286_COPRO) /* Acorn ADC08 80286 co-processor */
|
||||
// SLOT_INTERFACE("arm7copro", BBC_ARM7_COPRO) /* Sprow ARM7 co-processor */
|
||||
SLOT_INTERFACE_START( bbc_intube_devices )
|
||||
SLOT_INTERFACE("65c102", BBC_TUBE_65C102) /* Acorn ADC06 65C102 co-processor */
|
||||
SLOT_INTERFACE("80186", BBC_TUBE_80186) /* Acorn ADC08 80186 co-processor */
|
||||
// SLOT_INTERFACE("arm7", BBC_TUBE_ARM7) /* Sprow ARM7 co-processor */
|
||||
SLOT_INTERFACE_END
|
||||
|
||||
|
||||
//-------------------------------------------------
|
||||
// SLOT_INTERFACE( bbc_x25tube_devices )
|
||||
//-------------------------------------------------
|
||||
|
||||
//SLOT_INTERFACE_START( bbc_x25tube_devices )
|
||||
// SLOT_INTERFACE("x25", BBC_TUBE_X25) /* Econet X25 Gateway */
|
||||
//SLOT_INTERFACE_END
|
||||
|
@ -53,15 +53,15 @@
|
||||
MCFG_DEVICE_ADD(_tag, BBC_TUBE_SLOT, 0) \
|
||||
MCFG_DEVICE_SLOT_INTERFACE(_slot_intf, _def_slot, false)
|
||||
|
||||
#define MCFG_BBC_PASSTHRU_TUBE_SLOT_ADD() \
|
||||
MCFG_BBC_TUBE_SLOT_ADD(BBC_TUBE_SLOT_TAG, 0, bbc_tube_devices, nullptr)
|
||||
|
||||
#define MCFG_BBC_TUBE_SLOT_IRQ_HANDLER(_devcb) \
|
||||
devcb = &bbc_tube_slot_device::set_irq_handler(*device, DEVCB_##_devcb);
|
||||
|
||||
|
||||
//**************************************************************************
|
||||
// TYPE DEFINITIONS
|
||||
//**************************************************************************
|
||||
|
||||
|
||||
// ======================> bbc_tube_slot_device
|
||||
|
||||
class device_bbc_tube_interface;
|
||||
@ -71,6 +71,16 @@ class bbc_tube_slot_device : public device_t, public device_slot_interface
|
||||
public:
|
||||
// construction/destruction
|
||||
bbc_tube_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
|
||||
virtual ~bbc_tube_slot_device();
|
||||
|
||||
// callbacks
|
||||
template <class Object> static devcb_base &set_irq_handler(device_t &device, Object &&cb)
|
||||
{ return downcast<bbc_tube_slot_device &>(device).m_irq_handler.set_callback(std::forward<Object>(cb)); }
|
||||
|
||||
DECLARE_READ8_MEMBER( host_r );
|
||||
DECLARE_WRITE8_MEMBER( host_w );
|
||||
|
||||
DECLARE_WRITE_LINE_MEMBER( irq_w ) { m_irq_handler(state); }
|
||||
|
||||
protected:
|
||||
// device-level overrides
|
||||
@ -78,6 +88,9 @@ protected:
|
||||
virtual void device_reset() override;
|
||||
|
||||
device_bbc_tube_interface *m_card;
|
||||
|
||||
private:
|
||||
devcb_write_line m_irq_handler;
|
||||
};
|
||||
|
||||
|
||||
@ -89,6 +102,10 @@ public:
|
||||
// construction/destruction
|
||||
virtual ~device_bbc_tube_interface();
|
||||
|
||||
// reading and writing
|
||||
virtual DECLARE_READ8_MEMBER(host_r) { return 0xfe; }
|
||||
virtual DECLARE_WRITE8_MEMBER(host_w) { }
|
||||
|
||||
protected:
|
||||
device_bbc_tube_interface(const machine_config &mconfig, device_t &device);
|
||||
|
||||
@ -99,8 +116,9 @@ protected:
|
||||
// device type definition
|
||||
DECLARE_DEVICE_TYPE(BBC_TUBE_SLOT, bbc_tube_slot_device)
|
||||
|
||||
SLOT_INTERFACE_EXTERN( bbc_tube_ext_devices );
|
||||
SLOT_INTERFACE_EXTERN( bbc_tube_int_devices );
|
||||
SLOT_INTERFACE_EXTERN( bbc_extube_devices );
|
||||
SLOT_INTERFACE_EXTERN( bbc_intube_devices );
|
||||
//SLOT_INTERFACE_EXTERN( bbc_x25tube_devices );
|
||||
|
||||
|
||||
#endif // MAME_BUS_BBC_TUBE_TUBE_H
|
||||
|
157
src/devices/bus/bbc/tube/tube_6502.cpp
Normal file
157
src/devices/bus/bbc/tube/tube_6502.cpp
Normal file
@ -0,0 +1,157 @@
|
||||
// license:BSD-3-Clause
|
||||
// copyright-holders:Nigel Barnes
|
||||
/**********************************************************************
|
||||
|
||||
Acorn ANC01 6502 2nd Processor
|
||||
|
||||
http://chrisacorns.computinghistory.org.uk/8bit_Upgrades/Acorn_ANC01_65022ndproc.html
|
||||
|
||||
**********************************************************************/
|
||||
|
||||
|
||||
#include "emu.h"
|
||||
#include "tube_6502.h"
|
||||
#include "softlist_dev.h"
|
||||
|
||||
|
||||
//**************************************************************************
|
||||
// DEVICE DEFINITIONS
|
||||
//**************************************************************************
|
||||
|
||||
DEFINE_DEVICE_TYPE(BBC_TUBE_6502, bbc_tube_6502_device, "bbc_tube_6502", "Acorn 6502 2nd Processor")
|
||||
|
||||
|
||||
//-------------------------------------------------
|
||||
// ADDRESS_MAP( tube_6502_mem )
|
||||
//-------------------------------------------------
|
||||
|
||||
static ADDRESS_MAP_START(tube_6502_mem, AS_PROGRAM, 8, bbc_tube_6502_device)
|
||||
AM_RANGE(0x0000, 0xffff) AM_READWRITE(read, write)
|
||||
ADDRESS_MAP_END
|
||||
|
||||
//-------------------------------------------------
|
||||
// ROM( tube_6502 )
|
||||
//-------------------------------------------------
|
||||
|
||||
ROM_START( tube_6502 )
|
||||
ROM_REGION(0x1000, "rom", 0)
|
||||
ROM_LOAD("6502tube.rom", 0x0000, 0x1000, CRC(98b5fe42) SHA1(338269d03cf6bfa28e09d1651c273ea53394323b))
|
||||
ROM_END
|
||||
|
||||
//-------------------------------------------------
|
||||
// device_add_mconfig - add device configuration
|
||||
//-------------------------------------------------
|
||||
|
||||
MACHINE_CONFIG_MEMBER( bbc_tube_6502_device::device_add_mconfig )
|
||||
MCFG_CPU_ADD("m6502", M65C02, XTAL_12MHz / 4)
|
||||
MCFG_CPU_PROGRAM_MAP(tube_6502_mem)
|
||||
|
||||
MCFG_TUBE_ADD("ula")
|
||||
MCFG_TUBE_PNMI_HANDLER(INPUTLINE("m6502", M65C02_NMI_LINE))
|
||||
MCFG_TUBE_PIRQ_HANDLER(INPUTLINE("m6502", M65C02_IRQ_LINE))
|
||||
|
||||
/* internal ram */
|
||||
MCFG_RAM_ADD(RAM_TAG)
|
||||
MCFG_RAM_DEFAULT_SIZE("64K")
|
||||
MCFG_RAM_DEFAULT_VALUE(0x00)
|
||||
|
||||
/* software lists */
|
||||
MCFG_SOFTWARE_LIST_ADD("flop_ls_6502", "bbc_flop_6502")
|
||||
MCFG_SOFTWARE_LIST_ADD("flop_ls_65c102", "bbc_flop_65c102")
|
||||
MACHINE_CONFIG_END
|
||||
|
||||
//-------------------------------------------------
|
||||
// rom_region - device-specific ROM region
|
||||
//-------------------------------------------------
|
||||
|
||||
const tiny_rom_entry *bbc_tube_6502_device::device_rom_region() const
|
||||
{
|
||||
return ROM_NAME( tube_6502 );
|
||||
}
|
||||
|
||||
//**************************************************************************
|
||||
// LIVE DEVICE
|
||||
//**************************************************************************
|
||||
|
||||
//-------------------------------------------------
|
||||
// bbc_tube_6502_device - constructor
|
||||
//-------------------------------------------------
|
||||
|
||||
bbc_tube_6502_device::bbc_tube_6502_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock)
|
||||
: device_t(mconfig, BBC_TUBE_6502, tag, owner, clock),
|
||||
device_bbc_tube_interface(mconfig, *this),
|
||||
m_m6502(*this, "m6502"),
|
||||
m_ula(*this, "ula"),
|
||||
m_ram(*this, "ram"),
|
||||
m_rom(*this, "rom"),
|
||||
m_rom_enabled(true)
|
||||
{
|
||||
}
|
||||
|
||||
//-------------------------------------------------
|
||||
// device_start - device-specific startup
|
||||
//-------------------------------------------------
|
||||
|
||||
void bbc_tube_6502_device::device_start()
|
||||
{
|
||||
m_slot = dynamic_cast<bbc_tube_slot_device *>(owner());
|
||||
}
|
||||
|
||||
//-------------------------------------------------
|
||||
// device_reset - device-specific reset
|
||||
//-------------------------------------------------
|
||||
|
||||
void bbc_tube_6502_device::device_reset()
|
||||
{
|
||||
m_ula->reset();
|
||||
|
||||
m_rom_enabled = true;
|
||||
}
|
||||
|
||||
|
||||
//**************************************************************************
|
||||
// IMPLEMENTATION
|
||||
//**************************************************************************
|
||||
|
||||
READ8_MEMBER(bbc_tube_6502_device::host_r)
|
||||
{
|
||||
return m_ula->host_r(space, offset);
|
||||
}
|
||||
|
||||
WRITE8_MEMBER(bbc_tube_6502_device::host_w)
|
||||
{
|
||||
m_ula->host_w(space, offset, data);
|
||||
}
|
||||
|
||||
|
||||
READ8_MEMBER(bbc_tube_6502_device::read)
|
||||
{
|
||||
uint8_t data;
|
||||
|
||||
if (offset >= 0xfef0 && offset <= 0xfeff)
|
||||
{
|
||||
if (!machine().side_effect_disabled()) m_rom_enabled = false;
|
||||
data = m_ula->parasite_r(space, offset);
|
||||
}
|
||||
else if (m_rom_enabled && (offset >= 0xf000))
|
||||
{
|
||||
data = m_rom->base()[offset & 0xfff];
|
||||
}
|
||||
else
|
||||
{
|
||||
data = m_ram->pointer()[offset];
|
||||
}
|
||||
return data;
|
||||
}
|
||||
|
||||
WRITE8_MEMBER(bbc_tube_6502_device::write)
|
||||
{
|
||||
if (offset >= 0xfef0 && offset <= 0xfeff)
|
||||
{
|
||||
m_ula->parasite_w(space, offset, data);
|
||||
}
|
||||
else
|
||||
{
|
||||
m_ram->pointer()[offset] = data;
|
||||
}
|
||||
}
|
63
src/devices/bus/bbc/tube/tube_6502.h
Normal file
63
src/devices/bus/bbc/tube/tube_6502.h
Normal file
@ -0,0 +1,63 @@
|
||||
// license:BSD-3-Clause
|
||||
// copyright-holders:Nigel Barnes
|
||||
/**********************************************************************
|
||||
|
||||
Acorn ANC01 6502 2nd Processor
|
||||
|
||||
http://chrisacorns.computinghistory.org.uk/8bit_Upgrades/Acorn_ANC01_65022ndproc.html
|
||||
|
||||
**********************************************************************/
|
||||
|
||||
|
||||
#ifndef MAME_BUS_BBC_TUBE_6502_H
|
||||
#define MAME_BUS_BBC_TUBE_6502_H
|
||||
|
||||
#include "tube.h"
|
||||
#include "cpu/m6502/m65c02.h"
|
||||
#include "machine/ram.h"
|
||||
#include "machine/tube.h"
|
||||
|
||||
//**************************************************************************
|
||||
// TYPE DEFINITIONS
|
||||
//**************************************************************************
|
||||
|
||||
// ======================> bbc_tube_6502_device
|
||||
|
||||
class bbc_tube_6502_device :
|
||||
public device_t,
|
||||
public device_bbc_tube_interface
|
||||
{
|
||||
public:
|
||||
// construction/destruction
|
||||
bbc_tube_6502_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
|
||||
|
||||
DECLARE_READ8_MEMBER( read );
|
||||
DECLARE_WRITE8_MEMBER( write );
|
||||
|
||||
protected:
|
||||
// device-level overrides
|
||||
virtual void device_start() override;
|
||||
virtual void device_reset() override;
|
||||
|
||||
// optional information overrides
|
||||
virtual void device_add_mconfig(machine_config &config) override;
|
||||
virtual const tiny_rom_entry *device_rom_region() const override;
|
||||
|
||||
virtual DECLARE_READ8_MEMBER( host_r ) override;
|
||||
virtual DECLARE_WRITE8_MEMBER( host_w ) override;
|
||||
|
||||
private:
|
||||
required_device<cpu_device> m_m6502;
|
||||
required_device<tube_device> m_ula;
|
||||
required_device<ram_device> m_ram;
|
||||
required_memory_region m_rom;
|
||||
|
||||
bool m_rom_enabled;
|
||||
};
|
||||
|
||||
|
||||
// device type definition
|
||||
DECLARE_DEVICE_TYPE(BBC_TUBE_6502, bbc_tube_6502_device)
|
||||
|
||||
|
||||
#endif /* MAME_BUS_BBC_TUBE_6502_H */
|
157
src/devices/bus/bbc/tube/tube_65c102.cpp
Normal file
157
src/devices/bus/bbc/tube/tube_65c102.cpp
Normal file
@ -0,0 +1,157 @@
|
||||
// license:BSD-3-Clause
|
||||
// copyright-holders:Nigel Barnes
|
||||
/**********************************************************************
|
||||
|
||||
Acorn ADC06 65C102 Co-processor
|
||||
|
||||
http://chrisacorns.computinghistory.org.uk/8bit_Upgrades/Acorn_ADC06_65C102CoPro.html
|
||||
|
||||
**********************************************************************/
|
||||
|
||||
|
||||
#include "emu.h"
|
||||
#include "tube_65c102.h"
|
||||
#include "softlist_dev.h"
|
||||
|
||||
|
||||
//**************************************************************************
|
||||
// DEVICE DEFINITIONS
|
||||
//**************************************************************************
|
||||
|
||||
DEFINE_DEVICE_TYPE(BBC_TUBE_65C102, bbc_tube_65c102_device, "bbc_tube_65c102", "Acorn 65C102 Co-Processor")
|
||||
|
||||
|
||||
//-------------------------------------------------
|
||||
// ADDRESS_MAP( tube_6502_mem )
|
||||
//-------------------------------------------------
|
||||
|
||||
static ADDRESS_MAP_START(tube_6502_mem, AS_PROGRAM, 8, bbc_tube_65c102_device)
|
||||
AM_RANGE(0x0000, 0xffff) AM_READWRITE(read, write)
|
||||
ADDRESS_MAP_END
|
||||
|
||||
//-------------------------------------------------
|
||||
// ROM( tube_65c102 )
|
||||
//-------------------------------------------------
|
||||
|
||||
ROM_START( tube_65c102 )
|
||||
ROM_REGION(0x1000, "rom", 0)
|
||||
ROM_LOAD("65C102_BOOT_110.rom", 0x0000, 0x1000, CRC(ad5b70cc) SHA1(0ac9a1c70e55a79e2c81e102afae1d016af229fa)) // 2201,243-02
|
||||
ROM_END
|
||||
|
||||
//-------------------------------------------------
|
||||
// device_add_mconfig - add device configuration
|
||||
//-------------------------------------------------
|
||||
|
||||
MACHINE_CONFIG_MEMBER( bbc_tube_65c102_device::device_add_mconfig )
|
||||
MCFG_CPU_ADD("maincpu", M65C02, XTAL_16MHz / 4)
|
||||
MCFG_CPU_PROGRAM_MAP(tube_6502_mem)
|
||||
|
||||
MCFG_TUBE_ADD("ula")
|
||||
MCFG_TUBE_PNMI_HANDLER(INPUTLINE("maincpu", M65C02_NMI_LINE))
|
||||
MCFG_TUBE_PIRQ_HANDLER(INPUTLINE("maincpu", M65C02_IRQ_LINE))
|
||||
|
||||
/* internal ram */
|
||||
MCFG_RAM_ADD(RAM_TAG)
|
||||
MCFG_RAM_DEFAULT_SIZE("64K")
|
||||
MCFG_RAM_DEFAULT_VALUE(0x00)
|
||||
|
||||
/* software lists */
|
||||
MCFG_SOFTWARE_LIST_ADD("flop_ls_6502", "bbc_flop_6502")
|
||||
MCFG_SOFTWARE_LIST_ADD("flop_ls_65c102", "bbc_flop_65c102")
|
||||
MACHINE_CONFIG_END
|
||||
|
||||
//-------------------------------------------------
|
||||
// rom_region - device-specific ROM region
|
||||
//-------------------------------------------------
|
||||
|
||||
const tiny_rom_entry *bbc_tube_65c102_device::device_rom_region() const
|
||||
{
|
||||
return ROM_NAME( tube_65c102 );
|
||||
}
|
||||
|
||||
//**************************************************************************
|
||||
// LIVE DEVICE
|
||||
//**************************************************************************
|
||||
|
||||
//-------------------------------------------------
|
||||
// bbc_tube_65c102_device - constructor
|
||||
//-------------------------------------------------
|
||||
|
||||
bbc_tube_65c102_device::bbc_tube_65c102_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock)
|
||||
: device_t(mconfig, BBC_TUBE_65C102, tag, owner, clock),
|
||||
device_bbc_tube_interface(mconfig, *this),
|
||||
m_maincpu(*this, "maincpu"),
|
||||
m_ula(*this, "ula"),
|
||||
m_ram(*this, "ram"),
|
||||
m_rom(*this, "rom"),
|
||||
m_rom_enabled(true)
|
||||
{
|
||||
}
|
||||
|
||||
//-------------------------------------------------
|
||||
// device_start - device-specific startup
|
||||
//-------------------------------------------------
|
||||
|
||||
void bbc_tube_65c102_device::device_start()
|
||||
{
|
||||
m_slot = dynamic_cast<bbc_tube_slot_device *>(owner());
|
||||
}
|
||||
|
||||
//-------------------------------------------------
|
||||
// device_reset - device-specific reset
|
||||
//-------------------------------------------------
|
||||
|
||||
void bbc_tube_65c102_device::device_reset()
|
||||
{
|
||||
m_ula->reset();
|
||||
|
||||
m_rom_enabled = true;
|
||||
}
|
||||
|
||||
|
||||
//**************************************************************************
|
||||
// IMPLEMENTATION
|
||||
//**************************************************************************
|
||||
|
||||
READ8_MEMBER(bbc_tube_65c102_device::host_r)
|
||||
{
|
||||
return m_ula->host_r(space, offset);
|
||||
}
|
||||
|
||||
WRITE8_MEMBER(bbc_tube_65c102_device::host_w)
|
||||
{
|
||||
m_ula->host_w(space, offset, data);
|
||||
}
|
||||
|
||||
|
||||
READ8_MEMBER(bbc_tube_65c102_device::read)
|
||||
{
|
||||
uint8_t data;
|
||||
|
||||
if ((offset >= 0xfef0) && (offset <= 0xfeff))
|
||||
{
|
||||
if (!machine().side_effect_disabled()) m_rom_enabled = false;
|
||||
data = m_ula->parasite_r(space, offset);
|
||||
}
|
||||
else if (m_rom_enabled && (offset >= 0xf000))
|
||||
{
|
||||
data = m_rom->base()[offset & 0xfff];
|
||||
}
|
||||
else
|
||||
{
|
||||
data = m_ram->pointer()[offset];
|
||||
}
|
||||
return data;
|
||||
}
|
||||
|
||||
WRITE8_MEMBER(bbc_tube_65c102_device::write)
|
||||
{
|
||||
if ((offset >= 0xfef0) && (offset <= 0xfeff))
|
||||
{
|
||||
m_ula->parasite_w(space, offset, data);
|
||||
}
|
||||
else
|
||||
{
|
||||
m_ram->pointer()[offset] = data;
|
||||
}
|
||||
}
|
64
src/devices/bus/bbc/tube/tube_65c102.h
Normal file
64
src/devices/bus/bbc/tube/tube_65c102.h
Normal file
@ -0,0 +1,64 @@
|
||||
// license:BSD-3-Clause
|
||||
// copyright-holders:Nigel Barnes
|
||||
/**********************************************************************
|
||||
|
||||
Acorn ADC06 65C102 Co-processor
|
||||
|
||||
http://chrisacorns.computinghistory.org.uk/8bit_Upgrades/Acorn_ADC06_65C102CoPro.html
|
||||
|
||||
**********************************************************************/
|
||||
|
||||
|
||||
#ifndef MAME_BUS_BBC_TUBE_65C102_H
|
||||
#define MAME_BUS_BBC_TUBE_65C102_H
|
||||
|
||||
#include "tube.h"
|
||||
#include "cpu/m6502/m65c02.h"
|
||||
#include "machine/ram.h"
|
||||
#include "machine/tube.h"
|
||||
|
||||
//**************************************************************************
|
||||
// TYPE DEFINITIONS
|
||||
//**************************************************************************
|
||||
|
||||
// ======================> bbc_tube_65c102_device
|
||||
|
||||
class bbc_tube_65c102_device :
|
||||
public device_t,
|
||||
public device_bbc_tube_interface
|
||||
{
|
||||
public:
|
||||
// construction/destruction
|
||||
bbc_tube_65c102_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
|
||||
|
||||
DECLARE_READ8_MEMBER( read );
|
||||
DECLARE_WRITE8_MEMBER( write );
|
||||
|
||||
protected:
|
||||
// device-level overrides
|
||||
virtual void device_start() override;
|
||||
virtual void device_reset() override;
|
||||
|
||||
// optional information overrides
|
||||
virtual void device_add_mconfig(machine_config &config) override;
|
||||
virtual const tiny_rom_entry *device_rom_region() const override;
|
||||
|
||||
virtual DECLARE_READ8_MEMBER( host_r ) override;
|
||||
virtual DECLARE_WRITE8_MEMBER( host_w ) override;
|
||||
|
||||
private:
|
||||
required_device<cpu_device> m_maincpu;
|
||||
required_device<tube_device> m_ula;
|
||||
required_device<ram_device> m_ram;
|
||||
required_memory_region m_rom;
|
||||
|
||||
bool m_rom_enabled;
|
||||
};
|
||||
|
||||
|
||||
|
||||
// device type definition
|
||||
DECLARE_DEVICE_TYPE(BBC_TUBE_65C102, bbc_tube_65c102_device)
|
||||
|
||||
|
||||
#endif /* MAME_BUS_BBC_TUBE_65C102_H */
|
139
src/devices/bus/bbc/tube/tube_80186.cpp
Normal file
139
src/devices/bus/bbc/tube/tube_80186.cpp
Normal file
@ -0,0 +1,139 @@
|
||||
// license:BSD-3-Clause
|
||||
// copyright-holders:Nigel Barnes
|
||||
/**********************************************************************
|
||||
|
||||
Acorn ADC08 Intel 80186 Co-processor
|
||||
|
||||
http://chrisacorns.computinghistory.org.uk/8bit_Upgrades/Acorn_ADC08_80186Copro.html
|
||||
|
||||
**********************************************************************/
|
||||
|
||||
|
||||
#include "emu.h"
|
||||
#include "tube_80186.h"
|
||||
#include "softlist_dev.h"
|
||||
|
||||
|
||||
//**************************************************************************
|
||||
// DEVICE DEFINITIONS
|
||||
//**************************************************************************
|
||||
|
||||
DEFINE_DEVICE_TYPE(BBC_TUBE_80186, bbc_tube_80186_device, "bbc_tube_80186", "Acorn 80186 Co-Processor")
|
||||
|
||||
|
||||
//-------------------------------------------------
|
||||
// ADDRESS_MAP( tube_80186_mem )
|
||||
//-------------------------------------------------
|
||||
|
||||
static ADDRESS_MAP_START(tube_80186_mem, AS_PROGRAM, 16, bbc_tube_80186_device)
|
||||
ADDRESS_MAP_UNMAP_HIGH
|
||||
ADDRESS_MAP_END
|
||||
|
||||
//-------------------------------------------------
|
||||
// ADDRESS_MAP( tube_80186_io )
|
||||
//-------------------------------------------------
|
||||
|
||||
static ADDRESS_MAP_START(tube_80186_io, AS_IO, 16, bbc_tube_80186_device)
|
||||
AM_RANGE(0x80, 0x8f) AM_DEVREADWRITE8("ula", tube_device, parasite_r, parasite_w, 0x00ff)
|
||||
ADDRESS_MAP_END
|
||||
|
||||
//-------------------------------------------------
|
||||
// ROM( tube_80186 )
|
||||
//-------------------------------------------------
|
||||
|
||||
ROM_START( tube_80186 )
|
||||
ROM_REGION(0x4000, "bootstrap", 0)
|
||||
ROM_LOAD16_BYTE("M512_LO_IC31.rom", 0x0000, 0x2000, CRC(c0df8707) SHA1(7f6d843d5aea6bdb36cbd4623ae942b16b96069d)) // 2201,287-02
|
||||
ROM_LOAD16_BYTE("M512_HI_IC32.rom", 0x0001, 0x2000, CRC(e47f10b2) SHA1(45dc8d7e7936afbec6de423569d9005a1c350316)) // 2201,288-02
|
||||
ROM_END
|
||||
|
||||
//-------------------------------------------------
|
||||
// device_add_mconfig - add device configuration
|
||||
//-------------------------------------------------
|
||||
|
||||
MACHINE_CONFIG_MEMBER(bbc_tube_80186_device::device_add_mconfig )
|
||||
MCFG_CPU_ADD("i80186", I80186, XTAL_20MHz / 2)
|
||||
MCFG_CPU_PROGRAM_MAP(tube_80186_mem)
|
||||
MCFG_CPU_IO_MAP(tube_80186_io)
|
||||
//MCFG_80186_CHIP_SELECT_CB(WRITE16(bbc_tube_80186_device, chip_select_cb))
|
||||
MCFG_80186_TMROUT0_HANDLER(INPUTLINE("i80186", INPUT_LINE_HALT)) MCFG_DEVCB_INVERT
|
||||
MCFG_80186_TMROUT1_HANDLER(INPUTLINE("i80186", INPUT_LINE_NMI)) MCFG_DEVCB_INVERT
|
||||
|
||||
MCFG_TUBE_ADD("ula")
|
||||
MCFG_TUBE_PIRQ_HANDLER(DEVWRITELINE("i80186", i80186_cpu_device, int0_w))
|
||||
MCFG_TUBE_DRQ_HANDLER(DEVWRITELINE("i80186", i80186_cpu_device, drq0_w))
|
||||
|
||||
/* internal ram */
|
||||
MCFG_RAM_ADD(RAM_TAG)
|
||||
MCFG_RAM_DEFAULT_SIZE("512K")
|
||||
|
||||
/* software lists */
|
||||
MCFG_SOFTWARE_LIST_ADD("flop_ls_80186", "bbc_flop_80186")
|
||||
MACHINE_CONFIG_END
|
||||
|
||||
//-------------------------------------------------
|
||||
// rom_region - device-specific ROM region
|
||||
//-------------------------------------------------
|
||||
|
||||
const tiny_rom_entry *bbc_tube_80186_device::device_rom_region() const
|
||||
{
|
||||
return ROM_NAME( tube_80186 );
|
||||
}
|
||||
|
||||
//**************************************************************************
|
||||
// LIVE DEVICE
|
||||
//**************************************************************************
|
||||
|
||||
//-------------------------------------------------
|
||||
// bbc_tube_80186_device - constructor
|
||||
//-------------------------------------------------
|
||||
|
||||
bbc_tube_80186_device::bbc_tube_80186_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock)
|
||||
: device_t(mconfig, BBC_TUBE_80186, tag, owner, clock),
|
||||
device_bbc_tube_interface(mconfig, *this),
|
||||
m_i80186(*this, "i80186"),
|
||||
m_ula(*this, "ula"),
|
||||
m_ram(*this, "ram"),
|
||||
m_bootstrap(*this, "bootstrap")
|
||||
{
|
||||
}
|
||||
|
||||
//-------------------------------------------------
|
||||
// device_start - device-specific startup
|
||||
//-------------------------------------------------
|
||||
|
||||
void bbc_tube_80186_device::device_start()
|
||||
{
|
||||
m_slot = dynamic_cast<bbc_tube_slot_device *>(owner());
|
||||
}
|
||||
|
||||
//-------------------------------------------------
|
||||
// device_reset - device-specific reset
|
||||
//-------------------------------------------------
|
||||
|
||||
void bbc_tube_80186_device::device_reset()
|
||||
{
|
||||
m_ula->reset();
|
||||
|
||||
address_space &program = m_i80186->space(AS_PROGRAM);
|
||||
|
||||
program.install_ram(0x00000, 0x3ffff, m_ram->pointer());
|
||||
program.install_ram(0x40000, 0x7ffff, m_ram->pointer() + 0x40000);
|
||||
program.install_ram(0x80000, 0xbffff, m_ram->pointer() + 0x40000);
|
||||
program.install_rom(0xc0000, 0xc3fff, 0x3c000, m_bootstrap->base());
|
||||
}
|
||||
|
||||
|
||||
//**************************************************************************
|
||||
// IMPLEMENTATION
|
||||
//**************************************************************************
|
||||
|
||||
READ8_MEMBER(bbc_tube_80186_device::host_r)
|
||||
{
|
||||
return m_ula->host_r(space, offset);
|
||||
}
|
||||
|
||||
WRITE8_MEMBER(bbc_tube_80186_device::host_w)
|
||||
{
|
||||
m_ula->host_w(space, offset, data);
|
||||
}
|
58
src/devices/bus/bbc/tube/tube_80186.h
Normal file
58
src/devices/bus/bbc/tube/tube_80186.h
Normal file
@ -0,0 +1,58 @@
|
||||
// license:BSD-3-Clause
|
||||
// copyright-holders:Nigel Barnes
|
||||
/**********************************************************************
|
||||
|
||||
Acorn ADC08 Intel 80186 Co-processor
|
||||
|
||||
http://chrisacorns.computinghistory.org.uk/8bit_Upgrades/Acorn_ADC08_80186Copro.html
|
||||
|
||||
**********************************************************************/
|
||||
|
||||
|
||||
#ifndef MAME_BUS_BBC_TUBE_80186_H
|
||||
#define MAME_BUS_BBC_TUBE_80186_H
|
||||
|
||||
#include "tube.h"
|
||||
#include "cpu/i86/i186.h"
|
||||
#include "machine/ram.h"
|
||||
#include "machine/tube.h"
|
||||
|
||||
//**************************************************************************
|
||||
// TYPE DEFINITIONS
|
||||
//**************************************************************************
|
||||
|
||||
// ======================> bbc_tube_80186_device
|
||||
|
||||
class bbc_tube_80186_device :
|
||||
public device_t,
|
||||
public device_bbc_tube_interface
|
||||
{
|
||||
public:
|
||||
// construction/destruction
|
||||
bbc_tube_80186_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
|
||||
|
||||
protected:
|
||||
// device-level overrides
|
||||
virtual void device_start() override;
|
||||
virtual void device_reset() override;
|
||||
|
||||
// optional information overrides
|
||||
virtual void device_add_mconfig(machine_config &config) override;
|
||||
virtual const tiny_rom_entry *device_rom_region() const override;
|
||||
|
||||
virtual DECLARE_READ8_MEMBER( host_r ) override;
|
||||
virtual DECLARE_WRITE8_MEMBER( host_w ) override;
|
||||
|
||||
private:
|
||||
required_device<i80186_cpu_device> m_i80186;
|
||||
required_device<tube_device> m_ula;
|
||||
required_device<ram_device> m_ram;
|
||||
required_memory_region m_bootstrap;
|
||||
};
|
||||
|
||||
|
||||
// device type definition
|
||||
DECLARE_DEVICE_TYPE(BBC_TUBE_80186, bbc_tube_80186_device)
|
||||
|
||||
|
||||
#endif /* MAME_BUS_BBC_TUBE_80x86_H */
|
130
src/devices/bus/bbc/tube/tube_casper.cpp
Normal file
130
src/devices/bus/bbc/tube/tube_casper.cpp
Normal file
@ -0,0 +1,130 @@
|
||||
// license:BSD-3-Clause
|
||||
// copyright-holders:Nigel Barnes
|
||||
/**********************************************************************
|
||||
|
||||
Casper 68000 2nd Processor
|
||||
|
||||
**********************************************************************/
|
||||
|
||||
|
||||
#include "emu.h"
|
||||
#include "tube_casper.h"
|
||||
#include "softlist_dev.h"
|
||||
|
||||
|
||||
//**************************************************************************
|
||||
// DEVICE DEFINITIONS
|
||||
//**************************************************************************
|
||||
|
||||
DEFINE_DEVICE_TYPE(BBC_TUBE_CASPER, bbc_tube_casper_device, "bbc_tube_casper", "Casper 68000 2nd Processor")
|
||||
|
||||
|
||||
//-------------------------------------------------
|
||||
// ADDRESS_MAP( tube_casper_mem )
|
||||
//-------------------------------------------------
|
||||
|
||||
static ADDRESS_MAP_START(tube_casper_mem, AS_PROGRAM, 16, bbc_tube_casper_device)
|
||||
AM_RANGE(0x00000, 0x03fff) AM_ROM AM_REGION("casper_rom", 0)
|
||||
AM_RANGE(0x10000, 0x1001f) AM_DEVREADWRITE8("via6522_1",via6522_device, read, write, 0xff)
|
||||
AM_RANGE(0x20000, 0x3ffff) AM_RAM
|
||||
ADDRESS_MAP_END
|
||||
|
||||
//-------------------------------------------------
|
||||
// ROM( tube_casper )
|
||||
//-------------------------------------------------
|
||||
|
||||
ROM_START( tube_casper )
|
||||
ROM_REGION(0x4000, "casper_rom", 0)
|
||||
ROM_LOAD16_BYTE("casper.ic9", 0x0000, 0x2000, CRC(4105cbf4) SHA1(a3efeb6fb144da55b47c718239967ed0af4fff72))
|
||||
ROM_LOAD16_BYTE("casper.ic10", 0x0001, 0x2000, CRC(f25bc320) SHA1(297db56283bb3164c31c21331837213cea426837))
|
||||
|
||||
ROM_REGION(0x8000, "host_rom", 0)
|
||||
ROM_LOAD("rom1.rom", 0x0000, 0x4000, CRC(602b6a36) SHA1(7b24746dbcacb8772468532e92832d5c7f6648fd))
|
||||
ROM_LOAD("rom2.rom", 0x4000, 0x4000, CRC(7c9efb43) SHA1(4195ce1ed928178fd645a267872a5b4f325d078a))
|
||||
ROM_END
|
||||
|
||||
//-------------------------------------------------
|
||||
// device_add_mconfig - add device configuration
|
||||
//-------------------------------------------------
|
||||
|
||||
MACHINE_CONFIG_MEMBER(bbc_tube_casper_device::device_add_mconfig )
|
||||
MCFG_CPU_ADD("m68000", M68000, 8000000)
|
||||
MCFG_CPU_PROGRAM_MAP(tube_casper_mem)
|
||||
|
||||
MCFG_DEVICE_ADD("via6522_0", VIA6522, 2000000)
|
||||
MCFG_VIA6522_WRITEPB_HANDLER(DEVWRITE8("via6522_1", via6522_device, write_pa))
|
||||
MCFG_VIA6522_CA2_HANDLER(DEVWRITELINE("via6522_1", via6522_device, write_cb1))
|
||||
MCFG_VIA6522_CB2_HANDLER(DEVWRITELINE("via6522_1", via6522_device, write_ca1))
|
||||
MCFG_VIA6522_IRQ_HANDLER(DEVWRITELINE(DEVICE_SELF_OWNER, bbc_tube_slot_device, irq_w))
|
||||
|
||||
MCFG_DEVICE_ADD("via6522_1", VIA6522, 2000000)
|
||||
MCFG_VIA6522_WRITEPB_HANDLER(DEVWRITE8("via6522_0", via6522_device, write_pa))
|
||||
MCFG_VIA6522_CA2_HANDLER(DEVWRITELINE("via6522_0", via6522_device, write_cb1))
|
||||
MCFG_VIA6522_CB2_HANDLER(DEVWRITELINE("via6522_0", via6522_device, write_ca1))
|
||||
MCFG_VIA6522_IRQ_HANDLER(INPUTLINE("maincpu", M68K_IRQ_1))
|
||||
|
||||
/* software lists */
|
||||
MCFG_SOFTWARE_LIST_ADD("flop_ls_casper", "bbc_flop_68000")
|
||||
MACHINE_CONFIG_END
|
||||
|
||||
//-------------------------------------------------
|
||||
// rom_region - device-specific ROM region
|
||||
//-------------------------------------------------
|
||||
|
||||
const tiny_rom_entry *bbc_tube_casper_device::device_rom_region() const
|
||||
{
|
||||
return ROM_NAME( tube_casper );
|
||||
}
|
||||
|
||||
//**************************************************************************
|
||||
// LIVE DEVICE
|
||||
//**************************************************************************
|
||||
|
||||
//-------------------------------------------------
|
||||
// bbc_tube_casper_device - constructor
|
||||
//-------------------------------------------------
|
||||
|
||||
bbc_tube_casper_device::bbc_tube_casper_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock)
|
||||
: device_t(mconfig, BBC_TUBE_CASPER, tag, owner, clock),
|
||||
device_bbc_tube_interface(mconfig, *this),
|
||||
m_m68000(*this, "m68000"),
|
||||
m_via6522_0(*this, "via6522_0"),
|
||||
m_via6522_1(*this, "via6522_1"),
|
||||
m_casper_rom(*this, "casper_rom"),
|
||||
m_host_rom(*this, "host_rom")
|
||||
{
|
||||
}
|
||||
|
||||
//-------------------------------------------------
|
||||
// device_start - device-specific startup
|
||||
//-------------------------------------------------
|
||||
|
||||
void bbc_tube_casper_device::device_start()
|
||||
{
|
||||
m_slot = dynamic_cast<bbc_tube_slot_device *>(owner());
|
||||
}
|
||||
|
||||
//-------------------------------------------------
|
||||
// device_reset - device-specific reset
|
||||
//-------------------------------------------------
|
||||
|
||||
void bbc_tube_casper_device::device_reset()
|
||||
{
|
||||
machine().root_device().membank("bank4")->configure_entry(13, memregion("host_rom")->base() + 0x0000);
|
||||
machine().root_device().membank("bank4")->configure_entry(14, memregion("host_rom")->base() + 0x4000);
|
||||
}
|
||||
|
||||
|
||||
//**************************************************************************
|
||||
// IMPLEMENTATION
|
||||
//**************************************************************************
|
||||
|
||||
READ8_MEMBER(bbc_tube_casper_device::host_r)
|
||||
{
|
||||
return m_via6522_0->read(space, offset & 0xf);
|
||||
}
|
||||
|
||||
WRITE8_MEMBER(bbc_tube_casper_device::host_w)
|
||||
{
|
||||
m_via6522_0->write(space, offset & 0xf, data);
|
||||
}
|
56
src/devices/bus/bbc/tube/tube_casper.h
Normal file
56
src/devices/bus/bbc/tube/tube_casper.h
Normal file
@ -0,0 +1,56 @@
|
||||
// license:BSD-3-Clause
|
||||
// copyright-holders:Nigel Barnes
|
||||
/**********************************************************************
|
||||
|
||||
Casper 68000 2nd Processor
|
||||
|
||||
**********************************************************************/
|
||||
|
||||
|
||||
#ifndef MAME_BUS_BBC_TUBE_CASPER_H
|
||||
#define MAME_BUS_BBC_TUBE_CASPER_H
|
||||
|
||||
#include "tube.h"
|
||||
#include "cpu/m68000/m68000.h"
|
||||
#include "machine/6522via.h"
|
||||
|
||||
//**************************************************************************
|
||||
// TYPE DEFINITIONS
|
||||
//**************************************************************************
|
||||
|
||||
// ======================> bbc_tube_casper_device
|
||||
|
||||
class bbc_tube_casper_device :
|
||||
public device_t,
|
||||
public device_bbc_tube_interface
|
||||
{
|
||||
public:
|
||||
// construction/destruction
|
||||
bbc_tube_casper_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
|
||||
|
||||
protected:
|
||||
// device-level overrides
|
||||
virtual void device_start() override;
|
||||
virtual void device_reset() override;
|
||||
|
||||
// optional information overrides
|
||||
virtual void device_add_mconfig(machine_config &config) override;
|
||||
virtual const tiny_rom_entry *device_rom_region() const override;
|
||||
|
||||
virtual DECLARE_READ8_MEMBER( host_r ) override;
|
||||
virtual DECLARE_WRITE8_MEMBER( host_w ) override;
|
||||
|
||||
private:
|
||||
required_device<cpu_device> m_m68000;
|
||||
required_device<via6522_device> m_via6522_0;
|
||||
required_device<via6522_device> m_via6522_1;
|
||||
required_memory_region m_casper_rom;
|
||||
required_memory_region m_host_rom;
|
||||
};
|
||||
|
||||
|
||||
// device type definition
|
||||
DECLARE_DEVICE_TYPE(BBC_TUBE_CASPER, bbc_tube_casper_device)
|
||||
|
||||
|
||||
#endif /* MAME_BUS_BBC_TUBE_CASPER_H */
|
187
src/devices/bus/bbc/tube/tube_z80.cpp
Normal file
187
src/devices/bus/bbc/tube/tube_z80.cpp
Normal file
@ -0,0 +1,187 @@
|
||||
// license:BSD-3-Clause
|
||||
// copyright-holders:Nigel Barnes
|
||||
/**********************************************************************
|
||||
|
||||
Acorn ANC04 Z80 2nd processor
|
||||
|
||||
http://chrisacorns.computinghistory.org.uk/8bit_Upgrades/Acorn_ANC04_Z802ndproc.html
|
||||
|
||||
**********************************************************************/
|
||||
|
||||
|
||||
#include "emu.h"
|
||||
#include "tube_z80.h"
|
||||
#include "softlist_dev.h"
|
||||
|
||||
|
||||
//**************************************************************************
|
||||
// DEVICE DEFINITIONS
|
||||
//**************************************************************************
|
||||
|
||||
DEFINE_DEVICE_TYPE(BBC_TUBE_Z80, bbc_tube_z80_device, "bbc_tube_z80", "Acorn Z80 2nd Processor")
|
||||
|
||||
|
||||
//-------------------------------------------------
|
||||
// ADDRESS_MAP( tube_z80_mem )
|
||||
//-------------------------------------------------
|
||||
|
||||
static ADDRESS_MAP_START(tube_z80_mem, AS_PROGRAM, 8, bbc_tube_z80_device)
|
||||
AM_RANGE(0x0000, 0xffff) AM_READWRITE(mem_r, mem_w)
|
||||
ADDRESS_MAP_END
|
||||
|
||||
//-------------------------------------------------
|
||||
// ADDRESS_MAP( tube_z80_io )
|
||||
//-------------------------------------------------
|
||||
|
||||
static ADDRESS_MAP_START(tube_z80_io, AS_IO, 8, bbc_tube_z80_device)
|
||||
AM_RANGE(0x00, 0x07) AM_MIRROR(0xff00) AM_READWRITE(io_r, io_w)
|
||||
ADDRESS_MAP_END
|
||||
|
||||
//-------------------------------------------------
|
||||
// ROM( tube_z80 )
|
||||
//-------------------------------------------------
|
||||
|
||||
ROM_START( tube_z80 )
|
||||
ROM_REGION(0x1000, "rom", 0)
|
||||
ROM_LOAD("Z80_120.rom", 0x0000, 0x1000, CRC(315bfc20) SHA1(069077df498599a9c880d4ec9f4bc53fcc602d82))
|
||||
ROM_END
|
||||
|
||||
//-------------------------------------------------
|
||||
// device_add_mconfig - add device configuration
|
||||
//-------------------------------------------------
|
||||
|
||||
MACHINE_CONFIG_MEMBER( bbc_tube_z80_device::device_add_mconfig )
|
||||
MCFG_CPU_ADD("z80", Z80, XTAL_12MHz / 2)
|
||||
MCFG_CPU_PROGRAM_MAP(tube_z80_mem)
|
||||
MCFG_CPU_IO_MAP(tube_z80_io)
|
||||
MCFG_CPU_IRQ_ACKNOWLEDGE_DEVICE(DEVICE_SELF, bbc_tube_z80_device, irq_callback)
|
||||
|
||||
MCFG_TUBE_ADD("ula")
|
||||
MCFG_TUBE_HIRQ_HANDLER(DEVWRITELINE(DEVICE_SELF_OWNER, bbc_tube_slot_device, irq_w))
|
||||
MCFG_TUBE_PNMI_HANDLER(WRITELINE(bbc_tube_z80_device, nmi_w))
|
||||
MCFG_TUBE_PIRQ_HANDLER(INPUTLINE("z80", INPUT_LINE_IRQ0))
|
||||
|
||||
/* internal ram */
|
||||
MCFG_RAM_ADD(RAM_TAG)
|
||||
MCFG_RAM_DEFAULT_SIZE("64K")
|
||||
MCFG_RAM_DEFAULT_VALUE(0x00)
|
||||
|
||||
/* software lists */
|
||||
MCFG_SOFTWARE_LIST_ADD("flop_ls_z80", "bbc_flop_z80")
|
||||
MACHINE_CONFIG_END
|
||||
|
||||
//-------------------------------------------------
|
||||
// rom_region - device-specific ROM region
|
||||
//-------------------------------------------------
|
||||
|
||||
const tiny_rom_entry *bbc_tube_z80_device::device_rom_region() const
|
||||
{
|
||||
return ROM_NAME( tube_z80 );
|
||||
}
|
||||
|
||||
//**************************************************************************
|
||||
// LIVE DEVICE
|
||||
//**************************************************************************
|
||||
|
||||
//-------------------------------------------------
|
||||
// bbc_tube_z80_device - constructor
|
||||
//-------------------------------------------------
|
||||
|
||||
bbc_tube_z80_device::bbc_tube_z80_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock)
|
||||
: device_t(mconfig, BBC_TUBE_Z80, tag, owner, clock),
|
||||
device_bbc_tube_interface(mconfig, *this),
|
||||
m_z80(*this, "z80"),
|
||||
m_ula(*this, "ula"),
|
||||
m_ram(*this, "ram"),
|
||||
m_rom(*this, "rom"),
|
||||
m_rom_enabled(true)
|
||||
{
|
||||
}
|
||||
|
||||
//-------------------------------------------------
|
||||
// device_start - device-specific startup
|
||||
//-------------------------------------------------
|
||||
|
||||
void bbc_tube_z80_device::device_start()
|
||||
{
|
||||
m_slot = dynamic_cast<bbc_tube_slot_device *>(owner());
|
||||
}
|
||||
|
||||
//-------------------------------------------------
|
||||
// device_reset - device-specific reset
|
||||
//-------------------------------------------------
|
||||
|
||||
void bbc_tube_z80_device::device_reset()
|
||||
{
|
||||
m_ula->reset();
|
||||
|
||||
m_rom_enabled = true;
|
||||
}
|
||||
|
||||
|
||||
//**************************************************************************
|
||||
// IMPLEMENTATION
|
||||
//**************************************************************************
|
||||
|
||||
READ8_MEMBER(bbc_tube_z80_device::host_r)
|
||||
{
|
||||
return m_ula->host_r(space, offset);
|
||||
}
|
||||
|
||||
WRITE8_MEMBER(bbc_tube_z80_device::host_w)
|
||||
{
|
||||
m_ula->host_w(space, offset, data);
|
||||
}
|
||||
|
||||
|
||||
READ8_MEMBER(bbc_tube_z80_device::mem_r)
|
||||
{
|
||||
uint8_t data;
|
||||
|
||||
//if (!machine().side_effect_disabled() && m_nmiserv && offset == 0x0066) m_rom_enabled = true;
|
||||
if (!machine().side_effect_disabled() && offset == 0x0066) m_rom_enabled = true;
|
||||
if (!machine().side_effect_disabled() && offset >= 0x8000) m_rom_enabled = false;
|
||||
|
||||
if (m_rom_enabled && (offset < 0x1000))
|
||||
data = m_rom->base()[offset & 0xfff];
|
||||
else
|
||||
data = m_ram->pointer()[offset];
|
||||
|
||||
return data;
|
||||
}
|
||||
|
||||
WRITE8_MEMBER(bbc_tube_z80_device::mem_w)
|
||||
{
|
||||
m_ram->pointer()[offset] = data;
|
||||
}
|
||||
|
||||
|
||||
READ8_MEMBER(bbc_tube_z80_device::io_r)
|
||||
{
|
||||
if (!machine().side_effect_disabled() && (offset == 2)) m_rom_enabled = true;
|
||||
if (!machine().side_effect_disabled() && (offset == 6)) m_rom_enabled = false;
|
||||
|
||||
return m_ula->parasite_r(space, offset);
|
||||
}
|
||||
|
||||
WRITE8_MEMBER(bbc_tube_z80_device::io_w)
|
||||
{
|
||||
m_ula->parasite_w(space, offset, data);
|
||||
}
|
||||
|
||||
|
||||
WRITE_LINE_MEMBER(bbc_tube_z80_device::nmi_w)
|
||||
{
|
||||
//m_nmiserv = state;
|
||||
m_z80->set_input_line(INPUT_LINE_NMI, state);
|
||||
}
|
||||
|
||||
|
||||
//-------------------------------------------------
|
||||
// irq vector callback
|
||||
//-------------------------------------------------
|
||||
|
||||
IRQ_CALLBACK_MEMBER(bbc_tube_z80_device::irq_callback)
|
||||
{
|
||||
return 0xfe;
|
||||
}
|
69
src/devices/bus/bbc/tube/tube_z80.h
Normal file
69
src/devices/bus/bbc/tube/tube_z80.h
Normal file
@ -0,0 +1,69 @@
|
||||
// license:BSD-3-Clause
|
||||
// copyright-holders:Nigel Barnes
|
||||
/**********************************************************************
|
||||
|
||||
Acorn ANC04 Z80 2nd processor
|
||||
|
||||
http://chrisacorns.computinghistory.org.uk/8bit_Upgrades/Acorn_ANC04_Z802ndproc.html
|
||||
|
||||
**********************************************************************/
|
||||
|
||||
|
||||
#ifndef MAME_BUS_BBC_TUBE_Z80_H
|
||||
#define MAME_BUS_BBC_TUBE_Z80_H
|
||||
|
||||
#include "tube.h"
|
||||
#include "cpu/z80/z80.h"
|
||||
#include "machine/ram.h"
|
||||
#include "machine/tube.h"
|
||||
|
||||
//**************************************************************************
|
||||
// TYPE DEFINITIONS
|
||||
//**************************************************************************
|
||||
|
||||
// ======================> bbc_tube_z80_device
|
||||
|
||||
class bbc_tube_z80_device :
|
||||
public device_t,
|
||||
public device_bbc_tube_interface
|
||||
{
|
||||
public:
|
||||
// construction/destruction
|
||||
bbc_tube_z80_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
|
||||
|
||||
DECLARE_READ8_MEMBER( mem_r );
|
||||
DECLARE_WRITE8_MEMBER( mem_w );
|
||||
DECLARE_READ8_MEMBER( io_r );
|
||||
DECLARE_WRITE8_MEMBER( io_w );
|
||||
|
||||
protected:
|
||||
// device-level overrides
|
||||
virtual void device_start() override;
|
||||
virtual void device_reset() override;
|
||||
|
||||
// optional information overrides
|
||||
virtual void device_add_mconfig(machine_config &config) override;
|
||||
virtual const tiny_rom_entry *device_rom_region() const override;
|
||||
|
||||
virtual DECLARE_READ8_MEMBER( host_r ) override;
|
||||
virtual DECLARE_WRITE8_MEMBER( host_w ) override;
|
||||
|
||||
private:
|
||||
IRQ_CALLBACK_MEMBER( irq_callback );
|
||||
DECLARE_WRITE_LINE_MEMBER( nmi_w );
|
||||
|
||||
required_device<cpu_device> m_z80;
|
||||
required_device<tube_device> m_ula;
|
||||
required_device<ram_device> m_ram;
|
||||
required_memory_region m_rom;
|
||||
|
||||
bool m_rom_enabled;
|
||||
int m_nmiserv;
|
||||
};
|
||||
|
||||
|
||||
// device type definition
|
||||
DECLARE_DEVICE_TYPE(BBC_TUBE_Z80, bbc_tube_z80_device)
|
||||
|
||||
|
||||
#endif /* MAME_BUS_BBC_TUBE_Z80_H */
|
@ -59,6 +59,7 @@
|
||||
/* Devices */
|
||||
#include "formats/acorn_dsk.h"
|
||||
#include "formats/fsd_dsk.h"
|
||||
#include "formats/pc_dsk.h"
|
||||
#include "imagedev/cassette.h"
|
||||
#include "formats/uef_cas.h"
|
||||
#include "formats/csw_cas.h"
|
||||
@ -189,7 +190,7 @@ static ADDRESS_MAP_START( bbc_base, AS_PROGRAM, 8, bbc_state )
|
||||
/* fe80-fe9f FDC Floppy disc controller */
|
||||
AM_RANGE(0xfea0, 0xfebf) AM_DEVREADWRITE("mc6854", mc6854_device, read, write) /* fea0-febf 68B54 ADLC ECONET controller */
|
||||
AM_RANGE(0xfec0, 0xfedf) AM_DEVREADWRITE("upd7002", upd7002_device, read, write) /* fec0-fedf uPD7002 Analogue to digital converter */
|
||||
AM_RANGE(0xfee0, 0xfeff) AM_READ(bbc_fe_r) /* fee0-feff Tube ULA Tube system interface */
|
||||
AM_RANGE(0xfee0, 0xfeff) AM_DEVREADWRITE("tube", bbc_tube_slot_device, host_r, host_w) /* fee0-feff Tube ULA Tube system interface */
|
||||
AM_RANGE(0xff00, 0xffff) AM_ROM AM_REGION("os", 0x3f00) /* ff00-ffff OS ROM (continued) */
|
||||
ADDRESS_MAP_END
|
||||
|
||||
@ -226,6 +227,7 @@ static ADDRESS_MAP_START( bbcbp_mem, AS_PROGRAM, 8, bbc_state )
|
||||
/* W: fe30-fe3f 84LS161 Paged ROM selector */
|
||||
AM_RANGE(0xfe80, 0xfe83) AM_WRITE(bbc_wd1770_status_w) /* fe80-fe83 1770 FDC Drive control register */
|
||||
AM_RANGE(0xfe84, 0xfe9f) AM_DEVREADWRITE("wd1770", wd1770_device, read, write) /* fe84-fe9f 1770 FDC Floppy disc controller */
|
||||
AM_RANGE(0xfee0, 0xfeff) AM_DEVREADWRITE("tube", bbc_tube_slot_device, host_r, host_w) /* fee0-feff Tube ULA Tube system interface */
|
||||
AM_IMPORT_FROM(bbc_base)
|
||||
ADDRESS_MAP_END
|
||||
|
||||
@ -239,6 +241,7 @@ static ADDRESS_MAP_START( bbcbp128_mem, AS_PROGRAM, 8, bbc_state )
|
||||
/* W: fe30-fe3f 84LS161 Paged ROM selector */
|
||||
AM_RANGE(0xfe80, 0xfe83) AM_WRITE(bbc_wd1770_status_w) /* fe80-fe83 1770 FDC Drive control register */
|
||||
AM_RANGE(0xfe84, 0xfe9f) AM_DEVREADWRITE("wd1770", wd1770_device, read, write) /* fe84-fe9f 1770 FDC Floppy disc controller */
|
||||
AM_RANGE(0xfee0, 0xfeff) AM_DEVREADWRITE("tube", bbc_tube_slot_device, host_r, host_w) /* fee0-feff Tube ULA Tube system interface */
|
||||
AM_IMPORT_FROM(bbc_base)
|
||||
ADDRESS_MAP_END
|
||||
|
||||
@ -252,6 +255,7 @@ static ADDRESS_MAP_START( reutapm_mem, AS_PROGRAM, 8, bbc_state )
|
||||
/* W: fe30-fe3f 84LS161 Paged ROM selector */
|
||||
AM_RANGE(0xfe80, 0xfe83) AM_NOP /* fe80-fe83 1770 FDC Drive control register */
|
||||
AM_RANGE(0xfe84, 0xfe9f) AM_NOP /* fe84-fe9f 1770 FDC Floppy disc controller */
|
||||
AM_RANGE(0xfee0, 0xfeff) AM_READ(bbc_fe_r) /* fee0-feff Tube ULA Tube system interface */
|
||||
AM_IMPORT_FROM(bbc_base)
|
||||
ADDRESS_MAP_END
|
||||
|
||||
@ -303,6 +307,9 @@ INPUT_CHANGED_MEMBER(bbc_state::trigger_reset)
|
||||
if (m_fdc) m_fdc->reset();
|
||||
if (m_i8271) m_i8271->reset();
|
||||
if (m_1mhzbus) m_1mhzbus->reset();
|
||||
if (m_tube) m_tube->reset();
|
||||
if (m_intube) m_intube->reset();
|
||||
if (m_extube) m_extube->reset();
|
||||
}
|
||||
}
|
||||
|
||||
@ -780,7 +787,8 @@ FLOPPY_FORMATS_MEMBER( bbc_state::floppy_formats_bbcm )
|
||||
FLOPPY_OPUS_DDCPM_FORMAT,
|
||||
FLOPPY_TORCH_CPN_FORMAT,
|
||||
FLOPPY_ACORN_DOS_FORMAT,
|
||||
FLOPPY_FSD_FORMAT
|
||||
FLOPPY_FSD_FORMAT,
|
||||
FLOPPY_PC_FORMAT
|
||||
FLOPPY_FORMATS_END0
|
||||
|
||||
FLOPPY_FORMATS_MEMBER( bbc_state::floppy_formats_bbcmc )
|
||||
@ -990,7 +998,8 @@ static MACHINE_CONFIG_DERIVED( bbcb, bbca )
|
||||
MCFG_BBC_1MHZBUS_SLOT_NMI_HANDLER(WRITELINE(bbc_state, bus_nmi_w))
|
||||
|
||||
/* tube port */
|
||||
MCFG_BBC_TUBE_SLOT_ADD("tube", bbc_tube_ext_devices, nullptr)
|
||||
MCFG_BBC_TUBE_SLOT_ADD("tube", bbc_extube_devices, nullptr)
|
||||
MCFG_BBC_TUBE_SLOT_IRQ_HANDLER(DEVWRITELINE("irqs", input_merger_device, in_w<4>))
|
||||
|
||||
/* user port */
|
||||
MCFG_BBC_USERPORT_SLOT_ADD("userport", bbc_userport_devices, nullptr)
|
||||
@ -999,10 +1008,6 @@ static MACHINE_CONFIG_DERIVED( bbcb, bbca )
|
||||
MCFG_SOFTWARE_LIST_ADD("cass_ls_b", "bbcb_cass")
|
||||
MCFG_SOFTWARE_LIST_ADD("flop_ls_b", "bbcb_flop")
|
||||
MCFG_SOFTWARE_LIST_ADD("flop_ls_b_orig", "bbcb_flop_orig")
|
||||
MCFG_SOFTWARE_LIST_ADD("flop_ls_z80", "bbc_flop_z80")
|
||||
MCFG_SOFTWARE_LIST_ADD("flop_ls_32016", "bbc_flop_32016")
|
||||
MCFG_SOFTWARE_LIST_ADD("flop_ls_68000", "bbc_flop_68000")
|
||||
MCFG_SOFTWARE_LIST_ADD("flop_ls_6502", "bbc_flop_6502")
|
||||
MACHINE_CONFIG_END
|
||||
|
||||
|
||||
@ -1111,13 +1116,9 @@ static MACHINE_CONFIG_DERIVED( torchf, bbcb )
|
||||
MCFG_FLOPPY_DRIVE_SOUND(true)
|
||||
|
||||
/* Add Torch Z80 Communicator co-processor */
|
||||
|
||||
/* software lists */
|
||||
MCFG_SOFTWARE_LIST_ADD("flop_ls_torch", "bbc_flop_torch")
|
||||
MCFG_SOFTWARE_LIST_REMOVE("flop_ls_z80")
|
||||
MCFG_SOFTWARE_LIST_REMOVE("flop_ls_32016")
|
||||
MCFG_SOFTWARE_LIST_REMOVE("flop_ls_68000")
|
||||
MCFG_SOFTWARE_LIST_REMOVE("flop_ls_6502")
|
||||
//MCFG_DEVICE_MODIFY("tube")
|
||||
//MCFG_SLOT_DEFAULT_OPTION("zep100")
|
||||
//MCFG_SLOT_FIXED(true)
|
||||
MACHINE_CONFIG_END
|
||||
|
||||
|
||||
@ -1151,9 +1152,9 @@ static MACHINE_CONFIG_DERIVED( abc110, bbcbp )
|
||||
MCFG_DEVICE_REMOVE("wd1770:1")
|
||||
|
||||
/* Add Z80 co-processor */
|
||||
//MCFG_DEVICE_MODIFY("tube")
|
||||
//MCFG_SLOT_DEFAULT_OPTION("z80")
|
||||
//MCFG_SLOT_FIXED(true)
|
||||
MCFG_DEVICE_MODIFY("tube")
|
||||
MCFG_SLOT_DEFAULT_OPTION("z80")
|
||||
MCFG_SLOT_FIXED(true)
|
||||
|
||||
/* Add ADAPTEC ACB-4000 Winchester Disc Controller */
|
||||
//MCFG_DEVICE_ADD(SCSIBUS_TAG, SCSI_PORT, 0)
|
||||
@ -1175,9 +1176,6 @@ static MACHINE_CONFIG_DERIVED( abc110, bbcbp )
|
||||
MCFG_SOFTWARE_LIST_REMOVE("cass_ls_b")
|
||||
MCFG_SOFTWARE_LIST_REMOVE("flop_ls_b")
|
||||
MCFG_SOFTWARE_LIST_REMOVE("flop_ls_b_orig")
|
||||
MCFG_SOFTWARE_LIST_REMOVE("flop_ls_32016")
|
||||
MCFG_SOFTWARE_LIST_REMOVE("flop_ls_68000")
|
||||
MCFG_SOFTWARE_LIST_REMOVE("flop_ls_6502")
|
||||
MACHINE_CONFIG_END
|
||||
|
||||
|
||||
@ -1197,13 +1195,11 @@ static MACHINE_CONFIG_DERIVED( acw443, bbcbp )
|
||||
/* Add 20MB ST-412 Winchester Cambridge */
|
||||
|
||||
/* software lists */
|
||||
MCFG_SOFTWARE_LIST_ADD("flop_ls_32016", "bbc_flop_32016")
|
||||
MCFG_SOFTWARE_LIST_REMOVE("cass_ls_a")
|
||||
MCFG_SOFTWARE_LIST_REMOVE("cass_ls_b")
|
||||
MCFG_SOFTWARE_LIST_REMOVE("flop_ls_b")
|
||||
MCFG_SOFTWARE_LIST_REMOVE("flop_ls_b_orig")
|
||||
MCFG_SOFTWARE_LIST_REMOVE("flop_ls_z80")
|
||||
MCFG_SOFTWARE_LIST_REMOVE("flop_ls_68000")
|
||||
MCFG_SOFTWARE_LIST_REMOVE("flop_ls_6502")
|
||||
MACHINE_CONFIG_END
|
||||
|
||||
|
||||
@ -1224,10 +1220,6 @@ static MACHINE_CONFIG_DERIVED( abc310, bbcbp )
|
||||
MCFG_SOFTWARE_LIST_REMOVE("cass_ls_a")
|
||||
MCFG_SOFTWARE_LIST_REMOVE("cass_ls_b")
|
||||
MCFG_SOFTWARE_LIST_REMOVE("flop_ls_b")
|
||||
MCFG_SOFTWARE_LIST_REMOVE("flop_ls_z80")
|
||||
MCFG_SOFTWARE_LIST_REMOVE("flop_ls_32016")
|
||||
MCFG_SOFTWARE_LIST_REMOVE("flop_ls_68000")
|
||||
MCFG_SOFTWARE_LIST_REMOVE("flop_ls_6502")
|
||||
MACHINE_CONFIG_END
|
||||
|
||||
|
||||
@ -1260,10 +1252,6 @@ static MACHINE_CONFIG_DERIVED( reutapm, bbcbp )
|
||||
MCFG_SOFTWARE_LIST_REMOVE("cass_ls_b")
|
||||
MCFG_SOFTWARE_LIST_REMOVE("flop_ls_b")
|
||||
MCFG_SOFTWARE_LIST_REMOVE("flop_ls_b_orig")
|
||||
MCFG_SOFTWARE_LIST_REMOVE("flop_ls_z80")
|
||||
MCFG_SOFTWARE_LIST_REMOVE("flop_ls_32016")
|
||||
MCFG_SOFTWARE_LIST_REMOVE("flop_ls_68000")
|
||||
MCFG_SOFTWARE_LIST_REMOVE("flop_ls_6502")
|
||||
|
||||
/* expansion ports */
|
||||
MCFG_DEVICE_REMOVE("analogue")
|
||||
@ -1382,9 +1370,6 @@ static MACHINE_CONFIG_START( bbcm )
|
||||
MCFG_SOFTWARE_LIST_ADD("cass_ls_m", "bbcm_cass")
|
||||
MCFG_SOFTWARE_LIST_ADD("flop_ls_m", "bbcm_flop")
|
||||
MCFG_SOFTWARE_LIST_ADD("cart_ls_m", "bbcm_cart")
|
||||
MCFG_SOFTWARE_LIST_ADD("flop_ls_z80", "bbc_flop_z80")
|
||||
MCFG_SOFTWARE_LIST_ADD("flop_ls_32016", "bbc_flop_32016")
|
||||
MCFG_SOFTWARE_LIST_ADD("flop_ls_68000", "bbc_flop_68000")
|
||||
MCFG_SOFTWARE_LIST_COMPATIBLE_ADD("cass_ls_a", "bbca_cass")
|
||||
MCFG_SOFTWARE_LIST_COMPATIBLE_ADD("cass_ls_b", "bbcb_cass")
|
||||
MCFG_SOFTWARE_LIST_COMPATIBLE_ADD("flop_ls_b", "bbcb_flop")
|
||||
@ -1453,8 +1438,10 @@ static MACHINE_CONFIG_START( bbcm )
|
||||
MCFG_BBC_1MHZBUS_SLOT_NMI_HANDLER(WRITELINE(bbc_state, bus_nmi_w))
|
||||
|
||||
/* tube ports */
|
||||
MCFG_BBC_TUBE_SLOT_ADD("tube_ext", bbc_tube_ext_devices, nullptr)
|
||||
MCFG_BBC_TUBE_SLOT_ADD("tube_int", bbc_tube_int_devices, nullptr)
|
||||
MCFG_BBC_TUBE_SLOT_ADD("intube", bbc_intube_devices, nullptr)
|
||||
MCFG_BBC_TUBE_SLOT_IRQ_HANDLER(DEVWRITELINE("irqs", input_merger_device, in_w<4>))
|
||||
MCFG_BBC_TUBE_SLOT_ADD("extube", bbc_extube_devices, nullptr)
|
||||
MCFG_BBC_TUBE_SLOT_IRQ_HANDLER(DEVWRITELINE("irqs", input_merger_device, in_w<5>))
|
||||
|
||||
/* user port */
|
||||
MCFG_BBC_USERPORT_SLOT_ADD("userport", bbc_userport_devices, nullptr)
|
||||
@ -1463,20 +1450,17 @@ MACHINE_CONFIG_END
|
||||
|
||||
static MACHINE_CONFIG_DERIVED( bbcmt, bbcm )
|
||||
/* Add 65C102 co-processor */
|
||||
//MCFG_DEVICE_MODIFY("tube_int")
|
||||
//MCFG_SLOT_DEFAULT_OPTION("65c102copro")
|
||||
//MCFG_SLOT_FIXED(true)
|
||||
|
||||
/* software lists */
|
||||
MCFG_SOFTWARE_LIST_ADD("flop_ls_65c102", "bbc_flop_65c102")
|
||||
MCFG_DEVICE_MODIFY("intube")
|
||||
MCFG_SLOT_DEFAULT_OPTION("65c102")
|
||||
MCFG_SLOT_FIXED(true)
|
||||
MACHINE_CONFIG_END
|
||||
|
||||
|
||||
static MACHINE_CONFIG_DERIVED( bbcmaiv, bbcm )
|
||||
/* Add 65C102 co-processor */
|
||||
//MCFG_DEVICE_MODIFY("intube")
|
||||
//MCFG_SLOT_DEFAULT_OPTION("65c102")
|
||||
//MCFG_SLOT_FIXED(true)
|
||||
MCFG_DEVICE_MODIFY("intube")
|
||||
MCFG_SLOT_DEFAULT_OPTION("65c102")
|
||||
MCFG_SLOT_FIXED(true)
|
||||
|
||||
/* Add Philips VP415 Laserdisc player */
|
||||
|
||||
@ -1499,9 +1483,6 @@ static MACHINE_CONFIG_DERIVED( bbcmet, bbcm )
|
||||
MCFG_SOFTWARE_LIST_REMOVE("flop_ls_m")
|
||||
MCFG_SOFTWARE_LIST_REMOVE("flop_ls_b")
|
||||
MCFG_SOFTWARE_LIST_REMOVE("flop_ls_b_orig")
|
||||
MCFG_SOFTWARE_LIST_REMOVE("flop_ls_z80")
|
||||
MCFG_SOFTWARE_LIST_REMOVE("flop_ls_32016")
|
||||
MCFG_SOFTWARE_LIST_REMOVE("flop_ls_68000")
|
||||
|
||||
/* acia */
|
||||
MCFG_DEVICE_REMOVE("acia6850")
|
||||
@ -1521,19 +1502,14 @@ MACHINE_CONFIG_END
|
||||
|
||||
|
||||
static MACHINE_CONFIG_DERIVED( bbcm512, bbcm )
|
||||
|
||||
/* Add Intel 80186 co-processor */
|
||||
//MCFG_DEVICE_MODIFY("tube_int")
|
||||
//MCFG_SLOT_DEFAULT_OPTION("80186copro")
|
||||
//MCFG_SLOT_FIXED(true)
|
||||
|
||||
/* software lists */
|
||||
MCFG_SOFTWARE_LIST_ADD("flop_ls_80186", "bbc_flop_80186")
|
||||
MCFG_DEVICE_MODIFY("intube")
|
||||
MCFG_SLOT_DEFAULT_OPTION("80186")
|
||||
MCFG_SLOT_FIXED(true)
|
||||
MACHINE_CONFIG_END
|
||||
|
||||
|
||||
static MACHINE_CONFIG_DERIVED( bbcmarm, bbcm )
|
||||
|
||||
/* Add ARM co-processor */
|
||||
|
||||
/* software lists */
|
||||
@ -1607,9 +1583,6 @@ static MACHINE_CONFIG_DERIVED( bbcmc, bbcm )
|
||||
MCFG_SOFTWARE_LIST_REMOVE("flop_ls_m")
|
||||
MCFG_SOFTWARE_LIST_REMOVE("flop_ls_b")
|
||||
MCFG_SOFTWARE_LIST_REMOVE("flop_ls_b_orig")
|
||||
MCFG_SOFTWARE_LIST_REMOVE("flop_ls_z80")
|
||||
MCFG_SOFTWARE_LIST_REMOVE("flop_ls_32016")
|
||||
MCFG_SOFTWARE_LIST_REMOVE("flop_ls_68000")
|
||||
MCFG_SOFTWARE_LIST_REMOVE("cart_ls_m")
|
||||
MCFG_SOFTWARE_LIST_ADD("flop_ls_mc", "bbcmc_flop")
|
||||
MCFG_SOFTWARE_LIST_COMPATIBLE_ADD("flop_ls_pro128s", "pro128s_flop")
|
||||
@ -1617,6 +1590,8 @@ static MACHINE_CONFIG_DERIVED( bbcmc, bbcm )
|
||||
/* expansion ports */
|
||||
MCFG_DEVICE_REMOVE("analogue")
|
||||
MCFG_COMPACT_JOYPORT_ADD("joyport", bbc_joyport_devices, "joystick")
|
||||
MCFG_DEVICE_REMOVE("intube")
|
||||
MCFG_DEVICE_REMOVE("extube")
|
||||
MACHINE_CONFIG_END
|
||||
|
||||
|
||||
@ -2377,7 +2352,7 @@ COMP ( 1985, ltmpbp, bbcbp, 0, ltmpbp, ltmpbp, bbc_state, bbc,
|
||||
COMP ( 1985, reutapm, bbcbp, 0, reutapm, bbcb, bbc_state, bbc, "Acorn", "Reuters APM", MACHINE_NO_SOUND_HW | MACHINE_NOT_WORKING)
|
||||
COMP ( 1986, econx25, bbcbp, 0, econx25, bbcbp, bbc_state, bbc, "Acorn", "Econet X25 Gateway", MACHINE_NOT_WORKING)
|
||||
COMP ( 1986, bbcm, 0, bbcb, bbcm, bbcm, bbc_state, bbc, "Acorn", "BBC Master 128", MACHINE_IMPERFECT_GRAPHICS)
|
||||
COMP ( 1986, bbcmt, bbcm, 0, bbcmt, bbcm, bbc_state, bbc, "Acorn", "BBC Master Turbo", MACHINE_NOT_WORKING)
|
||||
COMP ( 1986, bbcmt, bbcm, 0, bbcmt, bbcm, bbc_state, bbc, "Acorn", "BBC Master Turbo", MACHINE_IMPERFECT_GRAPHICS)
|
||||
COMP ( 1986, bbcmaiv, bbcm, 0, bbcmaiv, bbcm, bbc_state, bbc, "Acorn", "BBC Master AIV", MACHINE_NOT_WORKING)
|
||||
COMP ( 1986, bbcmet, bbcm, 0, bbcmet, bbcm, bbc_state, bbc, "Acorn", "BBC Master ET", MACHINE_IMPERFECT_GRAPHICS)
|
||||
COMP ( 1986, bbcm512, bbcm, 0, bbcm512, bbcm, bbc_state, bbc, "Acorn", "BBC Master 512", MACHINE_NOT_WORKING)
|
||||
|
@ -82,6 +82,9 @@ public:
|
||||
m_upd7002(*this, "upd7002"),
|
||||
m_analog(*this, "analogue"),
|
||||
m_joyport(*this, "joyport"),
|
||||
m_tube(*this, "tube"),
|
||||
m_intube(*this, "intube"),
|
||||
m_extube(*this, "extube"),
|
||||
m_1mhzbus(*this, "1mhzbus"),
|
||||
m_rtc(*this, "rtc"),
|
||||
m_fdc(*this, "fdc"),
|
||||
@ -229,6 +232,9 @@ public: // HACK FOR MC6845
|
||||
optional_device<upd7002_device> m_upd7002;
|
||||
optional_device<bbc_analogue_slot_device> m_analog;
|
||||
optional_device<bbc_joyport_slot_device> m_joyport;
|
||||
optional_device<bbc_tube_slot_device> m_tube;
|
||||
optional_device<bbc_tube_slot_device> m_intube;
|
||||
optional_device<bbc_tube_slot_device> m_extube;
|
||||
optional_device<bbc_1mhzbus_slot_device> m_1mhzbus;
|
||||
optional_device<mc146818_device> m_rtc;
|
||||
optional_device<bbc_fdc_slot_device> m_fdc;
|
||||
|
@ -505,7 +505,7 @@ READ8_MEMBER(bbc_state::bbcm_r)
|
||||
if ((myo>=0x80) && (myo<=0x9f)) return 0xfe;
|
||||
if ((myo>=0xa0) && (myo<=0xbf)) return m_adlc ? m_adlc->read(space, myo & 0x03) : 0xfe;
|
||||
if ((myo>=0xc0) && (myo<=0xdf)) return 0xff;
|
||||
if ((myo>=0xe0) && (myo<=0xff)) return 0xff;
|
||||
if ((myo>=0xe0) && (myo<=0xff)) return m_intube ? m_intube->host_r(space, myo-0xe0) : 0xff;
|
||||
}
|
||||
return 0xfe;
|
||||
}
|
||||
@ -536,7 +536,7 @@ WRITE8_MEMBER(bbc_state::bbcm_w)
|
||||
//if ((myo>=0x80) && (myo<=0x9f))
|
||||
if ((myo>=0xa0) && (myo<=0xbf) && (m_adlc)) m_adlc->write(space, myo & 0x03, data);
|
||||
//if ((myo>=0xc0) && (myo<=0xdf))
|
||||
//if ((myo>=0xe0) && (myo<=0xff))
|
||||
if ((myo>=0xe0) && (myo<=0xff) && (m_intube)) m_intube->host_w(space, myo-0xe0, data);
|
||||
}
|
||||
}
|
||||
|
||||
@ -1442,6 +1442,8 @@ WRITE8_MEMBER(bbc_state::bbc_wd1770_status_w)
|
||||
// bit 3: density
|
||||
m_wd1770->dden_w(BIT(data, 3));
|
||||
|
||||
// bit 4: interrupt enable
|
||||
|
||||
// bit 5: reset
|
||||
if (!BIT(data, 5)) m_wd1770->soft_reset();
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user