diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/mess/drivers/vic10.c | 2 | ||||
-rw-r--r-- | src/mess/drivers/vic20.c | 7 | ||||
-rw-r--r-- | src/mess/machine/c64exp.c | 8 | ||||
-rw-r--r-- | src/mess/machine/cbmiec.c | 8 | ||||
-rw-r--r-- | src/mess/machine/plus4exp.c | 8 | ||||
-rw-r--r-- | src/mess/machine/vic1010.c | 12 | ||||
-rw-r--r-- | src/mess/machine/vic10exp.c | 10 | ||||
-rw-r--r-- | src/mess/machine/vic10exp.h | 4 | ||||
-rw-r--r-- | src/mess/machine/vic20exp.c | 8 | ||||
-rw-r--r-- | src/mess/machine/vic20exp.h | 4 |
10 files changed, 58 insertions, 13 deletions
diff --git a/src/mess/drivers/vic10.c b/src/mess/drivers/vic10.c index 6365cfa2ded..10ac12e7b6e 100644 --- a/src/mess/drivers/vic10.c +++ b/src/mess/drivers/vic10.c @@ -634,7 +634,7 @@ static MACHINE_CONFIG_START( vic10, vic10_state ) MCFG_MOS6526R1_ADD(MOS6526_TAG, VIC6566_CLOCK, cia_intf) MCFG_CASSETTE_ADD(CASSETTE_TAG, cbm_cassette_interface) MCFG_TIMER_ADD(TIMER_C1531_TAG, cassette_tick) - MCFG_VIC10_EXPANSION_SLOT_ADD(VIC10_EXPANSION_SLOT_TAG, expansion_intf, vic10_expansion_cards, NULL, NULL) + MCFG_VIC10_EXPANSION_SLOT_ADD(VIC10_EXPANSION_SLOT_TAG, VIC6566_CLOCK, expansion_intf, vic10_expansion_cards, NULL, NULL) // software list MCFG_SOFTWARE_LIST_ADD("cart_list", "vic10") diff --git a/src/mess/drivers/vic20.c b/src/mess/drivers/vic20.c index a4c59737dc4..b1b2832a5df 100644 --- a/src/mess/drivers/vic20.c +++ b/src/mess/drivers/vic20.c @@ -821,7 +821,6 @@ static MACHINE_CONFIG_START( vic20_common, vic20_state ) MCFG_VCS_CONTROL_PORT_ADD(CONTROL1_TAG, vic20_control_port_devices, NULL, NULL) MCFG_VCS_CONTROL_PORT_ADD(CONTROL2_TAG, vic20_control_port_devices, NULL, NULL) - MCFG_VIC20_EXPANSION_SLOT_ADD(VIC20_EXPANSION_SLOT_TAG, expansion_intf, vic20_expansion_cards, NULL, NULL) MCFG_VIC20_USER_PORT_ADD(VIC20_USER_PORT_TAG, user_intf, vic20_user_port_cards, NULL, NULL) // software lists @@ -862,6 +861,9 @@ static MACHINE_CONFIG_DERIVED( vic20_ntsc, vic20_common ) MCFG_SOUND_ADD("dac", DAC, 0) MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + // devices + MCFG_VIC20_EXPANSION_SLOT_ADD(VIC20_EXPANSION_SLOT_TAG, MOS6560_CLOCK, expansion_intf, vic20_expansion_cards, NULL, NULL) + // software lists MCFG_SOFTWARE_LIST_FILTER("cart_list", "NTSC") MCFG_SOFTWARE_LIST_FILTER("disk_list", "NTSC") @@ -889,6 +891,9 @@ static MACHINE_CONFIG_DERIVED( vic20_pal, vic20_common ) MCFG_PALETTE_LENGTH(16) MCFG_PALETTE_INIT( vic20 ) + // devices + MCFG_VIC20_EXPANSION_SLOT_ADD(VIC20_EXPANSION_SLOT_TAG, MOS6561_CLOCK, expansion_intf, vic20_expansion_cards, NULL, NULL) + // sound hardware MCFG_SPEAKER_STANDARD_MONO("mono") MCFG_MOS656X_ADD(M6560_TAG, vic_pal_intf) diff --git a/src/mess/machine/c64exp.c b/src/mess/machine/c64exp.c index 37123f377be..86be216ee43 100644 --- a/src/mess/machine/c64exp.c +++ b/src/mess/machine/c64exp.c @@ -202,6 +202,14 @@ void c64_expansion_slot_device::device_start() m_out_nmi_func.resolve(m_out_nmi_cb, *this); m_out_dma_func.resolve(m_out_dma_cb, *this); m_out_reset_func.resolve(m_out_reset_cb, *this); + + // inherit bus clock + if (clock() == 0) + { + c64_expansion_slot_device *root = machine().device<c64_expansion_slot_device>(C64_EXPANSION_SLOT_TAG); + assert(root); + set_unscaled_clock(root->clock()); + } } diff --git a/src/mess/machine/cbmiec.c b/src/mess/machine/cbmiec.c index 107b098116f..a0d90c40d1e 100644 --- a/src/mess/machine/cbmiec.c +++ b/src/mess/machine/cbmiec.c @@ -190,6 +190,14 @@ C64 SERIAL BUS 5) Tei minimum must be 80us for external device to be a listener. */ +/* + + TODO: + + - refactor into an actual daisy chain instead of this convenient hack + +*/ + #include "cbmiec.h" diff --git a/src/mess/machine/plus4exp.c b/src/mess/machine/plus4exp.c index 0d19b311194..11bf1a7b55f 100644 --- a/src/mess/machine/plus4exp.c +++ b/src/mess/machine/plus4exp.c @@ -234,6 +234,14 @@ void plus4_expansion_slot_device::device_start() m_out_dma_cd_func.resolve(m_out_dma_cd_cb, *this); m_out_irq_func.resolve(m_out_irq_cb, *this); m_out_aec_func.resolve(m_out_aec_cb, *this); + + // inherit bus clock + if (clock() == 0) + { + plus4_expansion_slot_device *root = machine().device<plus4_expansion_slot_device>(PLUS4_EXPANSION_SLOT_TAG); + assert(root); + set_unscaled_clock(root->clock()); + } } diff --git a/src/mess/machine/vic1010.c b/src/mess/machine/vic1010.c index ac88bd64cfe..dae017858d6 100644 --- a/src/mess/machine/vic1010.c +++ b/src/mess/machine/vic1010.c @@ -50,12 +50,12 @@ static VIC20_EXPANSION_INTERFACE( expansion_intf ) //------------------------------------------------- static MACHINE_CONFIG_FRAGMENT( vic1010 ) - MCFG_VIC20_EXPANSION_SLOT_ADD("slot1", expansion_intf, vic20_expansion_cards, NULL, NULL) - MCFG_VIC20_EXPANSION_SLOT_ADD("slot2", expansion_intf, vic20_expansion_cards, NULL, NULL) - MCFG_VIC20_EXPANSION_SLOT_ADD("slot3", expansion_intf, vic20_expansion_cards, NULL, NULL) - MCFG_VIC20_EXPANSION_SLOT_ADD("slot4", expansion_intf, vic20_expansion_cards, NULL, NULL) - MCFG_VIC20_EXPANSION_SLOT_ADD("slot5", expansion_intf, vic20_expansion_cards, NULL, NULL) - MCFG_VIC20_EXPANSION_SLOT_ADD("slot6", expansion_intf, vic20_expansion_cards, NULL, NULL) + MCFG_VIC20_EXPANSION_SLOT_ADD("slot1", 0, expansion_intf, vic20_expansion_cards, NULL, NULL) + MCFG_VIC20_EXPANSION_SLOT_ADD("slot2", 0, expansion_intf, vic20_expansion_cards, NULL, NULL) + MCFG_VIC20_EXPANSION_SLOT_ADD("slot3", 0, expansion_intf, vic20_expansion_cards, NULL, NULL) + MCFG_VIC20_EXPANSION_SLOT_ADD("slot4", 0, expansion_intf, vic20_expansion_cards, NULL, NULL) + MCFG_VIC20_EXPANSION_SLOT_ADD("slot5", 0, expansion_intf, vic20_expansion_cards, NULL, NULL) + MCFG_VIC20_EXPANSION_SLOT_ADD("slot6", 0, expansion_intf, vic20_expansion_cards, NULL, NULL) MACHINE_CONFIG_END diff --git a/src/mess/machine/vic10exp.c b/src/mess/machine/vic10exp.c index 806a26804f2..afa6831fd47 100644 --- a/src/mess/machine/vic10exp.c +++ b/src/mess/machine/vic10exp.c @@ -9,9 +9,9 @@ #include "emu.h" #include "emuopts.h" -#include "machine/vic10exp.h" #include "formats/cbm_crt.h" #include "formats/imageutl.h" +#include "machine/vic10exp.h" @@ -164,6 +164,14 @@ void vic10_expansion_slot_device::device_start() m_out_sp_func.resolve(m_out_sp_cb, *this); m_out_cnt_func.resolve(m_out_cnt_cb, *this); m_out_res_func.resolve(m_out_res_cb, *this); + + // inherit bus clock + if (clock() == 0) + { + vic10_expansion_slot_device *root = machine().device<vic10_expansion_slot_device>(VIC10_EXPANSION_SLOT_TAG); + assert(root); + set_unscaled_clock(root->clock()); + } } diff --git a/src/mess/machine/vic10exp.h b/src/mess/machine/vic10exp.h index 298df7b6f7c..13934b02d4b 100644 --- a/src/mess/machine/vic10exp.h +++ b/src/mess/machine/vic10exp.h @@ -58,8 +58,8 @@ const vic10_expansion_slot_interface (_name) = -#define MCFG_VIC10_EXPANSION_SLOT_ADD(_tag, _config, _slot_intf, _def_slot, _def_inp) \ - MCFG_DEVICE_ADD(_tag, VIC10_EXPANSION_SLOT, 0) \ +#define MCFG_VIC10_EXPANSION_SLOT_ADD(_tag, _clock, _config, _slot_intf, _def_slot, _def_inp) \ + MCFG_DEVICE_ADD(_tag, VIC10_EXPANSION_SLOT, _clock) \ MCFG_DEVICE_CONFIG(_config) \ MCFG_DEVICE_SLOT_INTERFACE(_slot_intf, _def_slot, _def_inp, false) diff --git a/src/mess/machine/vic20exp.c b/src/mess/machine/vic20exp.c index f63b40ed08d..20997bcc004 100644 --- a/src/mess/machine/vic20exp.c +++ b/src/mess/machine/vic20exp.c @@ -220,6 +220,14 @@ void vic20_expansion_slot_device::device_start() m_out_irq_func.resolve(m_out_irq_cb, *this); m_out_nmi_func.resolve(m_out_nmi_cb, *this); m_out_res_func.resolve(m_out_res_cb, *this); + + // inherit bus clock + if (clock() == 0) + { + vic20_expansion_slot_device *root = machine().device<vic20_expansion_slot_device>(VIC20_EXPANSION_SLOT_TAG); + assert(root); + set_unscaled_clock(root->clock()); + } } diff --git a/src/mess/machine/vic20exp.h b/src/mess/machine/vic20exp.h index 963235e48d6..7b406935875 100644 --- a/src/mess/machine/vic20exp.h +++ b/src/mess/machine/vic20exp.h @@ -57,8 +57,8 @@ const vic20_expansion_slot_interface (_name) = -#define MCFG_VIC20_EXPANSION_SLOT_ADD(_tag, _config, _slot_intf, _def_slot, _def_inp) \ - MCFG_DEVICE_ADD(_tag, VIC20_EXPANSION_SLOT, 0) \ +#define MCFG_VIC20_EXPANSION_SLOT_ADD(_tag, _clock, _config, _slot_intf, _def_slot, _def_inp) \ + MCFG_DEVICE_ADD(_tag, VIC20_EXPANSION_SLOT, _clock) \ MCFG_DEVICE_CONFIG(_config) \ MCFG_DEVICE_SLOT_INTERFACE(_slot_intf, _def_slot, _def_inp, false) |