summaryrefslogtreecommitdiffstatshomepage
path: root/src/devices/bus/bbc/tube/tube_32016.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/devices/bus/bbc/tube/tube_32016.cpp')
-rw-r--r--src/devices/bus/bbc/tube/tube_32016.cpp65
1 files changed, 51 insertions, 14 deletions
diff --git a/src/devices/bus/bbc/tube/tube_32016.cpp b/src/devices/bus/bbc/tube/tube_32016.cpp
index 164ab0ff089..6a54665937d 100644
--- a/src/devices/bus/bbc/tube/tube_32016.cpp
+++ b/src/devices/bus/bbc/tube/tube_32016.cpp
@@ -29,6 +29,7 @@
//**************************************************************************
DEFINE_DEVICE_TYPE(BBC_TUBE_32016, bbc_tube_32016_device, "bbc_tube_32016", "Acorn 32016 2nd processor")
+DEFINE_DEVICE_TYPE(BBC_TUBE_32016L, bbc_tube_32016l_device, "bbc_tube_32016l", "Acorn Large 32016 2nd processor")
//-------------------------------------------------
@@ -38,8 +39,9 @@ DEFINE_DEVICE_TYPE(BBC_TUBE_32016, bbc_tube_32016_device, "bbc_tube_32016", "Aco
void bbc_tube_32016_device::tube_32016_mem(address_map &map)
{
map(0x000000, 0xffffff).rw(FUNC(bbc_tube_32016_device::read), FUNC(bbc_tube_32016_device::write));
+ map(0xf00000, 0xf07fff).rom().region("rom", 0).mirror(0x0f8000);
map(0xf90000, 0xf90001).portr("CONFIG");
- map(0xfffff0, 0xffffff).rw("ula", FUNC(tube_device::parasite_r), FUNC(tube_device::parasite_w)).umask32(0x00ff);
+ map(0xfffff0, 0xffffff).rw("ula", FUNC(tube_device::parasite_r), FUNC(tube_device::parasite_w)).umask16(0x00ff);
}
//-------------------------------------------------
@@ -47,18 +49,27 @@ void bbc_tube_32016_device::tube_32016_mem(address_map &map)
//-------------------------------------------------
ROM_START(tube_32016)
- ROM_REGION(0x8000, "rom", 0)
- ROM_DEFAULT_BIOS("200")
+ ROM_REGION16_LE(0x8000, "rom", 0)
ROM_SYSTEM_BIOS(0, "200", "Pandora v2.00")
ROMX_LOAD("pan200lo.rom", 0x0000, 0x4000, CRC(b1980fd0) SHA1(8084f8896cd22953abefbd43c51e1a422b30e28d), ROM_SKIP(1) | ROM_BIOS(0)) // 0201-764-02 Pandora Lo
ROMX_LOAD("pan200hi.rom", 0x0001, 0x4000, CRC(cab98d6b) SHA1(dfad1f4180c50757a74fcfe3a0ee7d7b48eb1bee), ROM_SKIP(1) | ROM_BIOS(0)) // 0201-763-02 Pandora Hi
ROM_SYSTEM_BIOS(1, "100", "Pandora v1.00")
- ROMX_LOAD("pan100.rom", 0x0000, 0x8000, BAD_DUMP CRC(75333006) SHA1(996cd120103039390c9b979b16c327bb95da72e4), ROM_BIOS(1)) // 0201-763-01, 0201-764-01 Pandora
+ ROMX_LOAD("pan100lo.rom", 0x0000, 0x2000, CRC(101e8aca) SHA1(4998e64afe98b2f227df6daa7ae0af512ce8907a), ROM_SKIP(1) | ROM_BIOS(1)) // 0201-764-01 Pandora Lo
+ ROM_RELOAD( 0x4000, 0x2000)
+ ROMX_LOAD("pan100hi.rom", 0x0001, 0x2000, CRC(139de9ed) SHA1(1871e65c9ebd3eac835b0317b0ad8272ff207c4b), ROM_SKIP(1) | ROM_BIOS(1)) // 0201-763-01 Pandora Hi
+ ROM_RELOAD( 0x4001, 0x2000)
ROM_SYSTEM_BIOS(2, "061", "Pandora v0.61")
ROMX_LOAD("pan061lo.rom", 0x0000, 0x4000, CRC(6f801b35) SHA1(ce31f7c10603f3d15a06a8e32bde40df0639e446), ROM_SKIP(1) | ROM_BIOS(2))
ROMX_LOAD("pan061hi.rom", 0x0001, 0x4000, CRC(c00b1ab0) SHA1(e6a705232278c518340ddc69ea51af91965fa332), ROM_SKIP(1) | ROM_BIOS(2))
ROM_END
+ROM_START(tube_32016l)
+ ROM_REGION16_LE(0x8000, "rom", 0)
+ ROM_SYSTEM_BIOS(0, "200", "Pandora v2.00")
+ ROMX_LOAD("pan200lo.rom", 0x0000, 0x4000, CRC(b1980fd0) SHA1(8084f8896cd22953abefbd43c51e1a422b30e28d), ROM_SKIP(1) | ROM_BIOS(0)) // 0201-764-02 Pandora Lo
+ ROMX_LOAD("pan200hi.rom", 0x0001, 0x4000, CRC(cab98d6b) SHA1(dfad1f4180c50757a74fcfe3a0ee7d7b48eb1bee), ROM_SKIP(1) | ROM_BIOS(0)) // 0201-763-02 Pandora Hi
+ROM_END
+
//-------------------------------------------------
// INPUT_PORTS( tube_32016 )
//-------------------------------------------------
@@ -112,12 +123,23 @@ void bbc_tube_32016_device::device_add_mconfig(machine_config &config)
m_ula->pirq_handler().set_inputline(m_maincpu, INPUT_LINE_IRQ0);
/* internal ram */
- RAM(config, m_ram).set_default_size("1M").set_default_value(0);
+ RAM(config, m_ram).set_default_size("1M").set_extra_options("256K");
/* software lists */
SOFTWARE_LIST(config, "flop_ls_32016").set_original("bbc_flop_32016");
}
+
+void bbc_tube_32016l_device::device_add_mconfig(machine_config &config)
+{
+ bbc_tube_32016_device::device_add_mconfig(config);
+
+ m_maincpu->set_clock(16_MHz_XTAL / 2);
+
+ /* internal ram */
+ m_ram->set_default_size("4M");
+}
+
//-------------------------------------------------
// rom_region - device-specific ROM region
//-------------------------------------------------
@@ -127,6 +149,11 @@ const tiny_rom_entry *bbc_tube_32016_device::device_rom_region() const
return ROM_NAME( tube_32016 );
}
+const tiny_rom_entry *bbc_tube_32016l_device::device_rom_region() const
+{
+ return ROM_NAME( tube_32016l );
+}
+
//-------------------------------------------------
// input_ports - device-specific input ports
//-------------------------------------------------
@@ -144,8 +171,8 @@ ioport_constructor bbc_tube_32016_device::device_input_ports() const
// bbc_tube_32016_device - constructor
//-------------------------------------------------
-bbc_tube_32016_device::bbc_tube_32016_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock)
- : device_t(mconfig, BBC_TUBE_32016, tag, owner, clock)
+bbc_tube_32016_device::bbc_tube_32016_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock)
+ : device_t(mconfig, type, tag, owner, clock)
, device_bbc_tube_interface(mconfig, *this)
, m_maincpu(*this, "maincpu")
, m_ula(*this, "ula")
@@ -155,12 +182,23 @@ bbc_tube_32016_device::bbc_tube_32016_device(const machine_config &mconfig, cons
{
}
+bbc_tube_32016_device::bbc_tube_32016_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock)
+ : bbc_tube_32016_device(mconfig, BBC_TUBE_32016, tag, owner, clock)
+{
+}
+
+bbc_tube_32016l_device::bbc_tube_32016l_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock)
+ : bbc_tube_32016_device(mconfig, BBC_TUBE_32016L, tag, owner, clock)
+{
+}
+
//-------------------------------------------------
// device_start - device-specific startup
//-------------------------------------------------
void bbc_tube_32016_device::device_start()
{
+ save_item(NAME(m_rom_enabled));
}
//-------------------------------------------------
@@ -190,12 +228,12 @@ void bbc_tube_32016_device::host_w(offs_t offset, uint8_t data)
uint8_t bbc_tube_32016_device::read(offs_t offset)
{
- uint16_t data = 0xffff;
+ uint16_t data;
if (m_rom_enabled)
- data = m_rom->base()[offset & 0x3fff];
- else if (offset < m_ram->size())
- data = m_ram->pointer()[offset];
+ data = m_rom->base()[offset & 0x7fff];
+ else
+ data = m_ram->pointer()[offset & m_ram->mask()];
return data;
}
@@ -203,8 +241,7 @@ uint8_t bbc_tube_32016_device::read(offs_t offset)
void bbc_tube_32016_device::write(offs_t offset, uint8_t data)
{
/* clear ROM select on first write */
- if (!machine().side_effects_disabled()) m_rom_enabled = false;
+ m_rom_enabled = false;
- if (offset < m_ram->size())
- m_ram->pointer()[offset] = data;
+ m_ram->pointer()[offset & m_ram->mask()] = data;
}