mirror of
https://github.com/holub/mame
synced 2025-04-22 08:22:15 +03:00
(MESS) Apple II: Add preliminary support for TME Arcade Board [R. Belmont]
This commit is contained in:
parent
ec82f9f1eb
commit
4a412e9cfa
2
.gitattributes
vendored
2
.gitattributes
vendored
@ -6369,6 +6369,8 @@ src/mess/machine/990_tap.c svneol=native#text/plain
|
||||
src/mess/machine/990_tap.h svneol=native#text/plain
|
||||
src/mess/machine/a2alfam2.c svneol=native#text/plain
|
||||
src/mess/machine/a2alfam2.h svneol=native#text/plain
|
||||
src/mess/machine/a2arcadebd.c svneol=native#text/plain
|
||||
src/mess/machine/a2arcadebd.h svneol=native#text/plain
|
||||
src/mess/machine/a2bus.c svneol=native#text/plain
|
||||
src/mess/machine/a2bus.h svneol=native#text/plain
|
||||
src/mess/machine/a2cffa.c svneol=native#text/plain
|
||||
|
@ -209,6 +209,7 @@ Apple 3.5 and Apple 5.25 drives - up to three devices
|
||||
#include "machine/a2alfam2.h"
|
||||
#include "machine/laser128.h"
|
||||
#include "machine/a2echoii.h"
|
||||
#include "machine/a2arcadebd.h"
|
||||
|
||||
/***************************************************************************
|
||||
PARAMETERS
|
||||
@ -632,6 +633,7 @@ static SLOT_INTERFACE_START(apple2_cards)
|
||||
SLOT_INTERFACE("ap16alt", A2BUS_IBSAP16ALT) /* IBS AP16 (German VideoTerm clone), alternate revision */
|
||||
SLOT_INTERFACE("vtc1", A2BUS_VTC1) /* Unknown VideoTerm clone #1 */
|
||||
SLOT_INTERFACE("vtc2", A2BUS_VTC2) /* Unknown VideoTerm clone #2 */
|
||||
SLOT_INTERFACE("arcbd", A2BUS_ARCADEBOARD) /* Third Millenium Engineering Arcade Board */
|
||||
// SLOT_INTERFACE("scsi", A2BUS_SCSI) /* Apple II SCSI Card */
|
||||
SLOT_INTERFACE_END
|
||||
|
||||
|
145
src/mess/machine/a2arcadebd.c
Normal file
145
src/mess/machine/a2arcadebd.c
Normal file
@ -0,0 +1,145 @@
|
||||
/*********************************************************************
|
||||
|
||||
a2arcadeboard.c
|
||||
|
||||
Implementation of the Third Millenium Engineering Arcade Board
|
||||
|
||||
*********************************************************************/
|
||||
|
||||
#include "emu.h"
|
||||
#include "machine/a2arcadebd.h"
|
||||
|
||||
|
||||
/***************************************************************************
|
||||
PARAMETERS
|
||||
***************************************************************************/
|
||||
|
||||
#define TMS_TAG "arcbd_tms"
|
||||
#define AY_TAG "arcbd_ay"
|
||||
#define SCREEN_TAG "screen"
|
||||
|
||||
//**************************************************************************
|
||||
// GLOBAL VARIABLES
|
||||
//**************************************************************************
|
||||
|
||||
const device_type A2BUS_ARCADEBOARD = &device_creator<a2bus_arcboard_device>;
|
||||
|
||||
static const ay8910_interface arcadeboard_ay8910_interface =
|
||||
{
|
||||
AY8910_LEGACY_OUTPUT,
|
||||
AY8910_DEFAULT_LOADS,
|
||||
DEVCB_NULL
|
||||
};
|
||||
|
||||
static TMS9928A_INTERFACE(arcadeboard_tms9918a_interface)
|
||||
{
|
||||
SCREEN_TAG,
|
||||
0x4000, // 16k of VRAM
|
||||
DEVCB_NULL // VBL interrupt
|
||||
};
|
||||
|
||||
MACHINE_CONFIG_FRAGMENT( arcadeboard )
|
||||
MCFG_TMS9928A_ADD( TMS_TAG, TMS9918A, arcadeboard_tms9918a_interface )
|
||||
MCFG_TMS9928A_SCREEN_ADD_NTSC( SCREEN_TAG )
|
||||
MCFG_SCREEN_UPDATE_DEVICE( TMS_TAG, tms9918a_device, screen_update )
|
||||
|
||||
MCFG_SPEAKER_STANDARD_MONO("mono")
|
||||
MCFG_SOUND_ADD(AY_TAG, AY8910, 1022727)
|
||||
MCFG_SOUND_CONFIG(arcadeboard_ay8910_interface)
|
||||
MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 1.0)
|
||||
MACHINE_CONFIG_END
|
||||
|
||||
//-------------------------------------------------
|
||||
// machine_config_additions - device-specific
|
||||
// machine configurations
|
||||
//-------------------------------------------------
|
||||
|
||||
machine_config_constructor a2bus_arcboard_device::device_mconfig_additions() const
|
||||
{
|
||||
return MACHINE_CONFIG_NAME( arcadeboard );
|
||||
}
|
||||
|
||||
//**************************************************************************
|
||||
// LIVE DEVICE
|
||||
//**************************************************************************
|
||||
|
||||
a2bus_arcboard_device::a2bus_arcboard_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock) :
|
||||
device_t(mconfig, A2BUS_ARCADEBOARD, "Third Millenium Engineering Arcade Board", tag, owner, clock),
|
||||
device_a2bus_card_interface(mconfig, *this),
|
||||
m_tms(*this, TMS_TAG),
|
||||
m_ay(*this, AY_TAG)
|
||||
{
|
||||
m_shortname = "a2arcbd";
|
||||
}
|
||||
|
||||
a2bus_arcboard_device::a2bus_arcboard_device(const machine_config &mconfig, device_type type, const char *name, const char *tag, device_t *owner, UINT32 clock) :
|
||||
device_t(mconfig, type, name, tag, owner, clock),
|
||||
device_a2bus_card_interface(mconfig, *this),
|
||||
m_tms(*this, TMS_TAG),
|
||||
m_ay(*this, AY_TAG)
|
||||
{
|
||||
m_shortname = "a2arcbd";
|
||||
}
|
||||
|
||||
//-------------------------------------------------
|
||||
// device_start - device-specific startup
|
||||
//-------------------------------------------------
|
||||
|
||||
void a2bus_arcboard_device::device_start()
|
||||
{
|
||||
// set_a2bus_device makes m_slot valid
|
||||
set_a2bus_device();
|
||||
}
|
||||
|
||||
void a2bus_arcboard_device::device_reset()
|
||||
{
|
||||
}
|
||||
|
||||
/*
|
||||
C0nx map:
|
||||
0 - TMS read vram
|
||||
1 - TMS read status
|
||||
2 - TMS write vram
|
||||
3 - TMS write register
|
||||
5 - AY register select
|
||||
6 - AY data
|
||||
*/
|
||||
|
||||
UINT8 a2bus_arcboard_device::read_c0nx(address_space &space, UINT8 offset)
|
||||
{
|
||||
switch (offset)
|
||||
{
|
||||
case 0:
|
||||
return m_tms->vram_read(space, 0);
|
||||
|
||||
case 1:
|
||||
return m_tms->register_read(space, 0);
|
||||
|
||||
case 6:
|
||||
return ay8910_r(m_ay, space, 0);
|
||||
}
|
||||
|
||||
return 0xff;
|
||||
}
|
||||
|
||||
void a2bus_arcboard_device::write_c0nx(address_space &space, UINT8 offset, UINT8 data)
|
||||
{
|
||||
switch (offset)
|
||||
{
|
||||
case 2:
|
||||
m_tms->vram_write(space, 0, data);
|
||||
break;
|
||||
|
||||
case 3:
|
||||
m_tms->register_write(space, 0, data);
|
||||
break;
|
||||
|
||||
case 5:
|
||||
ay8910_address_w(m_ay, space, 0, data);
|
||||
break;
|
||||
|
||||
case 6:
|
||||
ay8910_data_w(m_ay, space, 0, data);
|
||||
break;
|
||||
}
|
||||
}
|
51
src/mess/machine/a2arcadebd.h
Normal file
51
src/mess/machine/a2arcadebd.h
Normal file
@ -0,0 +1,51 @@
|
||||
/*********************************************************************
|
||||
|
||||
a2arcadebd.h
|
||||
|
||||
Third Millenium Engineering Arcade Board
|
||||
|
||||
*********************************************************************/
|
||||
|
||||
#ifndef __A2BUS_ARCADEBOARD__
|
||||
#define __A2BUS_ARCADEBOARD__
|
||||
|
||||
#include "emu.h"
|
||||
#include "machine/a2bus.h"
|
||||
#include "video/tms9928a.h"
|
||||
#include "sound/ay8910.h"
|
||||
|
||||
//**************************************************************************
|
||||
// TYPE DEFINITIONS
|
||||
//**************************************************************************
|
||||
|
||||
class a2bus_arcboard_device:
|
||||
public device_t,
|
||||
public device_a2bus_card_interface
|
||||
{
|
||||
public:
|
||||
// construction/destruction
|
||||
a2bus_arcboard_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock);
|
||||
a2bus_arcboard_device(const machine_config &mconfig, device_type type, const char *name, const char *tag, device_t *owner, UINT32 clock);
|
||||
|
||||
// optional information overrides
|
||||
virtual machine_config_constructor device_mconfig_additions() const;
|
||||
|
||||
protected:
|
||||
virtual void device_start();
|
||||
virtual void device_reset();
|
||||
|
||||
// overrides of standard a2bus slot functions
|
||||
virtual UINT8 read_c0nx(address_space &space, UINT8 offset);
|
||||
virtual void write_c0nx(address_space &space, UINT8 offset, UINT8 data);
|
||||
|
||||
required_device<tms9918a_device> m_tms;
|
||||
required_device<device_t> m_ay;
|
||||
|
||||
private:
|
||||
};
|
||||
|
||||
// device type definition
|
||||
extern const device_type A2BUS_ARCADEBOARD;
|
||||
|
||||
#endif /* __A2BUS_ARCADEBOARD__ */
|
||||
|
@ -678,6 +678,7 @@ $(MESSOBJ)/apple.a: \
|
||||
$(MESS_MACHINE)/a2alfam2.o \
|
||||
$(MESS_MACHINE)/laser128.o \
|
||||
$(MESS_MACHINE)/a2echoii.o \
|
||||
$(MESS_MACHINE)/a2arcadebd.o \
|
||||
$(MESS_MACHINE)/lisa.o \
|
||||
$(MESS_DRIVERS)/lisa.o \
|
||||
$(MESS_MACHINE)/nubus.o \
|
||||
|
Loading…
Reference in New Issue
Block a user