Add TMP90PH44 device type for Sega 837-13551 I/O Board (nw)

This commit is contained in:
AJR 2017-04-12 15:53:00 -04:00
parent fb163b2d7e
commit 47900ba401
4 changed files with 40 additions and 5 deletions

View File

@ -26,32 +26,39 @@ const device_type TMP90841 = device_creator<tmp90841_device>;
const device_type TMP90845 = device_creator<tmp90845_device>;
const device_type TMP91640 = device_creator<tmp91640_device>;
const device_type TMP91641 = device_creator<tmp91641_device>;
const device_type TMP90PH44 = device_creator<tmp90ph44_device>;
static ADDRESS_MAP_START(tmp90840_mem, AS_PROGRAM, 8, tlcs90_device)
AM_RANGE( 0x0000, 0x1fff ) AM_ROM // 8KB ROM (internal)
AM_RANGE( 0xfec0, 0xffc0 ) AM_RAM // 256b RAM (internal)
AM_RANGE( 0xfec0, 0xffbf ) AM_RAM // 256b RAM (internal)
AM_RANGE( T90_IOBASE, T90_IOBASE+47 ) AM_READWRITE( t90_internal_registers_r, t90_internal_registers_w )
ADDRESS_MAP_END
static ADDRESS_MAP_START(tmp90841_mem, AS_PROGRAM, 8, tlcs90_device)
// AM_RANGE( 0x0000, 0x1fff ) AM_ROM // rom-less
AM_RANGE( 0xfec0, 0xffc0 ) AM_RAM // 256b RAM (internal)
AM_RANGE( 0xfec0, 0xffbf ) AM_RAM // 256b RAM (internal)
AM_RANGE( T90_IOBASE, T90_IOBASE+47 ) AM_READWRITE( t90_internal_registers_r, t90_internal_registers_w )
ADDRESS_MAP_END
static ADDRESS_MAP_START(tmp91640_mem, AS_PROGRAM, 8, tlcs90_device )
AM_RANGE( 0x0000, 0x3fff ) AM_ROM // 16KB ROM (internal)
AM_RANGE( 0xfdc0, 0xffc0 ) AM_RAM // 512b RAM (internal)
AM_RANGE( 0xfdc0, 0xffbf ) AM_RAM // 512b RAM (internal)
AM_RANGE( T90_IOBASE, T90_IOBASE+47 ) AM_READWRITE( t90_internal_registers_r, t90_internal_registers_w )
ADDRESS_MAP_END
static ADDRESS_MAP_START(tmp91641_mem, AS_PROGRAM, 8, tlcs90_device )
// AM_RANGE( 0x0000, 0x3fff ) AM_ROM // rom-less
AM_RANGE( 0xfdc0, 0xffc0 ) AM_RAM // 512b RAM (internal)
AM_RANGE( 0xfdc0, 0xffbf ) AM_RAM // 512b RAM (internal)
AM_RANGE( T90_IOBASE, T90_IOBASE+47 ) AM_READWRITE( t90_internal_registers_r, t90_internal_registers_w )
ADDRESS_MAP_END
static ADDRESS_MAP_START(tmp90ph44_mem, AS_PROGRAM, 8, tlcs90_device )
AM_RANGE( 0x0000, 0x3fff ) AM_ROM // 16KB ROM (internal)
AM_RANGE( 0xfdc0, 0xffbf ) AM_RAM // 512b RAM (internal)
AM_RANGE( T90_IOBASE, T90_IOBASE+55 ) AM_READWRITE( t90_internal_registers_r, t90_internal_registers_w ) // TODO: has 8 more registers
ADDRESS_MAP_END
tlcs90_device::tlcs90_device(const machine_config &mconfig, device_type type, const char *name, const char *tag, device_t *owner, uint32_t clock, const char *shortname, const char *source, address_map_constructor program_map)
: cpu_device(mconfig, type, name, tag, owner, clock, shortname, source)
@ -90,6 +97,12 @@ tmp91641_device::tmp91641_device(const machine_config &mconfig, const char *tag,
}
tmp90ph44_device::tmp90ph44_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock)
: tlcs90_device(mconfig, TMP90PH44, "TMP90PH44", tag, owner, clock, "tmp90ph44", __FILE__, ADDRESS_MAP_NAME(tmp90ph44_mem))
{
}
enum {
T90_B, T90_C, T90_D, T90_E, T90_H, T90_L, T90_A,
T90_BC, T90_DE, T90_HL, T90_XX, T90_IX, T90_IY, T90_SP,

View File

@ -166,6 +166,7 @@ public:
tmp90845_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
};
class tmp91640_device : public tlcs90_device
{
public:
@ -182,10 +183,19 @@ public:
};
class tmp90ph44_device : public tlcs90_device
{
public:
// construction/destruction
tmp90ph44_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
};
extern const device_type TMP90840;
extern const device_type TMP90841;
extern const device_type TMP90845;
extern const device_type TMP91640;
extern const device_type TMP91641;
extern const device_type TMP90PH44;
#endif /* __TLCS90_H__ */

View File

@ -3,6 +3,8 @@
#include "emu.h"
#include "jvs13551.h"
#include "cpu/tlcs90/tlcs90.h"
const device_type SEGA_837_13551 = device_creator<sega_837_13551>;
WRITE_LINE_MEMBER(sega_837_13551::jvs13551_coin_1_w)
@ -23,9 +25,13 @@ static INPUT_PORTS_START(sega_837_13551_coins)
PORT_BIT(0x02, IP_ACTIVE_HIGH, IPT_COIN2) PORT_WRITE_LINE_DEVICE_MEMBER(DEVICE_SELF, sega_837_13551, jvs13551_coin_2_w)
INPUT_PORTS_END
MACHINE_CONFIG_FRAGMENT(sega_837_13551)
MCFG_CPU_ADD("iomcu", TMP90PH44, 10000000) // unknown clock
MACHINE_CONFIG_END
ROM_START( jvs13551 )
// TMP90PH44N firmwares
ROM_REGION( 0x8000, "jvs13551", ROMREGION_ERASE )
ROM_REGION( 0x8000, "iomcu", ROMREGION_ERASE )
// Sega 838-13683-93
ROM_LOAD( "sp5001.bin", 0x0000, 0x8000, CRC(2f17e21a) SHA1(ac227ef3ca52ef17321bd60e435dba147645d8b8))
// Sega 838-13683-93 Rev.B
@ -47,6 +53,11 @@ void sega_837_13551::static_set_port_tag(device_t &device, int port, const char
ctrl.port_tag[port] = tag;
}
machine_config_constructor sega_837_13551::device_mconfig_additions() const
{
return MACHINE_CONFIG_NAME(sega_837_13551);
}
ioport_constructor sega_837_13551::device_input_ports() const
{
return INPUT_PORTS_NAME(sega_837_13551_coins);

View File

@ -38,6 +38,7 @@ protected:
// device-level overrides
virtual void device_start() override;
virtual void device_reset() override;
virtual machine_config_constructor device_mconfig_additions() const override;
virtual ioport_constructor device_input_ports() const override;
// JVS device overrides