mirror of
https://github.com/holub/mame
synced 2025-10-05 08:41:31 +03:00
(nw) fix MPU4 video crash, clean up a little
This commit is contained in:
parent
d80e7f95eb
commit
ecde621979
@ -444,7 +444,7 @@ Known Issues
|
|||||||
Issues with specific compiler versions
|
Issues with specific compiler versions
|
||||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
* MinGW GCC 7 for Windows i386 produces spurious out-of-bounds access warnings.
|
* GCC 7 for 32-bit x86 targets produces spurious out-of-bounds access warnings.
|
||||||
Adding **NOWERROR=1** to your build options works around this by not treating
|
Adding **NOWERROR=1** to your build options works around this by not treating
|
||||||
warnings as errors.
|
warnings as errors.
|
||||||
* Initial versions of GNU libstdc++ 6 have a broken ``std::unique_ptr``
|
* Initial versions of GNU libstdc++ 6 have a broken ``std::unique_ptr``
|
||||||
|
@ -2584,6 +2584,7 @@ m68000_device::m68000_device(const machine_config &mconfig, const device_type ty
|
|||||||
|
|
||||||
void m68000_device::device_start()
|
void m68000_device::device_start()
|
||||||
{
|
{
|
||||||
|
m68000_base_device::device_start();
|
||||||
init_cpu_m68000();
|
init_cpu_m68000();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -2607,6 +2608,7 @@ m68008_device::m68008_device(const machine_config &mconfig, const char *tag, dev
|
|||||||
|
|
||||||
void m68008_device::device_start()
|
void m68008_device::device_start()
|
||||||
{
|
{
|
||||||
|
m68000_base_device::device_start();
|
||||||
init_cpu_m68008();
|
init_cpu_m68008();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -2618,6 +2620,7 @@ m68008fn_device::m68008fn_device(const machine_config &mconfig, const char *tag,
|
|||||||
|
|
||||||
void m68008fn_device::device_start()
|
void m68008fn_device::device_start()
|
||||||
{
|
{
|
||||||
|
m68000_base_device::device_start();
|
||||||
init_cpu_m68008();
|
init_cpu_m68008();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -2630,6 +2633,7 @@ m68010_device::m68010_device(const machine_config &mconfig, const char *tag, dev
|
|||||||
|
|
||||||
void m68010_device::device_start()
|
void m68010_device::device_start()
|
||||||
{
|
{
|
||||||
|
m68000_base_device::device_start();
|
||||||
init_cpu_m68010();
|
init_cpu_m68010();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -2642,6 +2646,7 @@ m68020_device::m68020_device(const machine_config &mconfig, const char *tag, dev
|
|||||||
|
|
||||||
void m68020_device::device_start()
|
void m68020_device::device_start()
|
||||||
{
|
{
|
||||||
|
m68000_base_device::device_start();
|
||||||
init_cpu_m68020();
|
init_cpu_m68020();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -2653,6 +2658,7 @@ m68020fpu_device::m68020fpu_device(const machine_config &mconfig, const char *ta
|
|||||||
|
|
||||||
void m68020fpu_device::device_start()
|
void m68020fpu_device::device_start()
|
||||||
{
|
{
|
||||||
|
m68000_base_device::device_start();
|
||||||
init_cpu_m68020fpu();
|
init_cpu_m68020fpu();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -2664,6 +2670,7 @@ m68020pmmu_device::m68020pmmu_device(const machine_config &mconfig, const char *
|
|||||||
|
|
||||||
void m68020pmmu_device::device_start()
|
void m68020pmmu_device::device_start()
|
||||||
{
|
{
|
||||||
|
m68000_base_device::device_start();
|
||||||
init_cpu_m68020pmmu();
|
init_cpu_m68020pmmu();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -2689,6 +2696,7 @@ m68020hmmu_device::m68020hmmu_device(const machine_config &mconfig, const char *
|
|||||||
|
|
||||||
void m68020hmmu_device::device_start()
|
void m68020hmmu_device::device_start()
|
||||||
{
|
{
|
||||||
|
m68000_base_device::device_start();
|
||||||
init_cpu_m68020hmmu();
|
init_cpu_m68020hmmu();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -2700,6 +2708,7 @@ m68ec020_device::m68ec020_device(const machine_config &mconfig, const char *tag,
|
|||||||
|
|
||||||
void m68ec020_device::device_start()
|
void m68ec020_device::device_start()
|
||||||
{
|
{
|
||||||
|
m68000_base_device::device_start();
|
||||||
init_cpu_m68ec020();
|
init_cpu_m68ec020();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -2710,6 +2719,7 @@ m68030_device::m68030_device(const machine_config &mconfig, const char *tag, dev
|
|||||||
|
|
||||||
void m68030_device::device_start()
|
void m68030_device::device_start()
|
||||||
{
|
{
|
||||||
|
m68000_base_device::device_start();
|
||||||
init_cpu_m68030();
|
init_cpu_m68030();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -2720,6 +2730,7 @@ m68ec030_device::m68ec030_device(const machine_config &mconfig, const char *tag,
|
|||||||
|
|
||||||
void m68ec030_device::device_start()
|
void m68ec030_device::device_start()
|
||||||
{
|
{
|
||||||
|
m68000_base_device::device_start();
|
||||||
init_cpu_m68ec030();
|
init_cpu_m68ec030();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -2731,6 +2742,7 @@ m68040_device::m68040_device(const machine_config &mconfig, const char *tag, dev
|
|||||||
|
|
||||||
void m68040_device::device_start()
|
void m68040_device::device_start()
|
||||||
{
|
{
|
||||||
|
m68000_base_device::device_start();
|
||||||
init_cpu_m68040();
|
init_cpu_m68040();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -2743,6 +2755,7 @@ m68ec040_device::m68ec040_device(const machine_config &mconfig, const char *tag,
|
|||||||
|
|
||||||
void m68ec040_device::device_start()
|
void m68ec040_device::device_start()
|
||||||
{
|
{
|
||||||
|
m68000_base_device::device_start();
|
||||||
init_cpu_m68ec040();
|
init_cpu_m68ec040();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -2755,6 +2768,7 @@ m68lc040_device::m68lc040_device(const machine_config &mconfig, const char *tag,
|
|||||||
|
|
||||||
void m68lc040_device::device_start()
|
void m68lc040_device::device_start()
|
||||||
{
|
{
|
||||||
|
m68000_base_device::device_start();
|
||||||
init_cpu_m68lc040();
|
init_cpu_m68lc040();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -2767,6 +2781,7 @@ scc68070_base_device::scc68070_base_device(const machine_config &mconfig, const
|
|||||||
|
|
||||||
void scc68070_base_device::device_start()
|
void scc68070_base_device::device_start()
|
||||||
{
|
{
|
||||||
|
m68000_base_device::device_start();
|
||||||
init_cpu_scc68070();
|
init_cpu_scc68070();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -2785,6 +2800,7 @@ fscpu32_device::fscpu32_device(const machine_config &mconfig, const char *tag, d
|
|||||||
|
|
||||||
void fscpu32_device::device_start()
|
void fscpu32_device::device_start()
|
||||||
{
|
{
|
||||||
|
m68000_base_device::device_start();
|
||||||
init_cpu_fscpu32();
|
init_cpu_fscpu32();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -2797,6 +2813,7 @@ mcf5206e_device::mcf5206e_device(const machine_config &mconfig, const char *tag,
|
|||||||
|
|
||||||
void mcf5206e_device::device_start()
|
void mcf5206e_device::device_start()
|
||||||
{
|
{
|
||||||
|
m68000_base_device::device_start();
|
||||||
init_cpu_coldfire();
|
init_cpu_coldfire();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -205,19 +205,18 @@ TODO:
|
|||||||
#include "crmaze4p.lh"
|
#include "crmaze4p.lh"
|
||||||
|
|
||||||
|
|
||||||
struct bt471_t
|
|
||||||
{
|
|
||||||
uint8_t address;
|
|
||||||
uint8_t addr_cnt;
|
|
||||||
uint8_t pixmask;
|
|
||||||
uint8_t command;
|
|
||||||
rgb_t color;
|
|
||||||
};
|
|
||||||
|
|
||||||
|
|
||||||
class mpu4vid_state : public mpu4_state
|
class mpu4vid_state : public mpu4_state
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
|
struct bt471_t
|
||||||
|
{
|
||||||
|
uint8_t address;
|
||||||
|
uint8_t addr_cnt;
|
||||||
|
uint8_t pixmask;
|
||||||
|
uint8_t command;
|
||||||
|
rgb_t color;
|
||||||
|
};
|
||||||
|
|
||||||
mpu4vid_state(const machine_config &mconfig, device_type type, const char *tag)
|
mpu4vid_state(const machine_config &mconfig, device_type type, const char *tag)
|
||||||
: mpu4_state(mconfig, type, tag),
|
: mpu4_state(mconfig, type, tag),
|
||||||
m_videocpu(*this, "video"),
|
m_videocpu(*this, "video"),
|
||||||
@ -281,9 +280,9 @@ private:
|
|||||||
int m_gfx_index;
|
int m_gfx_index;
|
||||||
int8_t m_cur[2];
|
int8_t m_cur[2];
|
||||||
|
|
||||||
DECLARE_MACHINE_START(mpu4_vid);
|
virtual void machine_start() override;
|
||||||
DECLARE_MACHINE_RESET(mpu4_vid);
|
virtual void machine_reset() override;
|
||||||
DECLARE_VIDEO_START(mpu4_vid);
|
virtual void video_start() override;
|
||||||
SCN2674_DRAW_CHARACTER_MEMBER(display_pixels);
|
SCN2674_DRAW_CHARACTER_MEMBER(display_pixels);
|
||||||
DECLARE_WRITE_LINE_MEMBER(m6809_acia_irq);
|
DECLARE_WRITE_LINE_MEMBER(m6809_acia_irq);
|
||||||
DECLARE_WRITE_LINE_MEMBER(m68k_acia_irq);
|
DECLARE_WRITE_LINE_MEMBER(m68k_acia_irq);
|
||||||
@ -438,7 +437,7 @@ WRITE16_MEMBER(mpu4vid_state::mpu4_vid_vidram_w )
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
VIDEO_START_MEMBER(mpu4vid_state,mpu4_vid)
|
void mpu4vid_state::video_start()
|
||||||
{
|
{
|
||||||
m_vid_vidram.allocate(0x20000/2);
|
m_vid_vidram.allocate(0x20000/2);
|
||||||
|
|
||||||
@ -1152,19 +1151,16 @@ WRITE_LINE_MEMBER(mpu4vid_state::mpu_video_reset)
|
|||||||
}
|
}
|
||||||
|
|
||||||
/* machine start (called only once) */
|
/* machine start (called only once) */
|
||||||
MACHINE_START_MEMBER(mpu4vid_state,mpu4_vid)
|
void mpu4vid_state::machine_start()
|
||||||
{
|
{
|
||||||
mpu4_config_common();
|
mpu4_config_common();
|
||||||
|
|
||||||
m_mod_number=4; //No AY chip
|
m_mod_number=4; //No AY chip
|
||||||
/* setup communications */
|
/* setup communications */
|
||||||
m_link7a_connected = 1;
|
m_link7a_connected = 1;
|
||||||
|
|
||||||
/* Hook the reset line */
|
|
||||||
m_videocpu->set_reset_callback(FUNC(mpu4vid_state::mpu_video_reset));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
MACHINE_RESET_MEMBER(mpu4vid_state,mpu4_vid)
|
void mpu4vid_state::machine_reset()
|
||||||
{
|
{
|
||||||
m_vfd->reset(); //for debug ports only
|
m_vfd->reset(); //for debug ports only
|
||||||
|
|
||||||
@ -1302,13 +1298,10 @@ void mpu4vid_state::mpu4_vid(machine_config &config)
|
|||||||
|
|
||||||
M68000(config, m_videocpu, VIDEO_MASTER_CLOCK);
|
M68000(config, m_videocpu, VIDEO_MASTER_CLOCK);
|
||||||
m_videocpu->set_addrmap(AS_PROGRAM, &mpu4vid_state::mpu4_68k_map);
|
m_videocpu->set_addrmap(AS_PROGRAM, &mpu4vid_state::mpu4_68k_map);
|
||||||
|
m_videocpu->set_reset_callback(FUNC(mpu4vid_state::mpu_video_reset));
|
||||||
|
|
||||||
// config.m_minimum_quantum = attotime::from_hz(960);
|
// config.m_minimum_quantum = attotime::from_hz(960);
|
||||||
|
|
||||||
MCFG_MACHINE_START_OVERRIDE(mpu4vid_state,mpu4_vid)
|
|
||||||
MCFG_MACHINE_RESET_OVERRIDE(mpu4vid_state,mpu4_vid)
|
|
||||||
MCFG_VIDEO_START_OVERRIDE (mpu4vid_state,mpu4_vid)
|
|
||||||
|
|
||||||
PALETTE(config, m_palette).set_entries(ef9369_device::NUMCOLORS);
|
PALETTE(config, m_palette).set_entries(ef9369_device::NUMCOLORS);
|
||||||
|
|
||||||
EF9369(config, "ef9369").set_color_update_callback(FUNC(mpu4vid_state::ef9369_color_update));
|
EF9369(config, "ef9369").set_color_update_callback(FUNC(mpu4vid_state::ef9369_color_update));
|
||||||
|
Loading…
Reference in New Issue
Block a user