summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
author Robbbert <Robbbert@users.noreply.github.com>2018-05-24 11:13:10 +1000
committer Robbbert <Robbbert@users.noreply.github.com>2018-05-24 11:13:10 +1000
commit2d48fe3e35c9914864005196a11a88f3bb2cfd65 (patch)
tree7fda799226bab94d7d355ce2e8fc1aa666db36d1
parent512f11a672b47739e7a3530edc10e2aec22fa39c (diff)
parentf86f1fbda9c6eeae02914b9f64863c0ff1ab90f6 (diff)
Merge remote-tracking branch 'upstream/master'
-rw-r--r--scripts/target/mame/arcade.lua1
-rw-r--r--src/devices/bus/ieee488/remote488.cpp156
-rw-r--r--src/devices/bus/ieee488/remote488.h7
-rw-r--r--src/devices/machine/pc_fdc.cpp14
-rw-r--r--src/devices/video/i8275.cpp5
-rw-r--r--src/devices/video/voodoo_pci.cpp175
-rw-r--r--src/devices/video/voodoo_pci.h128
-rw-r--r--src/mame/arcade.flt1
-rw-r--r--src/mame/audio/dcs.cpp3
-rw-r--r--src/mame/drivers/apogee.cpp2
-rw-r--r--src/mame/drivers/gamemasters.cpp150
-rw-r--r--src/mame/drivers/imds2.cpp2
-rw-r--r--src/mame/drivers/iteagle.cpp4
-rw-r--r--src/mame/drivers/mikrosha.cpp2
-rw-r--r--src/mame/drivers/rungun.cpp41
-rw-r--r--src/mame/drivers/seattle.cpp2
-rw-r--r--src/mame/drivers/unior.cpp3
-rw-r--r--src/mame/drivers/vamphalf.cpp556
-rw-r--r--src/mame/drivers/vegas.cpp8
-rw-r--r--src/mame/drivers/wicat.cpp36
-rw-r--r--src/mame/includes/rungun.h16
-rw-r--r--src/mame/layout/wicat.lay4
-rw-r--r--src/mame/machine/cdi070.cpp2
-rw-r--r--src/mame/machine/cdi070.h2
-rw-r--r--src/mame/machine/partner.cpp2
-rw-r--r--src/mame/machine/radio86.cpp2
-rw-r--r--src/mame/mame.lst4
-rw-r--r--src/mame/video/rungun.cpp9
28 files changed, 950 insertions, 387 deletions
diff --git a/scripts/target/mame/arcade.lua b/scripts/target/mame/arcade.lua
index b49382881dd..e2b97d1befd 100644
--- a/scripts/target/mame/arcade.lua
+++ b/scripts/target/mame/arcade.lua
@@ -4582,6 +4582,7 @@ files {
MAME_DIR .. "src/mame/drivers/galaxi.cpp",
MAME_DIR .. "src/mame/drivers/galgame.cpp",
MAME_DIR .. "src/mame/drivers/gamecstl.cpp",
+ MAME_DIR .. "src/mame/drivers/gamemasters.cpp",
MAME_DIR .. "src/mame/drivers/gammagic.cpp",
MAME_DIR .. "src/mame/drivers/gamtor.cpp",
MAME_DIR .. "src/mame/drivers/gei.cpp",
diff --git a/src/devices/bus/ieee488/remote488.cpp b/src/devices/bus/ieee488/remote488.cpp
index bc4c8623d0e..1c14266796c 100644
--- a/src/devices/bus/ieee488/remote488.cpp
+++ b/src/devices/bus/ieee488/remote488.cpp
@@ -43,6 +43,8 @@
| Q | O | No | Request 'P' msg |
| R | I/O | Yes | Set bus control signals to 0 |
| S | I/O | Yes | Set bus control signals to 1 |
+ | X | I/O | No | Checkpoint in byte string |
+ | Y | I/O | Yes | Checkpoint reached |
- D messages
@@ -50,24 +52,42 @@
In the output direction the remotizer implements an acceptor so
that the proper 3-way handshake is implemented with the
source. The acceptor has no delays between state transitions so
- that it can keep up with any speed of the source. The acceptor
- doesn't wait for any acknowledgement from external receiver. The
- buffering in the output stream must have enough space to hold
- bursts of data bytes before they are processed by the external
- receiver.
+ that it can keep up with any speed of the source.
In the input direction a source is implemented to handshake with
local acceptor(s). The FSM in the source has no delays so that it can
operate at whatever speed the slowest acceptor on the bus can sustain.
Bytes are removed from the input buffer of the stream as the local
acceptors acknowledge them. No input message is processed by the
remotizer when it's waiting for 3-way handshake with acceptors to
- complete. If a local controller asserts the ATN signal to regain
- control of the bus when there are input bytes waiting, the bytes
- are discarded.
+ complete.
Byte values are expressed in positive logic (which is the opposite
of what's sent on the bus). To discriminate between DAB and command
bytes the receiver of this message has to check its state of ATN
signal (see R&S messages).
+ A simple infrastructure for synchronization between near and far
+ end is provided. The sender of a string of bytes can insert a
+ "checkpoint" msg in the string. This msg is turned into a
+ "checkpoint reached" msg by the receiver and sent back. This msg
+ reports to the sender that the receiver has processed data up to
+ the last checkpoint.
+ The acceptor in the remotizer sends a checkpoint in two cases: when a
+ byte with EOI is accepted and sent to the far end or when there's
+ a pause in the byte string longer than 10 ms. This is just for
+ safety, normal byte strings are always terminated by EOI by the
+ sender. The remotizer acceptor stops accepting data after sending
+ a checkpoint. It resumes when the "checkpoint reached" msg is sent
+ back. Bytes of I/F commands never use checkpointing.
+ The source handshake (SH) in the remotizer accepts data bytes from
+ the far end and puts them on the local bus. A simple heuristic is
+ implemented to recognize the situation when the far end has sent
+ more data than a local acceptor is willing to take. Whenever ATN
+ is asserted by a local device (the controller) all input bytes are
+ discarded up to the next checkpoint. The "checkpoint reached" msg
+ then reports that data has been completely/partially flushed by
+ setting its byte to 1. In normal cases byte is set to 0.
+ Usage of checkpointing is optional. The minimum the far end should
+ implement is sending back a "checkpoint reached" msg whenever a
+ checkpoint is received.
- E messages
@@ -129,16 +149,31 @@
message is attempting to set to 1 a signal that is locally forced
to 0.
+ - X & Y messages
+
+ See "D" messages above. "X" message is sent to request the
+ receiver to acknowledge the reception by sending back a "Y"
+ message. When used, the "X" message should be sent at the end of
+ a string of bytes by the sender. The reception of "Y" message
+ confirms that the receiver has seen (though not necessarily
+ accepted) the whole string.
+ The "X" -> "Y" sequence is used in the local AH for flow control:
+ once "X" is sent out, the acceptor pauses accepting bytes until a
+ "Y" is received. For this reason the far end should always
+ implement, at the very least, the sending back of "Y" whenever "X"
+ is seen.
+ A "X" message carries no info in its byte. A "Y" message reports
+ whether the preceding byte string was entirely accepted by the
+ receiver or not (with a 00 or 01 value in the associated byte,
+ respectively).
+
Limits & potential issues:
- There are no checks for violations of IEEE-488 protocol. It's
possible, for example, to put the bus in an illegal state by
sending a 'E' msg when the local controller is asserting ATN
(thus creating a phantom parallel poll).
- - The unacknowledged nature of D/E msgs may cause problems if
- the sender of the msgs must be synchronized byte-for-byte with
- the receiver. There is no direct way, for example, for the
- sender of a string of bytes to know how many have been accepted
- by the receiver.
+ - The heuristic to discard byte strings in the SH could be a bit
+ too simple and do the wrong thing in few rare cases.
- It's difficult to achieve accurate synchronization between the
local emulation time and the external time.
@@ -146,10 +181,6 @@
- Implement handling of incoming Q msgs (needed when parallel poll
is being performed by a remote controller)
- Enhancement: implement a msg for accurate time synchronization
- - Enhancement: implement some form of sliding window acknowledgement
- for cases when sender has to know how many bytes have been
- processed by the receiver. The HP "Amigo" protocol I used for
- my experiments has no such need.
*********************************************************************/
@@ -199,11 +230,14 @@ constexpr char MSG_PP_DATA = 'P'; // I: Parallel poll data
constexpr char MSG_PP_REQUEST = 'Q'; // O: Request PP data
constexpr char MSG_ECHO_REQ = 'J'; // O: Heartbeat msg: echo request
constexpr char MSG_ECHO_REPLY = 'K'; // I: Heartbeat msg: echo reply
+constexpr char MSG_CHECKPOINT = 'X'; // I/O: Checkpoint in byte stream
+constexpr char MSG_CP_REACHED = 'Y'; // I/O: Checkpoint reached
// Timings
constexpr unsigned POLL_PERIOD_US = 20; // Poll period (µs)
constexpr unsigned HEARTBEAT_MS = 500; // Heartbeat ping period (ms)
constexpr unsigned MAX_MISSED_HB = 3; // Missed heartbeats to declare the connection dead
+constexpr unsigned AH_TO_MS = 10; // Timeout in AH to report a byte string terminated (ms)
// device type definition
DEFINE_DEVICE_TYPE(REMOTE488, remote488_device, "remote488", "IEEE-488 Remotizer")
@@ -244,6 +278,7 @@ void remote488_device::ieee488_ifc(int state)
update_signal(SIGNAL_IFC_BIT , state);
if (!state) {
LOG("IFC\n");
+ flush_data();
bus_reset();
}
}
@@ -257,6 +292,7 @@ void remote488_device::ieee488_atn(int state)
{
update_signal(SIGNAL_ATN_BIT , state);
update_sh_fsm();
+ update_ah_fsm();
update_pp();
}
@@ -269,6 +305,7 @@ void remote488_device::device_start()
{
m_poll_timer = timer_alloc(TMR_ID_POLL);
m_hb_timer = timer_alloc(TMR_ID_HEARTBEAT);
+ m_ah_timer = timer_alloc(TMR_ID_AH);
}
void remote488_device::device_reset()
@@ -287,6 +324,9 @@ void remote488_device::device_reset()
m_connected = true;
set_connection(false);
+ m_ibf = false;
+ m_flush_bytes = false;
+ m_waiting_cp = false;
bus_reset();
}
@@ -295,8 +335,6 @@ void remote488_device::bus_reset()
m_sh_state = REM_SH_SIDS;
m_ah_state = REM_AH_ACRS;
m_rx_state = REM_RX_WAIT_CH;
- m_ibf = false;
- m_flush_bytes = false;
m_poll_timer->adjust(attotime::from_usec(POLL_PERIOD_US) , 0 , attotime::from_usec(POLL_PERIOD_US));
m_pp_data = 0;
m_pp_requested = false;
@@ -315,38 +353,25 @@ void remote488_device::process_input_msgs()
switch (msg_ch) {
case MSG_SIGNAL_CLEAR:
- m_flush_bytes = false;
update_signals_from_rem(0 , data);
break;
case MSG_SIGNAL_SET:
- m_flush_bytes = false;
update_signals_from_rem(data , 0);
break;
case MSG_DATA_BYTE:
- if (m_flush_bytes) {
- LOG("Flushed\n");
- } else {
- m_poll_timer->reset();
- recvd_data_byte(data , false);
- return;
- }
- break;
-
case MSG_END_BYTE:
if (m_flush_bytes) {
LOG("Flushed\n");
- m_flush_bytes = false;
+ m_poll_timer->adjust(attotime::zero);
} else {
m_poll_timer->reset();
- recvd_data_byte(data , true);
- return;
+ recvd_data_byte(data , msg_ch == MSG_END_BYTE);
}
- break;
+ return;
case MSG_PP_DATA:
- m_flush_bytes = false;
m_pp_data = data;
m_pp_requested = false;
update_pp_dio();
@@ -356,6 +381,18 @@ void remote488_device::process_input_msgs()
send_update(MSG_ECHO_REPLY , 0);
break;
+ case MSG_CHECKPOINT:
+ send_update(MSG_CP_REACHED , m_flush_bytes);
+ m_flush_bytes = false;
+ break;
+
+ case MSG_CP_REACHED:
+ if (m_waiting_cp) {
+ m_waiting_cp = false;
+ update_ah_fsm();
+ }
+ break;
+
default:
break;
}
@@ -379,6 +416,13 @@ void remote488_device::device_timer(emu_timer &timer, device_timer_id id, int pa
send_update(MSG_ECHO_REQ , 0);
break;
+ case TMR_ID_AH:
+ if (!m_waiting_cp) {
+ LOG("CP T/O\n");
+ ah_checkpoint();
+ }
+ break;
+
default:
break;
}
@@ -419,10 +463,23 @@ void remote488_device::recvd_data_byte(uint8_t data , bool eoi)
m_ib = data;
m_ib_eoi = eoi;
m_ibf = true;
+ if (is_local_atn_active()) {
+ flush_data();
+ }
update_sh_fsm();
update_ah_fsm();
}
+void remote488_device::flush_data()
+{
+ if (m_ibf) {
+ LOG("Flushing enabled\n");
+ m_flush_bytes = true;
+ m_ibf = false;
+ m_poll_timer->adjust(attotime::zero);
+ }
+}
+
void remote488_device::update_signals_from_rem(uint8_t to_set , uint8_t to_clear)
{
uint8_t diff = m_in_signals;
@@ -473,11 +530,8 @@ void remote488_device::update_state(uint8_t new_signals)
m_out_signals = new_signals;
- if (is_local_atn_active() && m_ibf) {
- LOG("Flushing enabled\n");
- m_flush_bytes = true;
- m_ibf = false;
- m_poll_timer->adjust(attotime::zero);
+ if (is_local_atn_active()) {
+ flush_data();
}
if (to_set) {
@@ -521,7 +575,9 @@ bool remote488_device::is_msg_type(char c)
c == MSG_DATA_BYTE ||
c == MSG_END_BYTE ||
c == MSG_PP_DATA ||
- c == MSG_ECHO_REPLY;
+ c == MSG_ECHO_REPLY ||
+ c == MSG_CHECKPOINT ||
+ c == MSG_CP_REACHED;
}
bool remote488_device::is_terminator(char c)
@@ -617,6 +673,13 @@ bool remote488_device::is_local_atn_active() const
return !BIT(m_out_signals , SIGNAL_ATN_BIT) && BIT(m_in_signals , SIGNAL_ATN_BIT);
}
+void remote488_device::ah_checkpoint()
+{
+ m_waiting_cp = true;
+ m_ah_timer->reset();
+ send_update(MSG_CHECKPOINT , 0);
+}
+
void remote488_device::update_ah_fsm()
{
bool changed = true;
@@ -640,13 +703,22 @@ void remote488_device::update_ah_fsm()
break;
case REM_AH_ACDS:
- {
+ if (m_bus->dav_r()) {
+ m_ah_state = REM_AH_ACRS;
+ } else if (!m_waiting_cp) {
uint8_t dio = ~m_bus->dio_r();
if (!m_bus->eoi_r()) {
send_update(MSG_END_BYTE , dio);
+ ah_checkpoint();
} else {
send_update(MSG_DATA_BYTE , dio);
+ if (!BIT(m_out_signals , SIGNAL_ATN_BIT)) {
+ // I/F commands have no checkpoint
+ m_ah_timer->reset();
+ } else {
+ m_ah_timer->adjust(attotime::from_msec(AH_TO_MS));
+ }
}
m_ah_state = REM_AH_AWNS;
}
diff --git a/src/devices/bus/ieee488/remote488.h b/src/devices/bus/ieee488/remote488.h
index fb5d267e901..312fc260f42 100644
--- a/src/devices/bus/ieee488/remote488.h
+++ b/src/devices/bus/ieee488/remote488.h
@@ -34,7 +34,8 @@ public:
// Timers
enum {
TMR_ID_POLL,
- TMR_ID_HEARTBEAT
+ TMR_ID_HEARTBEAT,
+ TMR_ID_AH
};
protected:
@@ -93,17 +94,20 @@ private:
bool m_ib_eoi;
emu_timer *m_poll_timer;
emu_timer *m_hb_timer;
+ emu_timer *m_ah_timer;
unsigned m_connect_cnt;
bool m_connected;
uint8_t m_pp_data;
bool m_pp_requested;
uint8_t m_pp_dio;
uint8_t m_sh_dio;
+ bool m_waiting_cp;
void bus_reset();
void process_input_msgs();
void set_connection(bool state);
void recvd_data_byte(uint8_t data , bool eoi);
+ void flush_data();
void update_signals_from_rem(uint8_t to_set , uint8_t to_clear);
void update_signal(signal_bit bit , int state);
void update_state(uint8_t new_signals);
@@ -114,6 +118,7 @@ private:
static bool is_space(char c);
char recv_update(uint8_t& data);
bool is_local_atn_active() const;
+ void ah_checkpoint();
void update_ah_fsm();
void update_sh_fsm();
bool is_local_pp_active() const;
diff --git a/src/devices/machine/pc_fdc.cpp b/src/devices/machine/pc_fdc.cpp
index 9d6acf72826..04db749eda7 100644
--- a/src/devices/machine/pc_fdc.cpp
+++ b/src/devices/machine/pc_fdc.cpp
@@ -16,6 +16,14 @@
#include "emu.h"
#include "machine/pc_fdc.h"
+//#define LOG_GENERAL (1U << 0) //defined in logmacro.h already
+
+//#define VERBOSE (LOG_GENERAL)
+//#define LOG_OUTPUT_STREAM std::cout
+
+#include "logmacro.h"
+
+
DEFINE_DEVICE_TYPE(PC_FDC_XT, pc_fdc_xt_device, "pc_fdc_xt", "PC FDC (XT)")
DEFINE_DEVICE_TYPE(PC_FDC_AT, pc_fdc_at_device, "pc_fdc_at", "PC FDC (AT)")
@@ -101,7 +109,7 @@ void pc_fdc_family_device::device_reset()
WRITE8_MEMBER( pc_fdc_family_device::dor_w )
{
- logerror("%s: dor = %02x\n", tag(), data);
+ LOG("dor = %02x\n", data);
uint8_t pdor = dor;
dor = data;
@@ -134,7 +142,7 @@ READ8_MEMBER( pc_fdc_family_device::dir_r )
WRITE8_MEMBER( pc_fdc_family_device::ccr_w )
{
static const int rates[4] = { 500000, 300000, 250000, 1000000 };
- logerror("%s: ccr = %02x\n", tag(), data);
+ LOG("ccr = %02x\n", data);
fdc->set_rate(rates[data & 3]);
}
@@ -168,7 +176,7 @@ void pc_fdc_family_device::check_irq()
bool pirq = irq;
irq = fdc_irq && (dor & 4) && (dor & 8);
if(irq != pirq && !intrq_cb.isnull()) {
- logerror("%s: pc_irq = %d\n", tag(), irq);
+ LOG("pc_irq = %d\n", irq);
intrq_cb(irq);
}
}
diff --git a/src/devices/video/i8275.cpp b/src/devices/video/i8275.cpp
index 96484294ece..cd035f8fa54 100644
--- a/src/devices/video/i8275.cpp
+++ b/src/devices/video/i8275.cpp
@@ -329,7 +329,8 @@ void i8275_device::device_timer(emu_timer &timer, device_timer_id id, int param,
if ((m_status & ST_VE) && m_scanline < m_vrtc_scanline)
{
int line_counter = OFFSET_LINE_COUNTER ? ((lc - 1) % SCANLINES_PER_ROW) : lc;
- bool end_of_row = (UNDERLINE >= 8) && ((lc == 0) || (lc == SCANLINES_PER_ROW - 1));
+ bool end_of_row = false;
+ bool blank_row = (UNDERLINE >= 8) && ((lc == 0) || (lc == SCANLINES_PER_ROW - 1));
int fifo_idx = 0;
m_hlgt = (m_stored_attr & FAC_H) ? 1 : 0;
m_vsp = (m_stored_attr & FAC_B) ? 1 : 0;
@@ -443,7 +444,7 @@ void i8275_device::device_timer(emu_timer &timer, device_timer_id id, int param,
}
}
- if (end_of_row || m_end_of_screen)
+ if (blank_row || end_of_row || m_end_of_screen)
{
vsp = 1;
}
diff --git a/src/devices/video/voodoo_pci.cpp b/src/devices/video/voodoo_pci.cpp
index 10d88b058e4..e8f7dad1031 100644
--- a/src/devices/video/voodoo_pci.cpp
+++ b/src/devices/video/voodoo_pci.cpp
@@ -6,31 +6,32 @@
#include "screen.h"
-MACHINE_CONFIG_START(voodoo_pci_device::device_add_mconfig)
- switch (m_type) {
- case TYPE_VOODOO_1:
- MCFG_DEVICE_ADD("voodoo", VOODOO_1, STD_VOODOO_1_CLOCK)
- MCFG_VOODOO_FBMEM(4)
- MCFG_VOODOO_TMUMEM(1, 0)
- break;
- case TYPE_VOODOO_2:
- MCFG_DEVICE_ADD("voodoo", VOODOO_2, STD_VOODOO_2_CLOCK)
- MCFG_VOODOO_FBMEM(4)
- MCFG_VOODOO_TMUMEM(1, 0)
- break;
- case TYPE_VOODOO_BANSHEE:
- MCFG_DEVICE_ADD("voodoo", VOODOO_BANSHEE, STD_VOODOO_BANSHEE_CLOCK)
- MCFG_VOODOO_FBMEM(16)
- break;
- //case TYPE_VOODOO_3
- default:
- MCFG_DEVICE_ADD("voodoo", VOODOO_3, STD_VOODOO_3_CLOCK)
- MCFG_VOODOO_FBMEM(16)
- break;}
+MACHINE_CONFIG_START(voodoo_1_pci_device::device_add_mconfig)
+ MCFG_DEVICE_ADD("voodoo", VOODOO_1, STD_VOODOO_1_CLOCK)
+ MCFG_VOODOO_FBMEM(4)
+ MCFG_VOODOO_TMUMEM(1, 0)
+MACHINE_CONFIG_END
+
+MACHINE_CONFIG_START(voodoo_2_pci_device::device_add_mconfig)
+ MCFG_DEVICE_ADD("voodoo", VOODOO_2, STD_VOODOO_2_CLOCK)
+ MCFG_VOODOO_FBMEM(4)
+ MCFG_VOODOO_TMUMEM(1, 0)
+MACHINE_CONFIG_END
+
+MACHINE_CONFIG_START(voodoo_banshee_pci_device::device_add_mconfig)
+ MCFG_DEVICE_ADD("voodoo", VOODOO_BANSHEE, STD_VOODOO_BANSHEE_CLOCK)
+ MCFG_VOODOO_FBMEM(16)
MACHINE_CONFIG_END
+MACHINE_CONFIG_START(voodoo_3_pci_device::device_add_mconfig)
+ MCFG_DEVICE_ADD("voodoo", VOODOO_3, STD_VOODOO_3_CLOCK)
+ MCFG_VOODOO_FBMEM(16)
+MACHINE_CONFIG_END
-DEFINE_DEVICE_TYPE(VOODOO_PCI, voodoo_pci_device, "voodoo_pci", "Voodoo PCI")
+DEFINE_DEVICE_TYPE(VOODOO_1_PCI, voodoo_1_pci_device, "voodoo_1_pci", "Voodoo 1 PCI")
+DEFINE_DEVICE_TYPE(VOODOO_2_PCI, voodoo_2_pci_device, "voodoo_2_pci", "Voodoo 2 PCI")
+DEFINE_DEVICE_TYPE(VOODOO_BANSHEE_PCI, voodoo_banshee_pci_device, "voodoo_banshee_pci", "Voodoo Banshee PCI")
+DEFINE_DEVICE_TYPE(VOODOO_3_PCI, voodoo_3_pci_device, "voodoo_3_pci", "Voodoo 3 PCI")
void voodoo_pci_device::config_map(address_map &map)
{
@@ -59,12 +60,32 @@ void voodoo_pci_device::io_map(address_map &map)
map(0x000, 0x0ff).rw("voodoo", FUNC(voodoo_banshee_device::banshee_io_r), FUNC(voodoo_banshee_device::banshee_io_w));
}
-voodoo_pci_device::voodoo_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock)
- : pci_device(mconfig, VOODOO_PCI, tag, owner, clock),
+voodoo_pci_device::voodoo_pci_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock)
+ : pci_device(mconfig, type, tag, owner, clock),
m_voodoo(*this, "voodoo"), m_cpu(*this, finder_base::DUMMY_TAG), m_screen(*this, finder_base::DUMMY_TAG), m_fbmem(2), m_tmumem0(0), m_tmumem1(0)
{
}
+voodoo_1_pci_device::voodoo_1_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock)
+ : voodoo_pci_device(mconfig, VOODOO_1_PCI, tag, owner, clock)
+{
+}
+
+voodoo_2_pci_device::voodoo_2_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock)
+ : voodoo_pci_device(mconfig, VOODOO_2_PCI, tag, owner, clock)
+{
+}
+
+voodoo_banshee_pci_device::voodoo_banshee_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock)
+ : voodoo_pci_device(mconfig, VOODOO_BANSHEE_PCI, tag, owner, clock)
+{
+}
+
+voodoo_3_pci_device::voodoo_3_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock)
+ : voodoo_pci_device(mconfig, VOODOO_3_PCI, tag, owner, clock)
+{
+}
+
void voodoo_pci_device::device_start()
{
if (m_cpu)
@@ -73,38 +94,60 @@ void voodoo_pci_device::device_start()
m_voodoo->set_screen(*m_screen);
m_voodoo->set_fbmem(m_fbmem);
m_voodoo->set_tmumem(m_tmumem0, m_tmumem1);
- switch (m_type) {
- //void set_ids(uint32_t main_id, uint8_t revision, uint32_t pclass, uint32_t subsystem_id);
- case TYPE_VOODOO_1:
- set_ids(0x121a0001, 0x02, 0x030000, 0x000000);
- break;
- case TYPE_VOODOO_2:
- set_ids(0x121a0002, 0x02, 0x038000, 0x000000);
- break;
- case TYPE_VOODOO_BANSHEE:
- set_ids(0x121a0003, 0x02, 0x030000, 0x000000);
- break;
- //case TYPE_VOODOO_3
- default:
- set_ids(0x121a0005, 0x02, 0x030000, 0x000000);
- break;
- }
pci_device::device_start();
- if (m_type<=TYPE_VOODOO_2) {
- add_map(16*1024*1024, M_MEM | M_PREF, FUNC(voodoo_pci_device::voodoo_reg_map));
- bank_infos[0].adr = 0xff000000;
- } else {
- add_map(32*1024*1024, M_MEM, FUNC(voodoo_pci_device::banshee_reg_map));
- add_map(32*1024*1024, M_MEM, FUNC(voodoo_pci_device::lfb_map));
- add_map(256, M_IO, FUNC(voodoo_pci_device::io_map));
- bank_infos[0].adr = 0xf8000000;
- bank_infos[1].adr = 0xf8000008;
- bank_infos[2].adr = 0xfffffff0;
- }
save_item(NAME(m_pcictrl_reg));
machine().save().register_postload(save_prepost_delegate(FUNC(voodoo_pci_device::postload), this));
}
+//void set_ids(uint32_t main_id, uint8_t revision, uint32_t pclass, uint32_t subsystem_id);
+void voodoo_1_pci_device::device_start()
+{
+ set_ids(0x121a0001, 0x02, 0x030000, 0x000000);
+
+ voodoo_pci_device::device_start();
+
+ add_map(16 * 1024 * 1024, M_MEM | M_PREF, FUNC(voodoo_pci_device::voodoo_reg_map));
+ bank_infos[0].adr = 0xff000000;
+}
+
+void voodoo_2_pci_device::device_start()
+{
+ set_ids(0x121a0002, 0x02, 0x038000, 0x000000);
+
+ voodoo_pci_device::device_start();
+
+ add_map(16 * 1024 * 1024, M_MEM | M_PREF, FUNC(voodoo_pci_device::voodoo_reg_map));
+ bank_infos[0].adr = 0xff000000;
+}
+
+void voodoo_banshee_pci_device::device_start()
+{
+ set_ids(0x121a0003, 0x02, 0x030000, 0x000000);
+
+ voodoo_pci_device::device_start();
+
+ add_map(32 * 1024 * 1024, M_MEM, FUNC(voodoo_pci_device::banshee_reg_map));
+ add_map(32 * 1024 * 1024, M_MEM, FUNC(voodoo_pci_device::lfb_map));
+ add_map(256, M_IO, FUNC(voodoo_pci_device::io_map));
+ bank_infos[0].adr = 0xf8000000;
+ bank_infos[1].adr = 0xf8000008;
+ bank_infos[2].adr = 0xfffffff0;
+}
+
+void voodoo_3_pci_device::device_start()
+{
+ set_ids(0x121a0005, 0x02, 0x030000, 0x000000);
+
+ voodoo_pci_device::device_start();
+
+ add_map(32 * 1024 * 1024, M_MEM, FUNC(voodoo_pci_device::banshee_reg_map));
+ add_map(32 * 1024 * 1024, M_MEM, FUNC(voodoo_pci_device::lfb_map));
+ add_map(256, M_IO, FUNC(voodoo_pci_device::io_map));
+ bank_infos[0].adr = 0xf8000000;
+ bank_infos[1].adr = 0xf8000008;
+ bank_infos[2].adr = 0xfffffff0;
+}
+
void voodoo_pci_device::postload()
{
remap_cb();
@@ -120,14 +163,32 @@ void voodoo_pci_device::map_extra(uint64_t memory_window_start, uint64_t memory_
uint64_t io_window_start, uint64_t io_window_end, uint64_t io_offset, address_space *io_space)
{
logerror("%s: map_extra\n", this->tag());
+}
+
+void voodoo_banshee_pci_device::map_extra(uint64_t memory_window_start, uint64_t memory_window_end, uint64_t memory_offset, address_space *memory_space,
+ uint64_t io_window_start, uint64_t io_window_end, uint64_t io_offset, address_space *io_space)
+{
+ logerror("%s: map_extra\n", this->tag());
+
// Map VGA legacy access
// Should really be dependent on voodoo VGAINIT0 bit 8 and IO base + 0xc3 bit 0
- if (m_type>=TYPE_VOODOO_BANSHEE) {
- uint64_t start = io_offset + 0x3b0;
- uint64_t end = io_offset + 0x3df;
- io_space->install_readwrite_handler(start, end, read32_delegate(FUNC(voodoo_pci_device::vga_r), this), write32_delegate(FUNC(voodoo_pci_device::vga_w), this));
- logerror("%s: map %s at %0*x-%0*x\n", this->tag(), "vga_r/w", 4, uint32_t(start), 4, uint32_t(end));
- }
+ uint64_t start = io_offset + 0x3b0;
+ uint64_t end = io_offset + 0x3df;
+ io_space->install_readwrite_handler(start, end, read32_delegate(FUNC(voodoo_pci_device::vga_r), this), write32_delegate(FUNC(voodoo_pci_device::vga_w), this));
+ logerror("%s: map %s at %0*x-%0*x\n", this->tag(), "vga_r/w", 4, uint32_t(start), 4, uint32_t(end));
+}
+
+void voodoo_3_pci_device::map_extra(uint64_t memory_window_start, uint64_t memory_window_end, uint64_t memory_offset, address_space *memory_space,
+ uint64_t io_window_start, uint64_t io_window_end, uint64_t io_offset, address_space *io_space)
+{
+ logerror("%s: map_extra\n", this->tag());
+
+ // Map VGA legacy access
+ // Should really be dependent on voodoo VGAINIT0 bit 8 and IO base + 0xc3 bit 0
+ uint64_t start = io_offset + 0x3b0;
+ uint64_t end = io_offset + 0x3df;
+ io_space->install_readwrite_handler(start, end, read32_delegate(FUNC(voodoo_pci_device::vga_r), this), write32_delegate(FUNC(voodoo_pci_device::vga_w), this));
+ logerror("%s: map %s at %0*x-%0*x\n", this->tag(), "vga_r/w", 4, uint32_t(start), 4, uint32_t(end));
}
uint32_t voodoo_pci_device::screen_update(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect)
diff --git a/src/devices/video/voodoo_pci.h b/src/devices/video/voodoo_pci.h
index cf1fdbebb6d..3a67f241eeb 100644
--- a/src/devices/video/voodoo_pci.h
+++ b/src/devices/video/voodoo_pci.h
@@ -16,56 +16,128 @@
#define MCFG_VOODOO_PCI_TMUMEM(_value1, _value2) \
downcast<voodoo_pci_device &>(*device).set_tmumem(_value1, _value2);
-class voodoo_pci_device : public pci_device {
+class voodoo_pci_device : public pci_device
+{
public:
- template <typename T, typename U>
- voodoo_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, int type, T &&cpu_tag, U &&screen_tag)
- : voodoo_pci_device(mconfig, tag, owner, clock)
- {
- set_type(type);
- set_cpu_tag(std::forward<T>(cpu_tag));
- set_screen_tag(std::forward<U>(screen_tag));
- }
+ template <typename T> void set_cpu_tag(T &&tag) { m_cpu.set_tag(std::forward<T>(tag)); }
+ template <typename T> void set_screen_tag(T &&tag) { m_screen.set_tag(std::forward<T>(tag)); }
+ void set_fbmem(int fbmem) { m_fbmem = fbmem; }
+ void set_tmumem(int tmumem0, int tmumem1) { m_tmumem0 = tmumem0; m_tmumem1 = tmumem1; }
+ uint32_t screen_update(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
+
+ DECLARE_READ32_MEMBER(vga_r);
+ DECLARE_WRITE32_MEMBER(vga_w);
+
+ void voodoo_reg_map(address_map &map);
+ void banshee_reg_map(address_map &map);
+ void lfb_map(address_map &map);
+ void io_map(address_map &map);
+
+protected:
+ voodoo_pci_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock);
- voodoo_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
virtual void map_extra(uint64_t memory_window_start, uint64_t memory_window_end, uint64_t memory_offset, address_space *memory_space,
uint64_t io_window_start, uint64_t io_window_end, uint64_t io_offset, address_space *io_space) override;
- uint32_t screen_update(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
virtual void config_map(address_map &map) override;
void postload(void);
- template <typename T> void set_cpu_tag(T &&tag) { m_cpu.set_tag(std::forward<T>(tag)); }
- template <typename T> void set_screen_tag(T &&tag) { m_screen.set_tag(std::forward<T>(tag)); }
- void set_type(int type) {m_type = type;}
- void set_fbmem(int fbmem) {m_fbmem = fbmem;}
- void set_tmumem(int tmumem0, int tmumem1) {m_tmumem0 = tmumem0; m_tmumem1 = tmumem1;}
-
- DECLARE_READ32_MEMBER(vga_r);
- DECLARE_WRITE32_MEMBER(vga_w);
-protected:
virtual void device_start() override;
virtual void device_reset() override;
- virtual void device_add_mconfig(machine_config &config) override;
-private:
required_device<voodoo_device> m_voodoo;
optional_device<cpu_device> m_cpu;
optional_device<screen_device> m_screen;
- int m_type;
int m_fbmem, m_tmumem0, m_tmumem1;
uint32_t m_pcictrl_reg[0x20];
- void voodoo_reg_map(address_map &map);
- void banshee_reg_map(address_map &map);
- void lfb_map(address_map &map);
- void io_map(address_map &map);
DECLARE_READ32_MEMBER(pcictrl_r);
DECLARE_WRITE32_MEMBER(pcictrl_w);
};
-DECLARE_DEVICE_TYPE(VOODOO_PCI, voodoo_pci_device)
+class voodoo_1_pci_device : public voodoo_pci_device
+{
+public:
+ template <typename T, typename U>
+ voodoo_1_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&cpu_tag, U &&screen_tag)
+ : voodoo_1_pci_device(mconfig, tag, owner, clock)
+ {
+ set_cpu_tag(std::forward<T>(cpu_tag));
+ set_screen_tag(std::forward<U>(screen_tag));
+ }
+
+ voodoo_1_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
+
+protected:
+ virtual void device_start() override;
+ virtual void device_add_mconfig(machine_config &config) override;
+};
+
+class voodoo_2_pci_device : public voodoo_pci_device
+{
+public:
+ template <typename T, typename U>
+ voodoo_2_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&cpu_tag, U &&screen_tag)
+ : voodoo_2_pci_device(mconfig, tag, owner, clock)
+ {
+ set_cpu_tag(std::forward<T>(cpu_tag));
+ set_screen_tag(std::forward<U>(screen_tag));
+ }
+
+ voodoo_2_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
+
+protected:
+ virtual void device_start() override;
+ virtual void device_add_mconfig(machine_config &config) override;
+};
+
+class voodoo_banshee_pci_device : public voodoo_pci_device
+{
+public:
+ template <typename T, typename U>
+ voodoo_banshee_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&cpu_tag, U &&screen_tag)
+ : voodoo_banshee_pci_device(mconfig, tag, owner, clock)
+ {
+ set_cpu_tag(std::forward<T>(cpu_tag));
+ set_screen_tag(std::forward<U>(screen_tag));
+ }
+
+ voodoo_banshee_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
+
+protected:
+ virtual void device_start() override;
+ virtual void device_add_mconfig(machine_config &config) override;
+
+ virtual void map_extra(uint64_t memory_window_start, uint64_t memory_window_end, uint64_t memory_offset, address_space *memory_space,
+ uint64_t io_window_start, uint64_t io_window_end, uint64_t io_offset, address_space *io_space) override;
+};
+
+class voodoo_3_pci_device : public voodoo_pci_device
+{
+public:
+ template <typename T, typename U>
+ voodoo_3_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&cpu_tag, U &&screen_tag)
+ : voodoo_3_pci_device(mconfig, tag, owner, clock)
+ {
+ set_cpu_tag(std::forward<T>(cpu_tag));
+ set_screen_tag(std::forward<U>(screen_tag));
+ }
+
+ voodoo_3_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
+
+protected:
+ virtual void device_start() override;
+ virtual void device_add_mconfig(machine_config &config) override;
+
+ virtual void map_extra(uint64_t memory_window_start, uint64_t memory_window_end, uint64_t memory_offset, address_space *memory_space,
+ uint64_t io_window_start, uint64_t io_window_end, uint64_t io_offset, address_space *io_space) override;
+};
+
+DECLARE_DEVICE_TYPE(VOODOO_1_PCI, voodoo_1_pci_device)
+DECLARE_DEVICE_TYPE(VOODOO_2_PCI, voodoo_2_pci_device)
+DECLARE_DEVICE_TYPE(VOODOO_BANSHEE_PCI, voodoo_banshee_pci_device)
+DECLARE_DEVICE_TYPE(VOODOO_3_PCI, voodoo_3_pci_device)
#endif // MAME_VIDEO_VOODOO_PCI_H
diff --git a/src/mame/arcade.flt b/src/mame/arcade.flt
index 99b786f88b8..0d98285792a 100644
--- a/src/mame/arcade.flt
+++ b/src/mame/arcade.flt
@@ -429,6 +429,7 @@ galpanic.cpp
galspnbl.cpp
gambl186.cpp
gamecstl.cpp
+gamemasters.cpp
gameplan.cpp
gammagic.cpp
gamtor.cpp
diff --git a/src/mame/audio/dcs.cpp b/src/mame/audio/dcs.cpp
index 073310c110a..cea1961e2b0 100644
--- a/src/mame/audio/dcs.cpp
+++ b/src/mame/audio/dcs.cpp
@@ -1631,9 +1631,6 @@ void dcs_audio_device::ack_w()
uint16_t dcs_audio_device::data_r()
{
- if IS_OUTPUT_EMPTY()
- return m_output_data;
-
/* data is actually only 8 bit (read from d8-d15, which is d0-d7 from the data access instructions POV) on early dcs, but goes 16 on later (seattle) */
if (m_last_output_full && !m_output_full_cb.isnull())
m_output_full_cb(m_last_output_full = 0);
diff --git a/src/mame/drivers/apogee.cpp b/src/mame/drivers/apogee.cpp
index 44b8bd4b2fb..d602192eb47 100644
--- a/src/mame/drivers/apogee.cpp
+++ b/src/mame/drivers/apogee.cpp
@@ -179,8 +179,6 @@ I8275_DRAW_CHARACTER_MEMBER(apogee_state::display_pixels)
const rgb_t *palette = m_palette->palette()->entry_list_raw();
const uint8_t *charmap = m_charmap + (gpa & 1) * 0x400;
uint8_t pixels = charmap[(linecount & 7) + (charcode << 3)] ^ 0xff;
- if(linecount == 8)
- pixels = 0;
if (vsp) {
pixels = 0;
}
diff --git a/src/mame/drivers/gamemasters.cpp b/src/mame/drivers/gamemasters.cpp
new file mode 100644
index 00000000000..612e9324d3d
--- /dev/null
+++ b/src/mame/drivers/gamemasters.cpp
@@ -0,0 +1,150 @@
+// license:BSD-3-Clause
+// copyright-holders:AJR
+/****************************************************************************
+
+ Skeleton driver for redemption games by GameMasters, Inc.
+
+ Not much is known about this Atlanta-based company and its games, aside
+ from a number of flyers.
+
+****************************************************************************/
+
+#include "emu.h"
+
+#include "cpu/m6502/r65c02.h"
+#include "machine/nvram.h"
+//#include "machine/ticket.h"
+#include "sound/ay8910.h"
+#include "speaker.h"
+
+
+class gamemasters_state : public driver_device
+{
+public:
+ gamemasters_state(const machine_config &mconfig, device_type type, const char *tag)
+ : driver_device(mconfig, type, tag)
+ , m_maincpu(*this, "maincpu")
+ {
+ }
+
+ void gmsshoot(machine_config &config);
+private:
+ DECLARE_WRITE8_MEMBER(output_1100);
+ DECLARE_WRITE8_MEMBER(output_1300);
+ DECLARE_WRITE8_MEMBER(output_1520);
+ DECLARE_WRITE8_MEMBER(output_1540);
+
+ void mem_map(address_map &map);
+
+ required_device<cpu_device> m_maincpu;
+};
+
+
+WRITE8_MEMBER(gamemasters_state::output_1100)
+{
+ logerror("%s: Writing %02X to 1100\n", machine().describe_context(), data);
+}
+
+WRITE8_MEMBER(gamemasters_state::output_1300)
+{
+ logerror("%s: Writing %02X to 1300\n", machine().describe_context(), data);
+}
+
+WRITE8_MEMBER(gamemasters_state::output_1520)
+{
+ logerror("%s: Writing %02X to 1520\n", machine().describe_context(), data);
+}
+
+WRITE8_MEMBER(gamemasters_state::output_1540)
+{
+ logerror("%s: Writing %02X to 1540 + %X\n", machine().describe_context(), data, offset);
+}
+
+void gamemasters_state::mem_map(address_map &map)
+{
+ map(0x0000, 0x07ff).ram().share("nvram");
+ map(0x1100, 0x1100).w(this, FUNC(gamemasters_state::output_1300));
+ map(0x1300, 0x1300).w(this, FUNC(gamemasters_state::output_1300));
+ map(0x1400, 0x1400).portr("IN0");
+ map(0x1500, 0x1500).portr("IN1");
+ map(0x1520, 0x1520).w(this, FUNC(gamemasters_state::output_1520));
+ map(0x1540, 0x1540).select(0x20).w(this, FUNC(gamemasters_state::output_1540));
+ map(0x1600, 0x1601).w("aysnd", FUNC(ay8910_device::data_address_w));
+ map(0x1601, 0x1601).r("aysnd", FUNC(ay8910_device::data_r));
+ map(0xe000, 0xffff).rom().region("maincpu", 0);
+}
+
+
+MACHINE_CONFIG_START(gamemasters_state::gmsshoot)
+ MCFG_DEVICE_ADD("maincpu", R65C02, 4_MHz_XTAL / 4) // divider not verified
+ MCFG_DEVICE_PROGRAM_MAP(mem_map)
+
+ MCFG_NVRAM_ADD_0FILL("nvram") // MK48Z02B-25
+
+ // LCD video?
+
+ SPEAKER(config, "mono").front_center();
+ MCFG_DEVICE_ADD("aysnd", AY8912, 4_MHz_XTAL / 4)
+ MCFG_AY8910_PORT_A_READ_CB(IOPORT("DSW"))
+ MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.30)
+MACHINE_CONFIG_END
+
+
+static INPUT_PORTS_START(gmsshoot)
+ // Flyer: "Sharpshooter can be set to have quarters or tokens in, and/or quarters or tokens out."
+ // "Ticket Dispenser" and "Optional Dollar Bill Acceptor" are also mentioned as features.
+ PORT_START("DSW")
+ PORT_DIPNAME(0x01, 0x00, DEF_STR(Unknown)) PORT_DIPLOCATION("SW2:1")
+ PORT_DIPSETTING(0x01, DEF_STR(Off))
+ PORT_DIPSETTING(0x00, DEF_STR(On))
+ PORT_DIPNAME(0x02, 0x00, DEF_STR(Unknown)) PORT_DIPLOCATION("SW2:2")
+ PORT_DIPSETTING(0x02, DEF_STR(Off))
+ PORT_DIPSETTING(0x00, DEF_STR(On))
+ PORT_DIPNAME(0x04, 0x00, DEF_STR(Unknown)) PORT_DIPLOCATION("SW2:3")
+ PORT_DIPSETTING(0x04, DEF_STR(Off))
+ PORT_DIPSETTING(0x00, DEF_STR(On))
+ PORT_DIPNAME(0x08, 0x08, DEF_STR(Unknown)) PORT_DIPLOCATION("SW2:4")
+ PORT_DIPSETTING(0x08, DEF_STR(Off))
+ PORT_DIPSETTING(0x00, DEF_STR(On))
+ PORT_DIPNAME(0x10, 0x10, DEF_STR(Unknown)) PORT_DIPLOCATION("SW2:5")
+ PORT_DIPSETTING(0x10, DEF_STR(Off))
+ PORT_DIPSETTING(0x00, DEF_STR(On))
+ PORT_DIPNAME(0x20, 0x00, DEF_STR(Unknown)) PORT_DIPLOCATION("SW2:6")
+ PORT_DIPSETTING(0x20, DEF_STR(Off))
+ PORT_DIPSETTING(0x00, DEF_STR(On))
+ PORT_DIPNAME(0x40, 0x00, DEF_STR(Unknown)) PORT_DIPLOCATION("SW2:7")
+ PORT_DIPSETTING(0x40, DEF_STR(Off))
+ PORT_DIPSETTING(0x00, DEF_STR(On))
+ PORT_DIPNAME(0x80, 0x00, DEF_STR(Unknown)) PORT_DIPLOCATION("SW2:8")
+ PORT_DIPSETTING(0x80, DEF_STR(Off))
+ PORT_DIPSETTING(0x00, DEF_STR(On))
+
+ PORT_START("IN0")
+ PORT_BIT(0x01, 0x01, IPT_UNKNOWN)
+ PORT_BIT(0x02, 0x02, IPT_UNKNOWN)
+ PORT_BIT(0x04, 0x04, IPT_UNKNOWN)
+ PORT_BIT(0x08, 0x08, IPT_UNKNOWN)
+ PORT_BIT(0x10, 0x10, IPT_UNKNOWN)
+ PORT_BIT(0x20, 0x20, IPT_UNKNOWN)
+ PORT_BIT(0x40, 0x40, IPT_UNKNOWN)
+ PORT_BIT(0x80, 0x80, IPT_UNUSED)
+
+ PORT_START("IN1")
+ PORT_BIT(0x01, 0x01, IPT_UNUSED)
+ PORT_BIT(0x02, 0x02, IPT_UNKNOWN)
+ PORT_BIT(0x04, 0x04, IPT_UNKNOWN)
+ PORT_BIT(0x08, 0x08, IPT_UNKNOWN)
+ PORT_BIT(0x10, 0x10, IPT_UNKNOWN)
+ PORT_BIT(0x20, 0x20, IPT_UNKNOWN)
+ PORT_BIT(0x40, 0x40, IPT_UNKNOWN)
+ PORT_BIT(0x80, 0x80, IPT_UNKNOWN)
+INPUT_PORTS_END
+
+
+ROM_START(gmsshoot)
+ ROM_REGION(0x2000, "maincpu", 0)
+ ROM_LOAD("sharp_shooter__u20_2764.bin", 0x0000, 0x2000, CRC(902bd63b) SHA1(606e9d1083677d7eb90ad3626a6340238a260253)) // M2764AFI
+ROM_END
+
+
+GAME(1989, gmsshoot, 0, gmsshoot, gmsshoot, gamemasters_state, empty_init, ROT0, "GameMasters", "Sharpshooter (coin pusher)", MACHINE_IS_SKELETON_MECHANICAL) // flyer and PCB dated 1988, but program strings claim 1989 copyright
diff --git a/src/mame/drivers/imds2.cpp b/src/mame/drivers/imds2.cpp
index 91d1cd56c35..87ab54fea92 100644
--- a/src/mame/drivers/imds2.cpp
+++ b/src/mame/drivers/imds2.cpp
@@ -525,7 +525,7 @@ I8275_DRAW_CHARACTER_MEMBER(imds2_state::crtc_display_pixels)
if (lten) {
pixels = ~0;
} else if (vsp != 0 || (linecount & 8) != 0) {
- pixels = 0;
+ pixels = 0; // VSP is gated with LC3
} else {
// See [2], pg 58 for the very peculiar way of generating character images
// Here each half-pixel is translated into a full pixel
diff --git a/src/mame/drivers/iteagle.cpp b/src/mame/drivers/iteagle.cpp
index eacb00aa0f3..60b3729b5ec 100644
--- a/src/mame/drivers/iteagle.cpp
+++ b/src/mame/drivers/iteagle.cpp
@@ -183,7 +183,7 @@ MACHINE_CONFIG_START(iteagle_state::iteagle)
MCFG_SOUND_ROUTE(1, PCI_ID_SOUND":rspeaker", 1.0)
MCFG_ES1373_IRQ_ADD( ":maincpu", MIPS3_IRQ3)
- MCFG_DEVICE_ADD(PCI_ID_VIDEO, VOODOO_PCI, 0, TYPE_VOODOO_3, m_maincpu, "screen")
+ MCFG_DEVICE_ADD(PCI_ID_VIDEO, VOODOO_3_PCI, 0, m_maincpu, "screen")
MCFG_VOODOO_PCI_FBMEM(16)
MCFG_DEVICE_MODIFY(PCI_ID_VIDEO":voodoo")
MCFG_VOODOO_VBLANK_CB(WRITELINE(PCI_ID_FPGA, iteagle_fpga_device, vblank_update))
@@ -295,7 +295,7 @@ MACHINE_CONFIG_START(iteagle_state::virtpool)
MCFG_DEVICE_CLOCK(99999999)
MCFG_MIPS3_SYSTEM_CLOCK(33333333)
- MCFG_DEVICE_REPLACE(PCI_ID_VIDEO, VOODOO_PCI, 0, TYPE_VOODOO_1, m_maincpu, "screen")
+ MCFG_DEVICE_REPLACE(PCI_ID_VIDEO, VOODOO_1_PCI, 0, m_maincpu, "screen")
MCFG_VOODOO_PCI_FBMEM(4)
MCFG_VOODOO_PCI_TMUMEM(4, 4)
diff --git a/src/mame/drivers/mikrosha.cpp b/src/mame/drivers/mikrosha.cpp
index 2b578241d3c..a8ffef44475 100644
--- a/src/mame/drivers/mikrosha.cpp
+++ b/src/mame/drivers/mikrosha.cpp
@@ -171,8 +171,6 @@ I8275_DRAW_CHARACTER_MEMBER(mikrosha_state::display_pixels)
const rgb_t *palette = m_palette->palette()->entry_list_raw();
const uint8_t *charmap = m_charmap + (m_mikrosha_font_page & 1) * 0x400;
uint8_t pixels = charmap[(linecount & 7) + (charcode << 3)] ^ 0xff;
- if(linecount == 8)
- pixels = 0;
if (vsp) {
pixels = 0;
}
diff --git a/src/mame/drivers/rungun.cpp b/src/mame/drivers/rungun.cpp
index 43fd8c63380..51530bb5afd 100644
--- a/src/mame/drivers/rungun.cpp
+++ b/src/mame/drivers/rungun.cpp
@@ -14,6 +14,12 @@
Status: Front tilemap should be complete, sprites are mostly correct, controls
should be fine.
+ Known Issues:
+ - CRTC and video registers needs syncronization with current video draw state, it's very noticeable if for example scroll values are in very different states between screens.
+ - Current draw state could be improved optimization-wise (for example by supporting it in the core in some way).
+ - sprite palettes are not entirely right (fixed?)
+ - sound volume mixing, handtune with set_gain() with m_k054539 devices.
+ Also notice that "volume" in sound options is for k054539_1 (SFX)
Change Log:
@@ -27,11 +33,6 @@
video\konamiic.c
- missing sprites and priority
- Known Issues:
- - CRTC and video registers needs syncronization with current video draw state, it's very noticeable if for example scroll values are in very different states between screens.
- - Current draw state could be improved optimization-wise (for example by supporting it in the core in some way).
- - sprite palettes are not entirely right
-
*************************************************************************/
@@ -49,7 +50,7 @@
-READ16_MEMBER(rungun_state::rng_sysregs_r)
+READ16_MEMBER(rungun_state::sysregs_r)
{
uint16_t data = 0;
@@ -85,7 +86,7 @@ READ16_MEMBER(rungun_state::rng_sysregs_r)
return m_sysreg[offset];
}
-WRITE16_MEMBER(rungun_state::rng_sysregs_w)
+WRITE16_MEMBER(rungun_state::sysregs_w)
{
COMBINE_DATA(m_sysreg + offset);
@@ -108,6 +109,9 @@ WRITE16_MEMBER(rungun_state::rng_sysregs_w)
membank("spriteram_bank")->set_entry((data & 0x80) >> 7);
m_video_mux_bank = ((data & 0x80) >> 7) ^ 1;
ioport("EEPROMOUT")->write(data, 0xff);
+
+ machine().bookkeeping().coin_counter_w(0, data & 0x08);
+ machine().bookkeeping().coin_counter_w(1, data & 0x10);
}
if (ACCESSING_BITS_8_15)
{
@@ -148,7 +152,7 @@ INTERRUPT_GEN_MEMBER(rungun_state::rng_interrupt)
device.execute().set_input_line(M68K_IRQ_5, ASSERT_LINE);
}
-READ8_MEMBER(rungun_state::rng_53936_rom_r)
+READ8_MEMBER(rungun_state::k53936_rom_r)
{
// TODO: odd addresses returns ...?
uint32_t rom_addr = offset;
@@ -181,8 +185,8 @@ void rungun_state::rungun_map(address_map &map)
map(0x000000, 0x2fffff).rom(); // main program + data
map(0x300000, 0x3007ff).rw(this, FUNC(rungun_state::palette_read), FUNC(rungun_state::palette_write));
map(0x380000, 0x39ffff).ram(); // work RAM
- map(0x400000, 0x43ffff).r(this, FUNC(rungun_state::rng_53936_rom_r)).umask16(0x00ff); // '936 ROM readback window
- map(0x480000, 0x48001f).rw(this, FUNC(rungun_state::rng_sysregs_r), FUNC(rungun_state::rng_sysregs_w)).share("sysreg");
+ map(0x400000, 0x43ffff).r(this, FUNC(rungun_state::k53936_rom_r)).umask16(0x00ff); // '936 ROM readback window
+ map(0x480000, 0x48001f).rw(this, FUNC(rungun_state::sysregs_r), FUNC(rungun_state::sysregs_w)).share("sysreg");
map(0x4c0000, 0x4c001f).rw(m_k053252, FUNC(k053252_device::read), FUNC(k053252_device::write)).umask16(0x00ff); // CCU (for scanline and vblank polling)
map(0x540000, 0x540001).w(this, FUNC(rungun_state::sound_irq_w));
map(0x580000, 0x58001f).m(m_k054321, FUNC(k054321_device::main_map)).umask16(0xff00);
@@ -191,9 +195,9 @@ void rungun_state::rungun_map(address_map &map)
map(0x600000, 0x601fff).bankrw("spriteram_bank"); // OBJ RAM
map(0x640000, 0x640007).w(m_k055673, FUNC(k055673_device::k053246_word_w)); // '246A registers
map(0x680000, 0x68001f).w(m_k053936, FUNC(k053936_device::ctrl_w)); // '936 registers
- map(0x6c0000, 0x6cffff).rw(this, FUNC(rungun_state::rng_psac2_videoram_r), FUNC(rungun_state::rng_psac2_videoram_w)); // PSAC2 ('936) RAM (34v + 35v)
+ map(0x6c0000, 0x6cffff).rw(this, FUNC(rungun_state::psac2_videoram_r), FUNC(rungun_state::psac2_videoram_w)); // PSAC2 ('936) RAM (34v + 35v)
map(0x700000, 0x7007ff).rw(m_k053936, FUNC(k053936_device::linectrl_r), FUNC(k053936_device::linectrl_w)); // PSAC "Line RAM"
- map(0x740000, 0x741fff).rw(this, FUNC(rungun_state::rng_ttl_ram_r), FUNC(rungun_state::rng_ttl_ram_w)); // text plane RAM
+ map(0x740000, 0x741fff).rw(this, FUNC(rungun_state::ttl_ram_r), FUNC(rungun_state::ttl_ram_w)); // text plane RAM
map(0x7c0000, 0x7c0001).nopw(); // watchdog
}
@@ -252,7 +256,7 @@ void rungun_state::rungun_sound_map(address_map &map)
}
-void rungun_state::rungun_k054539_map(address_map &map)
+void rungun_state::k054539_map(address_map &map)
{
map(0x000000, 0x3fffff).rom().region("k054539", 0);
}
@@ -379,6 +383,7 @@ void rungun_state::machine_start()
save_item(NAME(m_sound_status));
save_item(NAME(m_sound_nmi_clk));
//save_item(NAME(m_ttl_vram));
+
}
void rungun_state::machine_reset()
@@ -448,16 +453,18 @@ MACHINE_CONFIG_START(rungun_state::rng)
MCFG_K054321_ADD("k054321", "lspeaker", "rspeaker")
+ // SFX
MCFG_DEVICE_ADD("k054539_1", K054539, XTAL(18'432'000))
- MCFG_DEVICE_ADDRESS_MAP(0, rungun_k054539_map)
+ MCFG_DEVICE_ADDRESS_MAP(0, k054539_map)
MCFG_K054539_TIMER_HANDLER(WRITELINE(*this, rungun_state, k054539_nmi_gen))
MCFG_SOUND_ROUTE(0, "lspeaker", 1.0)
MCFG_SOUND_ROUTE(1, "rspeaker", 1.0)
+ // BGM, volumes handtuned to make SFXs heardable (still not 100% right tho)
MCFG_DEVICE_ADD("k054539_2", K054539, XTAL(18'432'000))
- MCFG_DEVICE_ADDRESS_MAP(0, rungun_k054539_map)
- MCFG_SOUND_ROUTE(0, "lspeaker", 1.0)
- MCFG_SOUND_ROUTE(1, "rspeaker", 1.0)
+ MCFG_DEVICE_ADDRESS_MAP(0, k054539_map)
+ MCFG_SOUND_ROUTE(0, "lspeaker", 0.25)
+ MCFG_SOUND_ROUTE(1, "rspeaker", 0.25)
MACHINE_CONFIG_END
// for dual-screen output Run and Gun requires the video de-multiplexer board connected to the Jamma output, this gives you 2 Jamma connectors, one for each screen.
diff --git a/src/mame/drivers/seattle.cpp b/src/mame/drivers/seattle.cpp
index bdb49648154..9b0d2be10bd 100644
--- a/src/mame/drivers/seattle.cpp
+++ b/src/mame/drivers/seattle.cpp
@@ -1892,7 +1892,7 @@ MACHINE_CONFIG_START(seattle_state::seattle_common)
MCFG_IDE_PCI_IRQ_ADD(":maincpu", IDE_IRQ_NUM)
MCFG_IDE_PCI_SET_LEGACY_TOP(0x0a0)
- MCFG_DEVICE_ADD(PCI_ID_VIDEO, VOODOO_PCI, 0, TYPE_VOODOO_1, m_maincpu, m_screen)
+ MCFG_DEVICE_ADD(PCI_ID_VIDEO, VOODOO_1_PCI, 0, m_maincpu, m_screen)
MCFG_VOODOO_PCI_FBMEM(2)
MCFG_VOODOO_PCI_TMUMEM(4, 0)
MCFG_DEVICE_MODIFY(PCI_ID_VIDEO":voodoo")
diff --git a/src/mame/drivers/unior.cpp b/src/mame/drivers/unior.cpp
index 6ac1a62d3ac..aaedeb1cfd4 100644
--- a/src/mame/drivers/unior.cpp
+++ b/src/mame/drivers/unior.cpp
@@ -266,9 +266,6 @@ I8275_DRAW_CHARACTER_MEMBER(unior_state::display_pixels)
const rgb_t *palette = m_palette->palette()->entry_list_raw();
uint8_t gfx = m_p_chargen[(linecount & 7) | (charcode << 3)];
- if(linecount == 8)
- gfx = 0;
-
if (vsp)
gfx = 0;
diff --git a/src/mame/drivers/vamphalf.cpp b/src/mame/drivers/vamphalf.cpp
index ccb7b9c6ea6..974c5dd6a1f 100644
--- a/src/mame/drivers/vamphalf.cpp
+++ b/src/mame/drivers/vamphalf.cpp
@@ -14,6 +14,7 @@
Jumping Break (c) 1999 F2 System
Poosho Poosho (c) 1999 F2 System
New Cross Pang (c) 1999 F2 System
+ World Adventure (c) 1999 F2 System + Logic
Lup Lup Puzzle (c) 1999 Omega System (version 3.0, 2.9 and 1.05)
Puzzle Bang Bang (c) 1999 Omega System (version 2.8 and 2.9)
Super Lup Lup Puzzle (c) 1999 Omega System (version 4.0)
@@ -49,8 +50,6 @@
Undumped Semicom games on similar hardware:
Red Wyvern - A semi-sequel or update?
Choice III: Joker's Dream (c) 2001 (likely SEMICOM-003 hardware)
- Undumped F2 System games on F-E1-16-002 hardware:
- World Adventure
TODO:
- boonggab: simulate photo sensors with a "stroke strength"
@@ -78,67 +77,113 @@ public:
vamphalf_state(const machine_config &mconfig, device_type type, const char *tag)
: driver_device(mconfig, type, tag)
, m_maincpu(*this, "maincpu")
- , m_eeprom(*this, "eeprom")
- , m_gfxdecode(*this, "gfxdecode")
+ , m_wram(*this,"wram")
+ , m_wram32(*this,"wram32")
+ , m_okibank(*this,"okibank")
, m_palette(*this, "palette")
, m_soundlatch(*this, "soundlatch")
+ , m_eeprom(*this, "eeprom")
+ , m_gfxdecode(*this, "gfxdecode")
, m_tiles(*this,"tiles")
- , m_wram(*this,"wram")
, m_tiles32(*this,"tiles32")
- , m_wram32(*this,"wram32")
, m_okiregion(*this, "oki%u", 1)
- , m_okibank(*this,"okibank")
, m_photosensors(*this, "PHOTO_SENSORS")
+ , m_has_extra_gfx(0)
{
- m_has_extra_gfx = 0;
}
+ void common(machine_config &config);
+ void sound_ym_oki(machine_config &config);
+ void sound_ym_banked_oki(machine_config &config);
+ void sound_suplup(machine_config &config);
+ void sound_qs1000(machine_config &config);
+ void mrdig(machine_config &config);
+ void suplup(machine_config &config);
+ void vamphalf(machine_config &config);
+ void boonggab(machine_config &config);
+ void jmpbreak(machine_config &config);
+ void newxpang(machine_config &config);
+ void worldadv(machine_config &config);
+ void aoh(machine_config &config);
+ void coolmini(machine_config &config);
+ void mrkicker(machine_config &config);
+
+ void init_vamphalf();
+ void init_vamphalfr1();
+ void init_vamphafk();
+ void init_coolmini();
+ void init_coolminii();
+ void init_mrdig();
+ void init_jmpbreak();
+ void init_poosho();
+ void init_newxpang();
+ void init_worldadv();
+ void init_dtfamily();
+ void init_dquizgo2();
+ void init_suplup();
+ void init_luplup();
+ void init_luplup29();
+ void init_luplup10();
+ void init_puzlbang();
+ void init_toyland();
+ void init_aoh();
+ void init_boonggab();
+ void init_mrkicker();
+
+ DECLARE_CUSTOM_INPUT_MEMBER(boonggab_photo_sensors_r);
+
+ DECLARE_READ16_MEMBER(eeprom_r);
+ DECLARE_READ32_MEMBER(eeprom32_r);
+ DECLARE_WRITE16_MEMBER(eeprom_w);
+ DECLARE_WRITE32_MEMBER(eeprom32_w);
+ DECLARE_WRITE16_MEMBER(flipscreen_w);
+ DECLARE_WRITE32_MEMBER(flipscreen32_w);
+
+ void banked_oki(int chip);
+
+ void common_map(address_map &map);
+ void common_32bit_map(address_map &map);
+
+protected:
+ int m_flip_bit;
+ int m_palshift;
+
required_device<cpu_device> m_maincpu;
- required_device<eeprom_serial_93cxx_device> m_eeprom;
- required_device<gfxdecode_device> m_gfxdecode;
+ optional_shared_ptr<uint16_t> m_wram;
+ optional_shared_ptr<uint32_t> m_wram32;
+
+ uint16_t m_semicom_prot_data[2];
+ int m_semicom_prot_idx;
+ int m_semicom_prot_which;
+
+ int irq_active();
+
+ optional_memory_bank m_okibank;
required_device<palette_device> m_palette;
optional_device<generic_latch_8_device> m_soundlatch;
+ required_device<eeprom_serial_93cxx_device> m_eeprom;
+
+private:
+ required_device<gfxdecode_device> m_gfxdecode;
optional_shared_ptr<uint16_t> m_tiles;
- optional_shared_ptr<uint16_t> m_wram;
optional_shared_ptr<uint32_t> m_tiles32;
- optional_shared_ptr<uint32_t> m_wram32;
optional_memory_region_array<2> m_okiregion;
- optional_memory_bank m_okibank;
optional_ioport m_photosensors;
// driver init configuration
- int m_flip_bit;
- int m_palshift;
int m_has_extra_gfx;
- uint16_t m_semicom_prot_data[2];
-
int m_flipscreen;
- int m_semicom_prot_idx;
- int m_semicom_prot_which;
- uint16_t m_finalgdr_backupram_bank;
- std::unique_ptr<uint8_t[]> m_finalgdr_backupram;
- DECLARE_WRITE16_MEMBER(flipscreen_w);
- DECLARE_WRITE32_MEMBER(flipscreen32_w);
DECLARE_WRITE16_MEMBER(jmpbreak_flipscreen_w);
- DECLARE_READ32_MEMBER(wyvernwg_prot_r);
- DECLARE_WRITE32_MEMBER(wyvernwg_prot_w);
- DECLARE_READ32_MEMBER(finalgdr_prot_r);
- DECLARE_WRITE32_MEMBER(finalgdr_prot_w);
- DECLARE_WRITE32_MEMBER(finalgdr_prize_w);
DECLARE_WRITE16_MEMBER(boonggab_prize_w);
DECLARE_WRITE16_MEMBER(boonggab_lamps_w);
- DECLARE_CUSTOM_INPUT_MEMBER(boonggab_photo_sensors_r);
- int irq_active();
DECLARE_READ16_MEMBER(vamphalf_speedup_r);
DECLARE_READ16_MEMBER(vamphalfr1_speedup_r);
DECLARE_READ16_MEMBER(vamphafk_speedup_r);
- DECLARE_READ16_MEMBER(misncrft_speedup_r);
- DECLARE_READ16_MEMBER(misncrfta_speedup_r);
DECLARE_READ16_MEMBER(coolmini_speedup_r);
DECLARE_READ16_MEMBER(coolminii_speedup_r);
DECLARE_READ16_MEMBER(suplup_speedup_r);
@@ -147,107 +192,116 @@ public:
DECLARE_READ16_MEMBER(luplup10_speedup_r);
DECLARE_READ16_MEMBER(puzlbang_speedup_r);
DECLARE_READ16_MEMBER(puzlbanga_speedup_r);
- DECLARE_READ32_MEMBER(wivernwg_speedup_r);
- DECLARE_READ32_MEMBER(wyvernwg_speedup_r);
- DECLARE_READ32_MEMBER(wyvernwga_speedup_r);
- DECLARE_READ32_MEMBER(finalgdr_speedup_r);
- DECLARE_READ32_MEMBER(mrkickera_speedup_r);
DECLARE_READ16_MEMBER(mrkicker_speedup_r);
DECLARE_READ16_MEMBER(dquizgo2_speedup_r);
DECLARE_READ32_MEMBER(aoh_speedup_r);
DECLARE_READ16_MEMBER(jmpbreak_speedup_r);
DECLARE_READ16_MEMBER(poosho_speedup_r);
DECLARE_READ16_MEMBER(newxpang_speedup_r);
+ DECLARE_READ16_MEMBER(worldadv_speedup_r);
DECLARE_READ16_MEMBER(mrdig_speedup_r);
DECLARE_READ16_MEMBER(dtfamily_speedup_r);
DECLARE_READ16_MEMBER(toyland_speedup_r);
DECLARE_READ16_MEMBER(boonggab_speedup_r);
- DECLARE_READ16_MEMBER(eeprom_r);
- DECLARE_READ32_MEMBER(eeprom32_r);
- DECLARE_WRITE16_MEMBER(eeprom_w);
- DECLARE_WRITE32_MEMBER(eeprom32_w);
- DECLARE_WRITE32_MEMBER(finalgdr_eeprom_w);
- DECLARE_WRITE32_MEMBER(finalgdr_backupram_bank_w);
- DECLARE_READ32_MEMBER(finalgdr_backupram_r);
- DECLARE_WRITE32_MEMBER(finalgdr_backupram_w);
-
- DECLARE_WRITE32_MEMBER(finalgdr_oki_bank_w);
DECLARE_WRITE32_MEMBER(aoh_oki_bank_w);
DECLARE_WRITE16_MEMBER(boonggab_oki_bank_w);
DECLARE_WRITE16_MEMBER(mrkicker_oki_bank_w);
DECLARE_WRITE8_MEMBER(qs1000_p3_w);
virtual void video_start() override;
- void init_vamphalf();
- void init_vamphalfr1();
- void init_vamphafk();
- void init_coolmini();
- void init_coolminii();
- void init_mrkickera();
- void init_mrdig();
- void init_jmpbreak();
- void init_poosho();
- void init_newxpang();
- void init_dtfamily();
- void init_dquizgo2();
- void init_suplup();
- void init_luplup();
- void init_luplup29();
- void init_luplup10();
- void init_puzlbang();
- void init_toyland();
- void init_aoh();
- void init_finalgdr();
- void init_misncrft();
- void init_boonggab();
- void init_wyvernwg();
- void init_yorijori();
- void init_mrkicker();
uint32_t screen_update_common(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
uint32_t screen_update_aoh(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
void draw_sprites(screen_device &screen, bitmap_ind16 &bitmap);
void draw_sprites_aoh(screen_device &screen, bitmap_ind16 &bitmap);
void handle_flipped_visible_area(screen_device &screen);
- void banked_oki(int chip);
- void common(machine_config &config);
- void sound_ym_oki(machine_config &config);
- void sound_ym_banked_oki(machine_config &config);
- void sound_suplup(machine_config &config);
- void sound_qs1000(machine_config &config);
- void mrkickera(machine_config &config);
- void mrdig(machine_config &config);
- void misncrft(machine_config &config);
- void suplup(machine_config &config);
- void vamphalf(machine_config &config);
- void yorijori(machine_config &config);
- void finalgdr(machine_config &config);
- void wyvernwg(machine_config &config);
- void boonggab(machine_config &config);
- void jmpbreak(machine_config &config);
- void newxpang(machine_config &config);
- void aoh(machine_config &config);
- void coolmini(machine_config &config);
- void mrkicker(machine_config &config);
void aoh_io(address_map &map);
void aoh_map(address_map &map);
void banked_oki_map(address_map &map);
void boonggab_io(address_map &map);
- void common_32bit_map(address_map &map);
- void common_map(address_map &map);
void coolmini_io(address_map &map);
- void finalgdr_io(address_map &map);
void jmpbreak_io(address_map &map);
- void misncrft_io(address_map &map);
+ void worldadv_io(address_map &map);
void mrdig_io(address_map &map);
void mrkicker_io(address_map &map);
- void mrkickera_io(address_map &map);
void suplup_io(address_map &map);
void vamphalf_io(address_map &map);
- void wyvernwg_io(address_map &map);
+};
+
+class vamphalf_qdsp_state : public vamphalf_state
+{
+public:
+ vamphalf_qdsp_state(const machine_config &mconfig, device_type type, const char *tag)
+ : vamphalf_state(mconfig, type, tag)
+ , m_qdsp_cpu(*this, "qs1000:cpu")
+ {
+ }
+
+ void misncrft(machine_config &config);
+ void yorijori(machine_config &config);
+ void wyvernwg(machine_config &config);
+
+ void init_misncrft();
+ void init_yorijori();
+ void init_wyvernwg();
+
+private:
+ required_device<i8052_device> m_qdsp_cpu;
+
+ DECLARE_READ16_MEMBER(misncrft_speedup_r);
+ DECLARE_READ16_MEMBER(misncrfta_speedup_r);
+ DECLARE_READ32_MEMBER(wivernwg_speedup_r);
+ DECLARE_READ32_MEMBER(wyvernwg_speedup_r);
+ DECLARE_READ32_MEMBER(wyvernwga_speedup_r);
+
+ DECLARE_READ32_MEMBER(wyvernwg_prot_r);
+ DECLARE_WRITE32_MEMBER(wyvernwg_prot_w);
+
void yorijori_32bit_map(address_map &map);
void yorijori_io(address_map &map);
+ void misncrft_io(address_map &map);
+ void wyvernwg_io(address_map &map);
+};
+
+class vamphalf_nvram_state : public vamphalf_state
+{
+public:
+ vamphalf_nvram_state(const machine_config &mconfig, device_type type, const char *tag)
+ : vamphalf_state(mconfig, type, tag)
+ , m_nvram(*this, "nvram")
+ {
+ }
+
+ void finalgdr(machine_config &config);
+ void mrkickera(machine_config &config);
+
+ void init_mrkickera();
+ void init_finalgdr();
+
+private:
+
+ void finalgdr_io(address_map &map);
+ void mrkickera_io(address_map &map);
+
+ required_device<nvram_device> m_nvram;
+
+ uint16_t m_finalgdr_backupram_bank;
+ std::unique_ptr<uint8_t[]> m_finalgdr_backupram;
+ DECLARE_WRITE32_MEMBER(finalgdr_backupram_bank_w);
+ DECLARE_READ32_MEMBER(finalgdr_backupram_r);
+ DECLARE_WRITE32_MEMBER(finalgdr_backupram_w);
+
+ DECLARE_READ32_MEMBER(finalgdr_prot_r);
+ DECLARE_WRITE32_MEMBER(finalgdr_prot_w);
+
+ DECLARE_READ32_MEMBER(finalgdr_speedup_r);
+ DECLARE_READ32_MEMBER(mrkickera_speedup_r);
+
+ DECLARE_WRITE32_MEMBER(finalgdr_prize_w);
+ DECLARE_WRITE32_MEMBER(finalgdr_oki_bank_w);
+
+ DECLARE_WRITE32_MEMBER(finalgdr_eeprom_w);
};
READ16_MEMBER(vamphalf_state::eeprom_r)
@@ -284,7 +338,7 @@ WRITE32_MEMBER(vamphalf_state::eeprom32_w)
m_eeprom->clk_write((data & 0x02) ? ASSERT_LINE : CLEAR_LINE );
}
-WRITE32_MEMBER(vamphalf_state::finalgdr_eeprom_w)
+WRITE32_MEMBER(vamphalf_nvram_state::finalgdr_eeprom_w)
{
m_eeprom->di_write((data & 0x4000) >> 14);
m_eeprom->cs_write((data & 0x1000) ? ASSERT_LINE : CLEAR_LINE );
@@ -311,25 +365,25 @@ WRITE16_MEMBER(vamphalf_state::jmpbreak_flipscreen_w)
-READ32_MEMBER(vamphalf_state::wyvernwg_prot_r)
+READ32_MEMBER(vamphalf_qdsp_state::wyvernwg_prot_r)
{
m_semicom_prot_idx--;
return (m_semicom_prot_data[m_semicom_prot_which] & (1 << m_semicom_prot_idx)) >> m_semicom_prot_idx;
}
-WRITE32_MEMBER(vamphalf_state::wyvernwg_prot_w)
+WRITE32_MEMBER(vamphalf_qdsp_state::wyvernwg_prot_w)
{
m_semicom_prot_which = data & 1;
m_semicom_prot_idx = 8;
}
-READ32_MEMBER(vamphalf_state::finalgdr_prot_r)
+READ32_MEMBER(vamphalf_nvram_state::finalgdr_prot_r)
{
m_semicom_prot_idx--;
return (m_semicom_prot_data[m_semicom_prot_which] & (1 << m_semicom_prot_idx)) ? 0x8000 : 0;
}
-WRITE32_MEMBER(vamphalf_state::finalgdr_prot_w)
+WRITE32_MEMBER(vamphalf_nvram_state::finalgdr_prot_w)
{
/*
41C6
@@ -345,27 +399,27 @@ F94B
m_semicom_prot_idx = 8;
}
-WRITE32_MEMBER(vamphalf_state::finalgdr_oki_bank_w)
+WRITE32_MEMBER(vamphalf_nvram_state::finalgdr_oki_bank_w)
{
m_okibank->set_entry((data & 0x300) >> 8);
}
-WRITE32_MEMBER(vamphalf_state::finalgdr_backupram_bank_w)
+WRITE32_MEMBER(vamphalf_nvram_state::finalgdr_backupram_bank_w)
{
m_finalgdr_backupram_bank = (data & 0xff000000) >> 24;
}
-READ32_MEMBER(vamphalf_state::finalgdr_backupram_r)
+READ32_MEMBER(vamphalf_nvram_state::finalgdr_backupram_r)
{
return m_finalgdr_backupram[offset + m_finalgdr_backupram_bank * 0x80] << 24;
}
-WRITE32_MEMBER(vamphalf_state::finalgdr_backupram_w)
+WRITE32_MEMBER(vamphalf_nvram_state::finalgdr_backupram_w)
{
m_finalgdr_backupram[offset + m_finalgdr_backupram_bank * 0x80] = data >> 24;
}
-WRITE32_MEMBER(vamphalf_state::finalgdr_prize_w)
+WRITE32_MEMBER(vamphalf_nvram_state::finalgdr_prize_w)
{
if(data & 0x1000000)
{
@@ -464,7 +518,7 @@ void vamphalf_state::common_32bit_map(address_map &map)
map(0xfff00000, 0xffffffff).rom().region("maincpu", 0);
}
-void vamphalf_state::yorijori_32bit_map(address_map &map)
+void vamphalf_qdsp_state::yorijori_32bit_map(address_map &map)
{
map(0x00000000, 0x001fffff).ram().share("wram32");
map(0x40000000, 0x4003ffff).ram().share("tiles32");
@@ -485,7 +539,7 @@ void vamphalf_state::vamphalf_io(address_map &map)
map(0x608, 0x60b).w(this, FUNC(vamphalf_state::eeprom_w));
}
-void vamphalf_state::misncrft_io(address_map &map)
+void vamphalf_qdsp_state::misncrft_io(address_map &map)
{
map(0x100, 0x103).w(this, FUNC(vamphalf_state::flipscreen_w));
map(0x200, 0x203).portr("P1_P2");
@@ -526,9 +580,9 @@ void vamphalf_state::suplup_io(address_map &map)
map(0x100, 0x103).r(this, FUNC(vamphalf_state::eeprom_r));
}
-void vamphalf_state::wyvernwg_io(address_map &map)
+void vamphalf_qdsp_state::wyvernwg_io(address_map &map)
{
- map(0x1800, 0x1803).rw(this, FUNC(vamphalf_state::wyvernwg_prot_r), FUNC(vamphalf_state::wyvernwg_prot_w));
+ map(0x1800, 0x1803).rw(this, FUNC(vamphalf_qdsp_state::wyvernwg_prot_r), FUNC(vamphalf_qdsp_state::wyvernwg_prot_w));
map(0x2000, 0x2003).w(this, FUNC(vamphalf_state::flipscreen32_w));
map(0x2800, 0x2803).portr("P1_P2");
map(0x3000, 0x3003).portr("SYSTEM");
@@ -537,33 +591,33 @@ void vamphalf_state::wyvernwg_io(address_map &map)
map(0x7c00, 0x7c03).r(this, FUNC(vamphalf_state::eeprom32_r));
}
-void vamphalf_state::finalgdr_io(address_map &map)
+void vamphalf_nvram_state::finalgdr_io(address_map &map)
{
- map(0x2400, 0x2403).r(this, FUNC(vamphalf_state::finalgdr_prot_r));
- map(0x2800, 0x2803).w(this, FUNC(vamphalf_state::finalgdr_backupram_bank_w));
- map(0x2c00, 0x2dff).rw(this, FUNC(vamphalf_state::finalgdr_backupram_r), FUNC(vamphalf_state::finalgdr_backupram_w));
+ map(0x2400, 0x2403).r(this, FUNC(vamphalf_nvram_state::finalgdr_prot_r));
+ map(0x2800, 0x2803).w(this, FUNC(vamphalf_nvram_state::finalgdr_backupram_bank_w));
+ map(0x2c00, 0x2dff).rw(this, FUNC(vamphalf_nvram_state::finalgdr_backupram_r), FUNC(vamphalf_nvram_state::finalgdr_backupram_w));
map(0x3000, 0x3007).rw("ymsnd", FUNC(ym2151_device::read), FUNC(ym2151_device::write)).umask32(0x0000ff00);
map(0x3800, 0x3803).portr("P1_P2");
map(0x3402, 0x3402).rw("oki1", FUNC(okim6295_device::read), FUNC(okim6295_device::write));
map(0x3c00, 0x3c03).portr("SYSTEM");
map(0x4400, 0x4403).r(this, FUNC(vamphalf_state::eeprom32_r));
map(0x6000, 0x6003).nopr(); //?
- map(0x6000, 0x6003).w(this, FUNC(vamphalf_state::finalgdr_eeprom_w));
- map(0x6040, 0x6043).w(this, FUNC(vamphalf_state::finalgdr_prot_w));
+ map(0x6000, 0x6003).w(this, FUNC(vamphalf_nvram_state::finalgdr_eeprom_w));
+ map(0x6040, 0x6043).w(this, FUNC(vamphalf_nvram_state::finalgdr_prot_w));
//AM_RANGE(0x6080, 0x6083) AM_WRITE(flipscreen32_w) //?
- map(0x6060, 0x6063).w(this, FUNC(vamphalf_state::finalgdr_prize_w));
- map(0x60a0, 0x60a3).w(this, FUNC(vamphalf_state::finalgdr_oki_bank_w));
+ map(0x6060, 0x6063).w(this, FUNC(vamphalf_nvram_state::finalgdr_prize_w));
+ map(0x60a0, 0x60a3).w(this, FUNC(vamphalf_nvram_state::finalgdr_oki_bank_w));
}
-void vamphalf_state::mrkickera_io(address_map &map)
+void vamphalf_nvram_state::mrkickera_io(address_map &map)
{
map(0x2400, 0x2403).r(this, FUNC(vamphalf_state::eeprom32_r));
map(0x4000, 0x4003).nopr(); //?
- map(0x4000, 0x4003).w(this, FUNC(vamphalf_state::finalgdr_eeprom_w));
- map(0x4040, 0x4043).w(this, FUNC(vamphalf_state::finalgdr_prot_w));
+ map(0x4000, 0x4003).w(this, FUNC(vamphalf_nvram_state::finalgdr_eeprom_w));
+ map(0x4040, 0x4043).w(this, FUNC(vamphalf_nvram_state::finalgdr_prot_w));
map(0x4084, 0x4087).nopw(); //?
- map(0x40a0, 0x40a3).w(this, FUNC(vamphalf_state::finalgdr_oki_bank_w));
- map(0x6400, 0x6403).r(this, FUNC(vamphalf_state::finalgdr_prot_r));
+ map(0x40a0, 0x40a3).w(this, FUNC(vamphalf_nvram_state::finalgdr_oki_bank_w));
+ map(0x6400, 0x6403).r(this, FUNC(vamphalf_nvram_state::finalgdr_prot_r));
map(0x7000, 0x7007).rw("ymsnd", FUNC(ym2151_device::read), FUNC(ym2151_device::write)).umask32(0x0000ff00);
map(0x7402, 0x7402).rw("oki1", FUNC(okim6295_device::read), FUNC(okim6295_device::write));
map(0x7800, 0x7803).portr("P1_P2");
@@ -584,6 +638,18 @@ void vamphalf_state::jmpbreak_io(address_map &map)
map(0x684, 0x687).rw("ymsnd", FUNC(ym2151_device::status_r), FUNC(ym2151_device::data_w)).umask16(0x00ff);
}
+void vamphalf_state::worldadv_io(address_map &map)
+{
+ map(0x180, 0x183).w(this, FUNC(vamphalf_state::eeprom_w));
+ map(0x780, 0x783).r(this, FUNC(vamphalf_state::eeprom_r));
+ map(0x640, 0x641).noprw(); // return 0, when oki chip is read / written
+ map(0x643, 0x643).rw("oki1", FUNC(okim6295_device::read), FUNC(okim6295_device::write));
+ map(0x280, 0x283).portr("P1_P2");
+ map(0x340, 0x343).portr("SYSTEM");
+ map(0x700, 0x703).w("ymsnd", FUNC(ym2151_device::register_w)).umask16(0x00ff);
+ map(0x704, 0x707).rw("ymsnd", FUNC(ym2151_device::status_r), FUNC(ym2151_device::data_w)).umask16(0x00ff);
+}
+
void vamphalf_state::mrdig_io(address_map &map)
{
map(0x500, 0x503).portr("P1_P2");
@@ -632,7 +698,7 @@ void vamphalf_state::boonggab_io(address_map &map)
map(0x747, 0x747).rw("ymsnd", FUNC(ym2151_device::status_r), FUNC(ym2151_device::data_w));
}
-void vamphalf_state::yorijori_io(address_map &map)
+void vamphalf_qdsp_state::yorijori_io(address_map &map)
{
}
@@ -1120,7 +1186,7 @@ MACHINE_CONFIG_START(vamphalf_state::vamphalf)
sound_ym_oki(config);
MACHINE_CONFIG_END
-MACHINE_CONFIG_START(vamphalf_state::misncrft)
+MACHINE_CONFIG_START(vamphalf_qdsp_state::misncrft)
common(config);
MCFG_DEVICE_REPLACE("maincpu", GMS30C2116, XTAL(50'000'000)) /* 50 MHz */
MCFG_DEVICE_PROGRAM_MAP(common_map)
@@ -1171,6 +1237,15 @@ MACHINE_CONFIG_START(vamphalf_state::newxpang)
sound_ym_oki(config);
MACHINE_CONFIG_END
+MACHINE_CONFIG_START(vamphalf_state::worldadv)
+ common(config);
+ MCFG_DEVICE_MODIFY("maincpu")
+ MCFG_DEVICE_IO_MAP(worldadv_io)
+ MCFG_DEVICE_VBLANK_INT_DRIVER("screen", vamphalf_state, irq1_line_hold)
+
+ sound_ym_oki(config);
+MACHINE_CONFIG_END
+
MACHINE_CONFIG_START(vamphalf_state::mrdig)
common(config);
MCFG_DEVICE_REPLACE("maincpu", GMS30C2116, XTAL(50'000'000)) /* 50 MHz */
@@ -1182,7 +1257,7 @@ MACHINE_CONFIG_START(vamphalf_state::mrdig)
sound_ym_oki(config);
MACHINE_CONFIG_END
-MACHINE_CONFIG_START(vamphalf_state::wyvernwg)
+MACHINE_CONFIG_START(vamphalf_qdsp_state::wyvernwg)
common(config);
MCFG_DEVICE_REPLACE("maincpu", E132T, XTAL(50'000'000)) /* 50 MHz */
MCFG_DEVICE_PROGRAM_MAP(common_32bit_map)
@@ -1192,7 +1267,7 @@ MACHINE_CONFIG_START(vamphalf_state::wyvernwg)
sound_qs1000(config);
MACHINE_CONFIG_END
-MACHINE_CONFIG_START(vamphalf_state::finalgdr)
+MACHINE_CONFIG_START(vamphalf_nvram_state::finalgdr)
common(config);
MCFG_DEVICE_REPLACE("maincpu", E132T, XTAL(50'000'000)) /* 50 MHz */
MCFG_DEVICE_PROGRAM_MAP(common_32bit_map)
@@ -1204,7 +1279,7 @@ MACHINE_CONFIG_START(vamphalf_state::finalgdr)
sound_ym_banked_oki(config);
MACHINE_CONFIG_END
-MACHINE_CONFIG_START(vamphalf_state::mrkickera)
+MACHINE_CONFIG_START(vamphalf_nvram_state::mrkickera)
common(config);
MCFG_DEVICE_REPLACE("maincpu", E132T, XTAL(50'000'000)) /* 50 MHz */
MCFG_DEVICE_PROGRAM_MAP(common_32bit_map)
@@ -1265,7 +1340,7 @@ MACHINE_CONFIG_START(vamphalf_state::boonggab)
sound_ym_banked_oki(config);
MACHINE_CONFIG_END
-MACHINE_CONFIG_START(vamphalf_state::yorijori)
+MACHINE_CONFIG_START(vamphalf_qdsp_state::yorijori)
common(config);
MCFG_DEVICE_REPLACE("maincpu", E132T, XTAL(50'000'000)) /* 50 MHz */
MCFG_DEVICE_PROGRAM_MAP(yorijori_32bit_map)
@@ -1701,6 +1776,77 @@ ROM_END
/*
+World Adventure
+F2 System, 1999
+
+F-E1-16-002
++----------------------------------------------+
+| VR1 M6295 VROM1 28MHz |
+| YM3012 |
+| YM2151 MEM2 |
+| MEM3 |
+| CRAM1 MEM5 |
+| CRAM2 MEM7 |
+|J |
+|A MEM1U +----------++----------+|
+|M | || ||
+|M MEM1L |Quicklogic||Quicklogic||
+|A | QL2003- || QL2003- ||
+| | XPL84C || XPL84C ||
+| | || ||
+| +----------++----------+|
+| GAL1 |
+| 93C46 DRAM1 ROM1* ROML00 ROMU00|
+|P1 P2 50MHz E1-16T ROM2 ROML01 ROMU01|
+| |
++----------------------------------------------+
+
+Notes:
+CPU: Hyperstone E1-16T @ 50.000MHz
+
+ DRAM1 - LG Semi GM71C18163 1M x16 EDO DRAM (SOJ44)
+MEMx/CRAMx - NKK N341256SJ-15 32K x8 SRAM (SOJ28)
+ GAL1 - PALCE22V10H
+
+Oki M6295 rebaged as AD-65
+YM3012/YM2151
+
+ P1 - Setup push button
+ P2 - Reset push button
+VR1 - Volume adjust pot
+
+ROMs:
+ ROML00/01, ROMU00/01 - Macronix MX29F1610MC-12 SOP44 16MBit FlashROM
+ VROM1 - TMS 27C020 2MBit DIP32 EPROM
+ ROM1 - ST M27C4001 4MBit DIP32 EPROM
+ ROM2 - ST M27C4001 4MBit DIP32 EPROM
+
+Measured Clocks:
+ E1-16T @ 50MHz
+ YM2151 @ 3.5MHz (28MHz/8)
+ M6295 @ 1.75MH (28MHz/16), Pin7 High
+ H-Sync @ 15.625KHz
+ V-Sync @ 59.189Hz
+
+*/
+
+ROM_START( worldadv ) /* Developed April 1999 */
+ ROM_REGION16_BE( 0x100000, "maincpu", ROMREGION_ERASE00 ) /* Hyperstone CPU Code */
+ ROM_LOAD( "rom1.bin", 0x00000, 0x80000, CRC(1855c235) SHA1(b4f7488365474248be8473c61bd2545e59132e44) )
+ ROM_LOAD( "rom2.bin", 0x80000, 0x80000, CRC(671ddbb0) SHA1(07f856ae33105440e08e4ae353952db4df65ad9f) )
+
+ ROM_REGION( 0x800000, "gfx", 0 ) /* 16x16x8 Sprites */
+ ROM_LOAD32_WORD( "roml00.bin", 0x000000, 0x200000, CRC(fe422890) SHA1(98c52f924345718a3b86d49b42b8c6fbba596da7) )
+ ROM_LOAD32_WORD( "romu00.bin", 0x000002, 0x200000, CRC(dd1066f5) SHA1(bf10217404eebbddc8bc639e86ca77f935e0b148) )
+ ROM_LOAD32_WORD( "roml01.bin", 0x400000, 0x200000, CRC(9ab76649) SHA1(ba4ae12638e1b25e77e7b7d20e6518bf9ce6bd1b) )
+ ROM_LOAD32_WORD( "romu01.bin", 0x400002, 0x200000, CRC(62132228) SHA1(7588fa90424ce4e557d1f43d3944cb89e007d63b) )
+
+ ROM_REGION( 0x40000, "oki1", 0 ) /* Oki Samples */
+ ROM_LOAD( "vrom1.bin", 0x00000, 0x40000, CRC(c87cce3b) SHA1(0b189fee8fb87c8fb06a67ae9d901732b89fbf38) )
+ROM_END
+
+/*
+
Mr. Dig
SUN, 2000
@@ -2748,7 +2894,7 @@ READ16_MEMBER(vamphalf_state::vamphafk_speedup_r)
return m_wram[0x4a648 / 2];
}
-READ16_MEMBER(vamphalf_state::misncrft_speedup_r)
+READ16_MEMBER(vamphalf_qdsp_state::misncrft_speedup_r)
{
if (m_maincpu->pc() == 0xff5a)
{
@@ -2761,7 +2907,7 @@ READ16_MEMBER(vamphalf_state::misncrft_speedup_r)
return m_wram[0x741e8 / 2];
}
-READ16_MEMBER(vamphalf_state::misncrfta_speedup_r)
+READ16_MEMBER(vamphalf_qdsp_state::misncrfta_speedup_r)
{
if (m_maincpu->pc() == 0xecd6)
{
@@ -2878,7 +3024,7 @@ READ16_MEMBER(vamphalf_state::puzlbanga_speedup_r)
return m_wram[0x113ecc / 2];
}
-READ32_MEMBER(vamphalf_state::wivernwg_speedup_r)
+READ32_MEMBER(vamphalf_qdsp_state::wivernwg_speedup_r)
{
if (m_maincpu->pc() == 0x10766)
{
@@ -2891,7 +3037,7 @@ READ32_MEMBER(vamphalf_state::wivernwg_speedup_r)
return m_wram32[0xb4cc4 / 4];
}
-READ32_MEMBER(vamphalf_state::wyvernwg_speedup_r)
+READ32_MEMBER(vamphalf_qdsp_state::wyvernwg_speedup_r)
{
if (m_maincpu->pc() == 0x10766)
{
@@ -2904,7 +3050,7 @@ READ32_MEMBER(vamphalf_state::wyvernwg_speedup_r)
return m_wram32[0xb56f4 / 4];
}
-READ32_MEMBER(vamphalf_state::wyvernwga_speedup_r)
+READ32_MEMBER(vamphalf_qdsp_state::wyvernwga_speedup_r)
{
if (m_maincpu->pc() == 0x10766)
{
@@ -2917,7 +3063,7 @@ READ32_MEMBER(vamphalf_state::wyvernwga_speedup_r)
return m_wram32[0xb74f0 / 4];
}
-READ32_MEMBER(vamphalf_state::finalgdr_speedup_r)
+READ32_MEMBER(vamphalf_nvram_state::finalgdr_speedup_r)
{
if (m_maincpu->pc() == 0x1c20c)
{
@@ -2930,7 +3076,7 @@ READ32_MEMBER(vamphalf_state::finalgdr_speedup_r)
return m_wram32[0x5e870 / 4];
}
-READ32_MEMBER(vamphalf_state::mrkickera_speedup_r)
+READ32_MEMBER(vamphalf_nvram_state::mrkickera_speedup_r)
{
if (m_maincpu->pc() == 0x46a30)
{
@@ -3018,6 +3164,19 @@ READ16_MEMBER(vamphalf_state::newxpang_speedup_r)
return m_wram[0x61218 / 2];
}
+READ16_MEMBER(vamphalf_state::worldadv_speedup_r)
+{
+ if (m_maincpu->pc() == 0x93ae)
+ {
+ if (irq_active())
+ m_maincpu->spin_until_interrupt();
+ else
+ m_maincpu->eat_cycles(50);
+ }
+
+ return m_wram[0xc5e78 / 2];
+}
+
READ16_MEMBER(vamphalf_state::mrdig_speedup_r)
{
if (m_maincpu->pc() == 0xae38)
@@ -3094,15 +3253,15 @@ void vamphalf_state::init_vamphafk()
m_flip_bit = 0x80;
}
-void vamphalf_state::init_misncrft()
+void vamphalf_qdsp_state::init_misncrft()
{
- m_maincpu->space(AS_PROGRAM).install_read_handler(0x000741e8, 0x000741e9, read16_delegate(FUNC(vamphalf_state::misncrft_speedup_r), this));
- m_maincpu->space(AS_PROGRAM).install_read_handler(0x00072e2c, 0x00072e2d, read16_delegate(FUNC(vamphalf_state::misncrfta_speedup_r), this));
+ m_maincpu->space(AS_PROGRAM).install_read_handler(0x000741e8, 0x000741e9, read16_delegate(FUNC(vamphalf_qdsp_state::misncrft_speedup_r), this));
+ m_maincpu->space(AS_PROGRAM).install_read_handler(0x00072e2c, 0x00072e2d, read16_delegate(FUNC(vamphalf_qdsp_state::misncrfta_speedup_r), this));
m_palshift = 0;
m_flip_bit = 1;
// Configure the QS1000 ROM banking. Care must be taken not to overlap the 256b internal RAM
- machine().device("qs1000:cpu")->memory().space(AS_IO).install_read_bank(0x0100, 0xffff, "data");
+ m_qdsp_cpu->space(AS_IO).install_read_bank(0x0100, 0xffff, "data");
membank("qs1000:data")->configure_entries(0, 16, memregion("qs1000:cpu")->base()+0x100, 0x8000-0x100);
}
@@ -3172,11 +3331,11 @@ void vamphalf_state::init_puzlbang()
/* no flipscreen */
}
-void vamphalf_state::init_wyvernwg()
+void vamphalf_qdsp_state::init_wyvernwg()
{
- m_maincpu->space(AS_PROGRAM).install_read_handler(0x00b4cc4, 0x00b4cc7, read32_delegate(FUNC(vamphalf_state::wivernwg_speedup_r), this));
- m_maincpu->space(AS_PROGRAM).install_read_handler(0x00b56f4, 0x00b56f7, read32_delegate(FUNC(vamphalf_state::wyvernwg_speedup_r), this));
- m_maincpu->space(AS_PROGRAM).install_read_handler(0x00b74f0, 0x00b74f3, read32_delegate(FUNC(vamphalf_state::wyvernwga_speedup_r), this));
+ m_maincpu->space(AS_PROGRAM).install_read_handler(0x00b4cc4, 0x00b4cc7, read32_delegate(FUNC(vamphalf_qdsp_state::wivernwg_speedup_r), this));
+ m_maincpu->space(AS_PROGRAM).install_read_handler(0x00b56f4, 0x00b56f7, read32_delegate(FUNC(vamphalf_qdsp_state::wyvernwg_speedup_r), this));
+ m_maincpu->space(AS_PROGRAM).install_read_handler(0x00b74f0, 0x00b74f3, read32_delegate(FUNC(vamphalf_qdsp_state::wyvernwga_speedup_r), this));
m_palshift = 0;
m_flip_bit = 1;
@@ -3185,14 +3344,14 @@ void vamphalf_state::init_wyvernwg()
m_semicom_prot_data[1] = 1;
// Configure the QS1000 ROM banking. Care must be taken not to overlap the 256b internal RAM
- machine().device("qs1000:cpu")->memory().space(AS_IO).install_read_bank(0x0100, 0xffff, "data");
+ m_qdsp_cpu->space(AS_IO).install_read_bank(0x0100, 0xffff, "data");
membank("qs1000:data")->configure_entries(0, 16, memregion("qs1000:cpu")->base()+0x100, 0x8000-0x100);
save_item(NAME(m_semicom_prot_idx));
save_item(NAME(m_semicom_prot_which));
}
-void vamphalf_state::init_yorijori()
+void vamphalf_qdsp_state::init_yorijori()
{
// seems close to Final Godori in terms of port mappings, possibly a SemiCom game?
@@ -3209,17 +3368,17 @@ void vamphalf_state::init_yorijori()
// romx[BYTE4_XOR_BE(0x8ff1)] = 0;
// Configure the QS1000 ROM banking. Care must be taken not to overlap the 256b internal RAM
- machine().device("qs1000:cpu")->memory().space(AS_IO).install_read_bank(0x0100, 0xffff, "data");
+ m_qdsp_cpu->space(AS_IO).install_read_bank(0x0100, 0xffff, "data");
membank("qs1000:data")->configure_entries(0, 16, memregion("qs1000:cpu")->base()+0x100, 0x8000-0x100);
}
-void vamphalf_state::init_finalgdr()
+void vamphalf_nvram_state::init_finalgdr()
{
banked_oki(0);
m_finalgdr_backupram_bank = 1;
m_finalgdr_backupram = std::make_unique<uint8_t[]>(0x80*0x100);
- m_maincpu->space(AS_PROGRAM).install_read_handler(0x005e870, 0x005e873, read32_delegate(FUNC(vamphalf_state::finalgdr_speedup_r), this));
- machine().device<nvram_device>("nvram")->set_base(m_finalgdr_backupram.get(), 0x80*0x100);
+ m_maincpu->space(AS_PROGRAM).install_read_handler(0x005e870, 0x005e873, read32_delegate(FUNC(vamphalf_nvram_state::finalgdr_speedup_r), this));
+ m_nvram->set_base(m_finalgdr_backupram.get(), 0x80*0x100);
m_palshift = 0;
m_flip_bit = 1; //?
@@ -3234,14 +3393,14 @@ void vamphalf_state::init_finalgdr()
save_item(NAME(m_semicom_prot_which));
}
-void vamphalf_state::init_mrkickera()
+void vamphalf_nvram_state::init_mrkickera()
{
banked_oki(0);
// backup ram isn't used
m_finalgdr_backupram_bank = 1;
m_finalgdr_backupram = std::make_unique<uint8_t[]>(0x80*0x100);
- m_maincpu->space(AS_PROGRAM).install_read_handler(0x00701a0, 0x00701a3, read32_delegate(FUNC(vamphalf_state::mrkickera_speedup_r), this));
- machine().device<nvram_device>("nvram")->set_base(m_finalgdr_backupram.get(), 0x80*0x100);
+ m_maincpu->space(AS_PROGRAM).install_read_handler(0x00701a0, 0x00701a3, read32_delegate(FUNC(vamphalf_nvram_state::mrkickera_speedup_r), this));
+ m_nvram->set_base(m_finalgdr_backupram.get(), 0x80*0x100);
m_palshift = 0;
m_flip_bit = 1; //?
@@ -3321,6 +3480,17 @@ void vamphalf_state::init_newxpang()
m_palshift = 0;
}
+void vamphalf_state::init_worldadv()
+{
+ m_maincpu->space(AS_PROGRAM).install_read_handler(0x0c5e78, 0x0c5e79, read16_delegate(FUNC(vamphalf_state::worldadv_speedup_r), this));
+ m_maincpu->space(AS_PROGRAM).install_write_handler(0xe0000000, 0xe0000003, write16_delegate(FUNC(vamphalf_state::jmpbreak_flipscreen_w), this));
+
+ m_palshift = 0;
+}
+
+
+
+
void vamphalf_state::init_boonggab()
{
banked_oki(0);
@@ -3331,32 +3501,50 @@ void vamphalf_state::init_boonggab()
m_flip_bit = 1;
}
-GAME( 1999, coolmini, 0, coolmini, common, vamphalf_state, init_coolmini, ROT0, "SemiCom", "Cool Minigame Collection", MACHINE_SUPPORTS_SAVE )
-GAME( 1999, coolminii, coolmini, coolmini, common, vamphalf_state, init_coolminii, ROT0, "SemiCom", "Cool Minigame Collection (Italy)", MACHINE_SUPPORTS_SAVE )
-GAME( 1999, jmpbreak, 0, jmpbreak, common, vamphalf_state, init_jmpbreak, ROT0, "F2 System", "Jumping Break" , MACHINE_SUPPORTS_SAVE )
-GAME( 1999, poosho, 0, jmpbreak, common, vamphalf_state, init_poosho, ROT0, "F2 System", "Poosho Poosho" , MACHINE_SUPPORTS_SAVE )
-GAME( 1999, newxpang, 0, newxpang, common, vamphalf_state, init_newxpang, ROT0, "F2 System", "New Cross Pang" , MACHINE_SUPPORTS_SAVE )
-GAME( 1999, suplup, 0, suplup, common, vamphalf_state, init_suplup, ROT0, "Omega System", "Super Lup Lup Puzzle / Zhuan Zhuan Puzzle (version 4.0 / 990518)" , MACHINE_SUPPORTS_SAVE )
-GAME( 1999, luplup, suplup, suplup, common, vamphalf_state, init_luplup, ROT0, "Omega System", "Lup Lup Puzzle / Zhuan Zhuan Puzzle (version 3.0 / 990128)", MACHINE_SUPPORTS_SAVE )
-GAME( 1999, luplup29, suplup, suplup, common, vamphalf_state, init_luplup29, ROT0, "Omega System", "Lup Lup Puzzle / Zhuan Zhuan Puzzle (version 2.9 / 990108)", MACHINE_SUPPORTS_SAVE )
-GAME( 1999, luplup10, suplup, suplup, common, vamphalf_state, init_luplup10, ROT0, "Omega System (Adko license)", "Lup Lup Puzzle / Zhuan Zhuan Puzzle (version 1.05 / 981214)", MACHINE_SUPPORTS_SAVE )
-GAME( 1999, puzlbang, suplup, suplup, common, vamphalf_state, init_puzlbang, ROT0, "Omega System", "Puzzle Bang Bang (Korea, version 2.9 / 990108)", MACHINE_SUPPORTS_SAVE )
-GAME( 1999, puzlbanga, suplup, suplup, common, vamphalf_state, init_puzlbang, ROT0, "Omega System", "Puzzle Bang Bang (Korea, version 2.8 / 990106)", MACHINE_SUPPORTS_SAVE )
-GAME( 1999, vamphalf, 0, vamphalf, common, vamphalf_state, init_vamphalf, ROT0, "Danbi / F2 System", "Vamf x1/2 (Europe, version 1.1.0908)", MACHINE_SUPPORTS_SAVE )
-GAME( 1999, vamphalfr1, vamphalf, vamphalf, common, vamphalf_state, init_vamphalfr1,ROT0, "Danbi / F2 System", "Vamf x1/2 (Europe, version 1.0.0903)", MACHINE_SUPPORTS_SAVE )
-GAME( 1999, vamphalfk, vamphalf, vamphalf, common, vamphalf_state, init_vamphafk, ROT0, "Danbi / F2 System", "Vamp x1/2 (Korea, version 1.1.0908)", MACHINE_SUPPORTS_SAVE )
-GAME( 2000, dquizgo2, 0, coolmini, common, vamphalf_state, init_dquizgo2, ROT0, "SemiCom", "Date Quiz Go Go Episode 2" , MACHINE_SUPPORTS_SAVE )
-GAME( 2000, misncrft, 0, misncrft, common, vamphalf_state, init_misncrft, ROT90, "Sun", "Mission Craft (version 2.7)", MACHINE_IMPERFECT_SOUND | MACHINE_SUPPORTS_SAVE )
-GAME( 2000, misncrfta, misncrft, misncrft, common, vamphalf_state, init_misncrft, ROT90, "Sun", "Mission Craft (version 2.4)", MACHINE_IMPERFECT_SOUND | MACHINE_SUPPORTS_SAVE )
-GAME( 2000, mrdig, 0, mrdig, common, vamphalf_state, init_mrdig, ROT0, "Sun", "Mr. Dig", MACHINE_SUPPORTS_SAVE )
-GAME( 2001, dtfamily, 0, mrkicker, common, vamphalf_state, init_dtfamily, ROT0, "SemiCom", "Diet Family", MACHINE_SUPPORTS_SAVE )
-GAME( 2001, finalgdr, 0, finalgdr, finalgdr, vamphalf_state, init_finalgdr, ROT0, "SemiCom", "Final Godori (Korea, version 2.20.5915)", MACHINE_SUPPORTS_SAVE )
-GAME( 2001, mrkicker, 0, mrkicker, common, vamphalf_state, init_mrkicker, ROT0, "SemiCom", "Mr. Kicker (F-E1-16-010 PCB)", MACHINE_SUPPORTS_SAVE )
-GAME( 2001, mrkickera, mrkicker, mrkickera, finalgdr, vamphalf_state, init_mrkickera, ROT0, "SemiCom", "Mr. Kicker (SEMICOM-003b PCB)", MACHINE_SUPPORTS_SAVE | MACHINE_NOT_WORKING ) // if you allow eeprom saving works then this set corrupts the eeprom and then won't boot
-GAME( 2001, toyland, 0, coolmini, common, vamphalf_state, init_toyland, ROT0, "SemiCom", "Toy Land Adventure", MACHINE_SUPPORTS_SAVE )
-GAME( 2001, wivernwg, 0, wyvernwg, common, vamphalf_state, init_wyvernwg, ROT270, "SemiCom", "Wivern Wings", MACHINE_IMPERFECT_SOUND | MACHINE_SUPPORTS_SAVE )
-GAME( 2001, wyvernwg, wivernwg, wyvernwg, common, vamphalf_state, init_wyvernwg, ROT270, "SemiCom (Game Vision license)", "Wyvern Wings (set 1)", MACHINE_IMPERFECT_SOUND | MACHINE_SUPPORTS_SAVE )
-GAME( 2001, wyvernwga, wivernwg, wyvernwg, common, vamphalf_state, init_wyvernwg, ROT270, "SemiCom (Game Vision license)", "Wyvern Wings (set 2)", MACHINE_IMPERFECT_SOUND | MACHINE_SUPPORTS_SAVE )
-GAME( 2001, aoh, 0, aoh, aoh, vamphalf_state, init_aoh, ROT0, "Unico", "Age Of Heroes - Silkroad 2 (v0.63 - 2001/02/07)", MACHINE_SUPPORTS_SAVE )
-GAME( 2001, boonggab, 0, boonggab, boonggab, vamphalf_state, init_boonggab, ROT270, "Taff System", "Boong-Ga Boong-Ga (Spank'em!)", MACHINE_SUPPORTS_SAVE )
-GAME( 199?, yorijori, 0, yorijori, common, vamphalf_state, init_yorijori, ROT0, "Golden Bell Entertainment", "Yori Jori Kuk Kuk", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND | MACHINE_SUPPORTS_SAVE )
+GAME( 1999, coolmini, 0, coolmini, common, vamphalf_state, init_coolmini, ROT0, "SemiCom", "Cool Minigame Collection", MACHINE_SUPPORTS_SAVE )
+GAME( 1999, coolminii, coolmini, coolmini, common, vamphalf_state, init_coolminii, ROT0, "SemiCom", "Cool Minigame Collection (Italy)", MACHINE_SUPPORTS_SAVE )
+
+GAME( 1999, jmpbreak, 0, jmpbreak, common, vamphalf_state, init_jmpbreak, ROT0, "F2 System", "Jumping Break" , MACHINE_SUPPORTS_SAVE )
+
+GAME( 1999, poosho, 0, jmpbreak, common, vamphalf_state, init_poosho, ROT0, "F2 System", "Poosho Poosho" , MACHINE_SUPPORTS_SAVE )
+
+GAME( 1999, newxpang, 0, newxpang, common, vamphalf_state, init_newxpang, ROT0, "F2 System", "New Cross Pang" , MACHINE_SUPPORTS_SAVE )
+
+GAME( 1999, worldadv, 0, worldadv, common, vamphalf_state, init_worldadv, ROT0, "Logic / F2 System", "World Adventure" , MACHINE_SUPPORTS_SAVE )
+
+GAME( 1999, suplup, 0, suplup, common, vamphalf_state, init_suplup, ROT0, "Omega System", "Super Lup Lup Puzzle / Zhuan Zhuan Puzzle (version 4.0 / 990518)" , MACHINE_SUPPORTS_SAVE )
+GAME( 1999, luplup, suplup, suplup, common, vamphalf_state, init_luplup, ROT0, "Omega System", "Lup Lup Puzzle / Zhuan Zhuan Puzzle (version 3.0 / 990128)", MACHINE_SUPPORTS_SAVE )
+GAME( 1999, luplup29, suplup, suplup, common, vamphalf_state, init_luplup29, ROT0, "Omega System", "Lup Lup Puzzle / Zhuan Zhuan Puzzle (version 2.9 / 990108)", MACHINE_SUPPORTS_SAVE )
+GAME( 1999, luplup10, suplup, suplup, common, vamphalf_state, init_luplup10, ROT0, "Omega System (Adko license)", "Lup Lup Puzzle / Zhuan Zhuan Puzzle (version 1.05 / 981214)", MACHINE_SUPPORTS_SAVE )
+GAME( 1999, puzlbang, suplup, suplup, common, vamphalf_state, init_puzlbang, ROT0, "Omega System", "Puzzle Bang Bang (Korea, version 2.9 / 990108)", MACHINE_SUPPORTS_SAVE )
+GAME( 1999, puzlbanga, suplup, suplup, common, vamphalf_state, init_puzlbang, ROT0, "Omega System", "Puzzle Bang Bang (Korea, version 2.8 / 990106)", MACHINE_SUPPORTS_SAVE )
+
+GAME( 1999, vamphalf, 0, vamphalf, common, vamphalf_state, init_vamphalf, ROT0, "Danbi / F2 System", "Vamf x1/2 (Europe, version 1.1.0908)", MACHINE_SUPPORTS_SAVE )
+GAME( 1999, vamphalfr1, vamphalf, vamphalf, common, vamphalf_state, init_vamphalfr1,ROT0, "Danbi / F2 System", "Vamf x1/2 (Europe, version 1.0.0903)", MACHINE_SUPPORTS_SAVE )
+GAME( 1999, vamphalfk, vamphalf, vamphalf, common, vamphalf_state, init_vamphafk, ROT0, "Danbi / F2 System", "Vamp x1/2 (Korea, version 1.1.0908)", MACHINE_SUPPORTS_SAVE )
+
+GAME( 2000, dquizgo2, 0, coolmini, common, vamphalf_state, init_dquizgo2, ROT0, "SemiCom", "Date Quiz Go Go Episode 2" , MACHINE_SUPPORTS_SAVE )
+
+GAME( 2000, misncrft, 0, misncrft, common, vamphalf_qdsp_state, init_misncrft, ROT90, "Sun", "Mission Craft (version 2.7)", MACHINE_IMPERFECT_SOUND | MACHINE_SUPPORTS_SAVE )
+GAME( 2000, misncrfta, misncrft, misncrft, common, vamphalf_qdsp_state, init_misncrft, ROT90, "Sun", "Mission Craft (version 2.4)", MACHINE_IMPERFECT_SOUND | MACHINE_SUPPORTS_SAVE )
+
+GAME( 2000, mrdig, 0, mrdig, common, vamphalf_state, init_mrdig, ROT0, "Sun", "Mr. Dig", MACHINE_SUPPORTS_SAVE )
+
+GAME( 2001, dtfamily, 0, mrkicker, common, vamphalf_state, init_dtfamily, ROT0, "SemiCom", "Diet Family", MACHINE_SUPPORTS_SAVE )
+
+GAME( 2001, finalgdr, 0, finalgdr, finalgdr, vamphalf_nvram_state,init_finalgdr, ROT0, "SemiCom", "Final Godori (Korea, version 2.20.5915)", MACHINE_SUPPORTS_SAVE )
+
+GAME( 2001, mrkicker, 0, mrkicker, common, vamphalf_state, init_mrkicker, ROT0, "SemiCom", "Mr. Kicker (F-E1-16-010 PCB)", MACHINE_SUPPORTS_SAVE )
+GAME( 2001, mrkickera, mrkicker, mrkickera, finalgdr, vamphalf_nvram_state,init_mrkickera, ROT0, "SemiCom", "Mr. Kicker (SEMICOM-003b PCB)", MACHINE_SUPPORTS_SAVE | MACHINE_NOT_WORKING ) // if you allow eeprom saving works then this set corrupts the eeprom and then won't boot
+
+GAME( 2001, toyland, 0, coolmini, common, vamphalf_state, init_toyland, ROT0, "SemiCom", "Toy Land Adventure", MACHINE_SUPPORTS_SAVE )
+
+GAME( 2001, wivernwg, 0, wyvernwg, common, vamphalf_qdsp_state, init_wyvernwg, ROT270, "SemiCom", "Wivern Wings", MACHINE_IMPERFECT_SOUND | MACHINE_SUPPORTS_SAVE )
+GAME( 2001, wyvernwg, wivernwg, wyvernwg, common, vamphalf_qdsp_state, init_wyvernwg, ROT270, "SemiCom (Game Vision license)", "Wyvern Wings (set 1)", MACHINE_IMPERFECT_SOUND | MACHINE_SUPPORTS_SAVE )
+GAME( 2001, wyvernwga, wivernwg, wyvernwg, common, vamphalf_qdsp_state, init_wyvernwg, ROT270, "SemiCom (Game Vision license)", "Wyvern Wings (set 2)", MACHINE_IMPERFECT_SOUND | MACHINE_SUPPORTS_SAVE )
+
+GAME( 2001, aoh, 0, aoh, aoh, vamphalf_state, init_aoh, ROT0, "Unico", "Age Of Heroes - Silkroad 2 (v0.63 - 2001/02/07)", MACHINE_SUPPORTS_SAVE )
+
+GAME( 2001, boonggab, 0, boonggab, boonggab, vamphalf_state, init_boonggab, ROT270, "Taff System", "Boong-Ga Boong-Ga (Spank'em!)", MACHINE_SUPPORTS_SAVE )
+
+GAME( 199?, yorijori, 0, yorijori, common, vamphalf_qdsp_state, init_yorijori, ROT0, "Golden Bell Entertainment", "Yori Jori Kuk Kuk", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND | MACHINE_SUPPORTS_SAVE )
diff --git a/src/mame/drivers/vegas.cpp b/src/mame/drivers/vegas.cpp
index f453f775ec4..f7422d2d2fb 100644
--- a/src/mame/drivers/vegas.cpp
+++ b/src/mame/drivers/vegas.cpp
@@ -1738,7 +1738,7 @@ MACHINE_CONFIG_START(vegas_state::vegascore)
MCFG_IDE_PCI_IRQ_HANDLER(WRITELINE(PCI_ID_NILE, vrc5074_device, pci_intr_d))
//MCFG_IDE_PCI_SET_PIF(0x8f)
- MCFG_DEVICE_ADD(PCI_ID_VIDEO, VOODOO_PCI, 0, TYPE_VOODOO_2, m_maincpu, "screen")
+ MCFG_DEVICE_ADD(PCI_ID_VIDEO, VOODOO_2_PCI, 0, m_maincpu, "screen")
MCFG_VOODOO_PCI_FBMEM(2)
MCFG_VOODOO_PCI_TMUMEM(4, 4)
MCFG_DEVICE_MODIFY(PCI_ID_VIDEO":voodoo")
@@ -1784,7 +1784,7 @@ MACHINE_CONFIG_END
MACHINE_CONFIG_START(vegas_state::vegasban)
vegas32m(config);
- MCFG_DEVICE_REPLACE(PCI_ID_VIDEO, VOODOO_PCI, 0, TYPE_VOODOO_BANSHEE, m_maincpu, "screen")
+ MCFG_DEVICE_REPLACE(PCI_ID_VIDEO, VOODOO_BANSHEE_PCI, 0, m_maincpu, "screen")
MCFG_VOODOO_PCI_FBMEM(16)
MCFG_DEVICE_MODIFY(PCI_ID_VIDEO":voodoo")
MCFG_VOODOO_VBLANK_CB(WRITELINE(*this, vegas_state, vblank_assert))
@@ -1798,7 +1798,7 @@ MACHINE_CONFIG_START(vegas_state::vegasv3)
MCFG_MIPS3_DCACHE_SIZE(16384)
MCFG_MIPS3_SYSTEM_CLOCK(vegas_state::SYSTEM_CLOCK)
- MCFG_DEVICE_REPLACE(PCI_ID_VIDEO, VOODOO_PCI, 0, TYPE_VOODOO_3, m_maincpu, "screen")
+ MCFG_DEVICE_REPLACE(PCI_ID_VIDEO, VOODOO_3_PCI, 0, m_maincpu, "screen")
MCFG_VOODOO_PCI_FBMEM(16)
MCFG_DEVICE_MODIFY(PCI_ID_VIDEO":voodoo")
MCFG_VOODOO_VBLANK_CB(WRITELINE(*this, vegas_state, vblank_assert))
@@ -1816,7 +1816,7 @@ MACHINE_CONFIG_START(vegas_state::denver)
MCFG_VRC5074_SET_SDRAM(0, 0x02000000)
MCFG_VRC5074_SET_CS(8, vegas_state::vegas_cs8_map)
- MCFG_DEVICE_REPLACE(PCI_ID_VIDEO, VOODOO_PCI, 0, TYPE_VOODOO_3, m_maincpu, "screen")
+ MCFG_DEVICE_REPLACE(PCI_ID_VIDEO, VOODOO_3_PCI, 0, m_maincpu, "screen")
MCFG_VOODOO_PCI_FBMEM(16)
MCFG_DEVICE_MODIFY(PCI_ID_VIDEO":voodoo")
MCFG_VOODOO_VBLANK_CB(WRITELINE(*this, vegas_state, vblank_assert))
diff --git a/src/mame/drivers/wicat.cpp b/src/mame/drivers/wicat.cpp
index 365be8d6e6b..f05116e50e3 100644
--- a/src/mame/drivers/wicat.cpp
+++ b/src/mame/drivers/wicat.cpp
@@ -22,6 +22,7 @@ Wicat - various systems.
#include "cpu/8x300/8x300.h"
#include "cpu/m68000/m68000.h"
#include "cpu/z8000/z8000.h"
+#include "machine/74259.h"
#include "machine/6522via.h"
#include "machine/am9517a.h"
#include "machine/im6402.h"
@@ -67,7 +68,8 @@ public:
DECLARE_WRITE16_MEMBER(invalid_w);
DECLARE_READ16_MEMBER(memmap_r);
DECLARE_WRITE16_MEMBER(memmap_w);
- DECLARE_WRITE16_MEMBER(parallel_led_w);
+ DECLARE_WRITE_LINE_MEMBER(adir_w);
+ DECLARE_WRITE_LINE_MEMBER(bdir_w);
DECLARE_WRITE8_MEMBER(via_a_w);
DECLARE_WRITE8_MEMBER(via_b_w);
DECLARE_READ8_MEMBER(video_r);
@@ -179,7 +181,7 @@ void wicat_state::wicat_mem(address_map &map)
map(0xf00030, 0xf00037).rw(m_uart6, FUNC(mc2661_device::read), FUNC(mc2661_device::write)).umask16(0xff00);
map(0xf00040, 0xf0005f).rw(this, FUNC(wicat_state::via_r), FUNC(wicat_state::via_w));
map(0xf00060, 0xf0007f).rw(m_rtc, FUNC(mm58274c_device::read), FUNC(mm58274c_device::write)).umask16(0xff00);
- map(0xf000d0, 0xf000d1).w(this, FUNC(wicat_state::parallel_led_w));
+ map(0xf000d0, 0xf000d0).w("ledlatch", FUNC(ls259_device::write_nibble_d3));
map(0xf00180, 0xf0018f).rw(this, FUNC(wicat_state::hdc_r), FUNC(wicat_state::hdc_w)); // WD1000
map(0xf00190, 0xf0019f).rw(this, FUNC(wicat_state::fdc_r), FUNC(wicat_state::fdc_w)); // FD1795
map(0xf00f00, 0xf00fff).rw(this, FUNC(wicat_state::invalid_r), FUNC(wicat_state::invalid_w));
@@ -390,16 +392,14 @@ void wicat_state::send_key(uint8_t val)
m_kb_serial_timer->adjust(attotime::zero,0,attotime::from_hz(1200));
}
-WRITE16_MEMBER( wicat_state::parallel_led_w )
+WRITE_LINE_MEMBER(wicat_state::adir_w)
{
- // bit 0 - parallel port A direction (0 = input)
- // bit 1 - parallel port B direction (0 = input)
- output().set_value("led1",data & 0x0400);
- output().set_value("led2",data & 0x0800);
- output().set_value("led3",data & 0x1000);
- output().set_value("led4",data & 0x2000);
- output().set_value("led5",data & 0x4000);
- output().set_value("led6",data & 0x8000);
+ // parallel port A direction (0 = input, 1 = output)
+}
+
+WRITE_LINE_MEMBER(wicat_state::bdir_w)
+{
+ // parallel port B direction (0 = input, 1 = output)
}
WRITE8_MEMBER( wicat_state::via_a_w )
@@ -761,14 +761,14 @@ WRITE_LINE_MEMBER(wicat_state::crtc_cb)
I8275_DRAW_CHARACTER_MEMBER(wicat_state::wicat_display_pixels)
{
- uint8_t romdata = m_chargen->base()[((charcode << 4) | linecount) + 1];
+ uint8_t romdata = m_chargen->base()[(charcode << 4) | linecount];
const pen_t *pen = m_palette->pens();
for (int i = 0; i < 8; i++)
{
int color = (romdata >> (7-i)) & 0x01;
- if(vsp || linecount > 9)
+ if(vsp)
color = 0;
bitmap.pix32(y, x + i) = pen[color];
@@ -866,6 +866,16 @@ MACHINE_CONFIG_START(wicat_state::wicat)
MCFG_RS232_DSR_HANDLER(WRITELINE("uart5",mc2661_device,dsr_w))
MCFG_RS232_CTS_HANDLER(WRITELINE("uart5",mc2661_device,cts_w))
+ MCFG_DEVICE_ADD("ledlatch", LS259, 0) // U19 on I/O board
+ MCFG_ADDRESSABLE_LATCH_Q0_OUT_CB(WRITELINE(*this, wicat_state, adir_w))
+ MCFG_ADDRESSABLE_LATCH_Q1_OUT_CB(WRITELINE(*this, wicat_state, bdir_w))
+ MCFG_ADDRESSABLE_LATCH_Q2_OUT_CB(OUTPUT("led1")) MCFG_DEVCB_INVERT // 0 = on, 1 = off
+ MCFG_ADDRESSABLE_LATCH_Q3_OUT_CB(OUTPUT("led2")) MCFG_DEVCB_INVERT
+ MCFG_ADDRESSABLE_LATCH_Q4_OUT_CB(OUTPUT("led3")) MCFG_DEVCB_INVERT
+ MCFG_ADDRESSABLE_LATCH_Q5_OUT_CB(OUTPUT("led4")) MCFG_DEVCB_INVERT
+ MCFG_ADDRESSABLE_LATCH_Q6_OUT_CB(OUTPUT("led5")) MCFG_DEVCB_INVERT
+ MCFG_ADDRESSABLE_LATCH_Q7_OUT_CB(OUTPUT("led6")) MCFG_DEVCB_INVERT
+
/* video hardware */
MCFG_DEVICE_ADD("videocpu",Z8002,XTAL(8'000'000)/2) // AMD AMZ8002DC
MCFG_DEVICE_PROGRAM_MAP(wicat_video_mem)
diff --git a/src/mame/includes/rungun.h b/src/mame/includes/rungun.h
index bcc661c0d07..2f948015b4b 100644
--- a/src/mame/includes/rungun.h
+++ b/src/mame/includes/rungun.h
@@ -83,19 +83,19 @@ private:
bool m_single_screen_mode;
uint8_t m_video_mux_bank;
- DECLARE_READ16_MEMBER(rng_sysregs_r);
- DECLARE_WRITE16_MEMBER(rng_sysregs_w);
+ DECLARE_READ16_MEMBER(sysregs_r);
+ DECLARE_WRITE16_MEMBER(sysregs_w);
DECLARE_WRITE16_MEMBER(sound_cmd1_w);
DECLARE_WRITE16_MEMBER(sound_cmd2_w);
DECLARE_WRITE16_MEMBER(sound_irq_w);
DECLARE_READ16_MEMBER(sound_status_msb_r);
DECLARE_WRITE8_MEMBER(sound_status_w);
DECLARE_WRITE8_MEMBER(sound_ctrl_w);
- DECLARE_READ16_MEMBER(rng_ttl_ram_r);
- DECLARE_WRITE16_MEMBER(rng_ttl_ram_w);
- DECLARE_READ16_MEMBER(rng_psac2_videoram_r);
- DECLARE_WRITE16_MEMBER(rng_psac2_videoram_w);
- DECLARE_READ8_MEMBER(rng_53936_rom_r);
+ DECLARE_READ16_MEMBER(ttl_ram_r);
+ DECLARE_WRITE16_MEMBER(ttl_ram_w);
+ DECLARE_READ16_MEMBER(psac2_videoram_r);
+ DECLARE_WRITE16_MEMBER(psac2_videoram_w);
+ DECLARE_READ8_MEMBER(k53936_rom_r);
TILE_GET_INFO_MEMBER(ttl_get_tile_info);
TILE_GET_INFO_MEMBER(get_rng_936_tile_info);
DECLARE_WRITE_LINE_MEMBER(k054539_nmi_gen);
@@ -115,7 +115,7 @@ private:
INTERRUPT_GEN_MEMBER(rng_interrupt);
- void rungun_k054539_map(address_map &map);
+ void k054539_map(address_map &map);
void rungun_map(address_map &map);
void rungun_sound_map(address_map &map);
};
diff --git a/src/mame/layout/wicat.lay b/src/mame/layout/wicat.lay
index 891b884b79d..d321a637a9f 100644
--- a/src/mame/layout/wicat.lay
+++ b/src/mame/layout/wicat.lay
@@ -3,8 +3,8 @@
<mamelayout version="2">
- <element name="led">
- <disk>
+ <element name="led" defstate="0">
+ <disk state="1">
<color red="1.0" green="0.0" blue="0.0" />
</disk>
</element>
diff --git a/src/mame/machine/cdi070.cpp b/src/mame/machine/cdi070.cpp
index 472075dd3c9..c889da5c9e2 100644
--- a/src/mame/machine/cdi070.cpp
+++ b/src/mame/machine/cdi070.cpp
@@ -856,7 +856,6 @@ READ16_MEMBER( cdi68070_device::periphs_r )
WRITE16_MEMBER( cdi68070_device::periphs_w )
{
- /*
switch(offset)
{
// Interrupts: 80001001
@@ -1162,7 +1161,6 @@ WRITE16_MEMBER( cdi68070_device::periphs_w )
verboselog(*this, 0, "cdi68070_periphs_w: Unknown address: %04x = %04x & %04x\n", offset * 2, data, mem_mask);
break;
}
- */
}
#if ENABLE_UART_PRINTING
diff --git a/src/mame/machine/cdi070.h b/src/mame/machine/cdi070.h
index 74c962ba4aa..eb47209ccb7 100644
--- a/src/mame/machine/cdi070.h
+++ b/src/mame/machine/cdi070.h
@@ -146,7 +146,7 @@ public:
// construction/destruction
cdi68070_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
- void set_cpu_tag(const char *tag) { m_maincpu.set_tag(tag); }
+ template <typename T> void set_cpu_tag(T &&tag) { m_maincpu.set_tag(std::forward<T>(tag)); }
// external callbacks
void uart_rx(uint8_t data);
diff --git a/src/mame/machine/partner.cpp b/src/mame/machine/partner.cpp
index 6cb36b7f304..9aeeb9820e2 100644
--- a/src/mame/machine/partner.cpp
+++ b/src/mame/machine/partner.cpp
@@ -332,8 +332,6 @@ I8275_DRAW_CHARACTER_MEMBER(partner_state::display_pixels)
const rgb_t *palette = m_palette->palette()->entry_list_raw();
const uint8_t *charmap = m_charmap + 0x400 * (gpa * 2 + hlgt);
uint8_t pixels = charmap[(linecount & 7) + (charcode << 3)] ^ 0xff;
- if(linecount == 8)
- pixels = 0;
if (vsp) {
pixels = 0;
}
diff --git a/src/mame/machine/radio86.cpp b/src/mame/machine/radio86.cpp
index 2cfbd396880..da181dac71d 100644
--- a/src/mame/machine/radio86.cpp
+++ b/src/mame/machine/radio86.cpp
@@ -202,8 +202,6 @@ I8275_DRAW_CHARACTER_MEMBER(radio86_state::display_pixels)
const rgb_t *palette = m_palette->palette()->entry_list_raw();
const uint8_t *charmap = m_charmap;
uint8_t pixels = charmap[(linecount & 7) + (charcode << 3)] ^ 0xff;
- if(linecount == 8)
- pixels = 0;
if (vsp) {
pixels = 0;
}
diff --git a/src/mame/mame.lst b/src/mame/mame.lst
index c0329b0e2c5..08b23a35c6e 100644
--- a/src/mame/mame.lst
+++ b/src/mame/mame.lst
@@ -13503,6 +13503,9 @@ gcbr // (c) 2002 Nintendo
gamekin3 //
gameking //
+@source:gamemasters.cpp
+gmsshoot // (c) 1989 GameMasters
+
@source:gameplan.cpp
challeng // (c) 1981 Centuri
kaos // (c) 1981
@@ -37797,6 +37800,7 @@ mrdig // (c) 2000 Sun
mrkicker // (c) 2001 Semicom
mrkickera // (c) 2001 Semicom
newxpang // (c) 1999 F2 System
+worldadv // (c) 1999 F2 System
puzlbang // (c) 1999 Omega System
puzlbanga // (c) 1999 Omega System
suplup // (c) 1999 Omega System
diff --git a/src/mame/video/rungun.cpp b/src/mame/video/rungun.cpp
index 556489d789e..eedf7dd0bfd 100644
--- a/src/mame/video/rungun.cpp
+++ b/src/mame/video/rungun.cpp
@@ -33,24 +33,24 @@ K055673_CB_MEMBER(rungun_state::sprite_callback)
*color = m_sprite_colorbase | (*color & 0x001f);
}
-READ16_MEMBER(rungun_state::rng_ttl_ram_r)
+READ16_MEMBER(rungun_state::ttl_ram_r)
{
return m_ttl_vram[offset+(m_video_mux_bank*0x1000)];
}
-WRITE16_MEMBER(rungun_state::rng_ttl_ram_w)
+WRITE16_MEMBER(rungun_state::ttl_ram_w)
{
COMBINE_DATA(&m_ttl_vram[offset+(m_video_mux_bank*0x1000)]);
m_ttl_tilemap[m_video_mux_bank]->mark_tile_dirty(offset / 2);
}
/* 53936 (PSAC2) rotation/zoom plane */
-READ16_MEMBER(rungun_state::rng_psac2_videoram_r)
+READ16_MEMBER(rungun_state::psac2_videoram_r)
{
return m_psac2_vram[offset+(m_video_mux_bank*0x80000)];
}
-WRITE16_MEMBER(rungun_state::rng_psac2_videoram_w)
+WRITE16_MEMBER(rungun_state::psac2_videoram_w)
{
COMBINE_DATA(&m_psac2_vram[offset+(m_video_mux_bank*0x80000)]);
m_936_tilemap[m_video_mux_bank]->mark_tile_dirty(offset / 2);
@@ -136,7 +136,6 @@ uint32_t rungun_state::screen_update_rng(screen_device &screen, bitmap_ind16 &bi
}
m_ttl_tilemap[m_current_display_bank]->draw(screen, bitmap, cliprect, 0, 0);
-
return 0;
}