diff options
author | Michael Zapf <Michael.Zapf@mizapf.de> | 2016-04-03 01:45:39 +0200 |
---|---|---|
committer | Michael Zapf <Michael.Zapf@mizapf.de> | 2016-04-03 01:45:39 +0200 |
commit | 535bc443302d13811fb16e9fc17ac5783df41ba2 (patch) | |
tree | f300c97c448febb5f730fbc780d28a68f206d9c5 /src/devices/bus | |
parent | 4b7752e64e1c257ac90367db798399e099be074a (diff) |
ti99: Removed GROMCLK generator from wrapper
Diffstat (limited to 'src/devices/bus')
-rw-r--r-- | src/devices/bus/ti99x/datamux.cpp | 23 | ||||
-rw-r--r-- | src/devices/bus/ti99x/datamux.h | 3 | ||||
-rw-r--r-- | src/devices/bus/ti99x/videowrp.cpp | 17 | ||||
-rw-r--r-- | src/devices/bus/ti99x/videowrp.h | 13 |
4 files changed, 7 insertions, 49 deletions
diff --git a/src/devices/bus/ti99x/datamux.cpp b/src/devices/bus/ti99x/datamux.cpp index 85030665b41..034ecfe114d 100644 --- a/src/devices/bus/ti99x/datamux.cpp +++ b/src/devices/bus/ti99x/datamux.cpp @@ -124,16 +124,7 @@ void ti99_datamux_device::read_all(address_space& space, UINT16 addr, UINT8 *val // Video if ((addr & 0xf801)==0x8800) { - if (addr & 2) - { - // Read VDP status - *value = m_video->register_read(space, 0); - } - else - { - // Read VDP RAM - *value = m_video->vram_read(space, 0); - } + m_video->readz(space, addr, value); } } @@ -166,15 +157,7 @@ void ti99_datamux_device::write_all(address_space& space, UINT16 addr, UINT8 val // Video if ((addr & 0xf801)==0x8800) { - if (addr & 2) - { - // Write VDP address - m_video->register_write(space, 0, value); - } - else - { // Write VDP data - m_video->vram_write(space, 0, value); - } + m_video->write(space, addr, value); } // PEB gets all accesses @@ -577,7 +560,7 @@ void ti99_datamux_device::device_reset(void) void ti99_datamux_device::device_config_complete() { - m_video = downcast<tms9928a_device*>(owner()->subdevice(VDP_TAG)); + m_video = downcast<bus8z_device*>(owner()->subdevice(VIDEO_SYSTEM_TAG)); m_sound = downcast<sn76496_base_device*>(owner()->subdevice(TISOUNDCHIP_TAG)); m_gromport = downcast<gromport_device*>(owner()->subdevice(GROMPORT_TAG)); m_peb = downcast<peribox_device*>(owner()->subdevice(PERIBOX_TAG)); diff --git a/src/devices/bus/ti99x/datamux.h b/src/devices/bus/ti99x/datamux.h index 27908d403c6..5b59ea7d134 100644 --- a/src/devices/bus/ti99x/datamux.h +++ b/src/devices/bus/ti99x/datamux.h @@ -20,6 +20,7 @@ #include "bus/ti99_peb/peribox.h" #include "sound/sn76496.h" #include "video/tms9928a.h" +#include "bus/ti99x/videowrp.h" extern const device_type DATAMUX; @@ -55,7 +56,7 @@ protected: private: // Link to the video processor - tms9928a_device* m_video; + bus8z_device* m_video; // Link to the sound processor sn76496_base_device* m_sound; diff --git a/src/devices/bus/ti99x/videowrp.cpp b/src/devices/bus/ti99x/videowrp.cpp index a6bba316700..4aa1935f226 100644 --- a/src/devices/bus/ti99x/videowrp.cpp +++ b/src/devices/bus/ti99x/videowrp.cpp @@ -34,8 +34,7 @@ ti_std_video_device::ti_std_video_device(const machine_config &mconfig, const ch ti_exp_video_device::ti_exp_video_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock) : ti_video_device(mconfig, V9938VIDEO, "TI99 EXP Video subsystem", tag, owner, clock, "v9938_video", __FILE__), - m_v9938(nullptr), - m_out_gromclk_cb(*this) + m_v9938(nullptr) { } @@ -88,13 +87,6 @@ WRITE16_MEMBER( ti_exp_video_device::write16 ) m_v9938->write(space, offset, (data>>8)&0xff); } -void ti_exp_video_device::device_timer(emu_timer &timer, device_timer_id id, int param, void *ptr) -{ - // Pulse it - m_out_gromclk_cb(ASSERT_LINE); - m_out_gromclk_cb(CLEAR_LINE); -} - /******************************************************************************/ @@ -121,13 +113,6 @@ void ti_video_device::device_start(void) void ti_exp_video_device::device_start(void) { m_v9938 = static_cast<v9938_device*>(machine().device(VDP_TAG)); - m_out_gromclk_cb.resolve(); - m_gromclk_timer = timer_alloc(0); -} - -void ti_exp_video_device::device_reset(void) -{ - if (!m_out_gromclk_cb.isnull()) m_gromclk_timer->adjust(attotime::zero, 0, attotime::from_hz(XTAL_10_738635MHz/24)); } /**************************************************************************/ diff --git a/src/devices/bus/ti99x/videowrp.h b/src/devices/bus/ti99x/videowrp.h index ca52a99902e..787f0e2d44f 100644 --- a/src/devices/bus/ti99x/videowrp.h +++ b/src/devices/bus/ti99x/videowrp.h @@ -43,7 +43,6 @@ public: ti_std_video_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock); DECLARE_READ8Z_MEMBER(readz) override; DECLARE_WRITE8_MEMBER(write) override; - void reset_vdp(int state) override { m_tms9928a->reset_line(state); } }; @@ -54,8 +53,6 @@ class ti_exp_video_device : public ti_video_device { public: ti_exp_video_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock); - template<class _Object> static devcb_base &set_out_gromclk_callback(device_t &device, _Object object) { return downcast<ti_exp_video_device &>(device).m_out_gromclk_cb.set_callback(object); } - DECLARE_READ8Z_MEMBER(readz) override; DECLARE_WRITE8_MEMBER(write) override; DECLARE_READ16_MEMBER(read16); @@ -63,20 +60,12 @@ public: void reset_vdp(int state) override { m_v9938->reset_line(state); } protected: - virtual void device_start(void) override; - virtual void device_reset(void) override; + virtual void device_start(void) override; private: - void device_timer(emu_timer &timer, device_timer_id id, int param, void *ptr) override; v9938_device *m_v9938; - devcb_write_line m_out_gromclk_cb; // GROMCLK line is optional; if present, pulse it by XTAL/24 rate - emu_timer *m_gromclk_timer; }; -#define MCFG_ADD_GROMCLK_CB(_devcb) \ - devcb = &ti_exp_video_device::set_out_gromclk_callback(*device, DEVCB_##_devcb); - - extern const device_type TI99VIDEO; extern const device_type V9938VIDEO; |