diff --git a/src/devices/machine/gen_latch.cpp b/src/devices/machine/gen_latch.cpp index 54982bc7e85..a72305bcaa4 100644 --- a/src/devices/machine/gen_latch.cpp +++ b/src/devices/machine/gen_latch.cpp @@ -41,6 +41,16 @@ WRITE8_MEMBER( generic_latch_8_device::write ) machine().scheduler().synchronize(timer_expired_delegate(FUNC(generic_latch_8_device::sync_callback), this), data); } +WRITE8_MEMBER( generic_latch_8_device::preset_w ) +{ + m_latched_value = 0xff; +} + +WRITE8_MEMBER( generic_latch_8_device::clear_w ) +{ + m_latched_value = 0x00; +} + WRITE_LINE_MEMBER( generic_latch_8_device::preset_w ) { m_latched_value = 0xff; @@ -113,6 +123,16 @@ WRITE16_MEMBER( generic_latch_16_device::write ) machine().scheduler().synchronize(timer_expired_delegate(FUNC(generic_latch_16_device::sync_callback), this), data); } +WRITE16_MEMBER( generic_latch_16_device::preset_w ) +{ + m_latched_value = 0xffff; +} + +WRITE16_MEMBER( generic_latch_16_device::clear_w ) +{ + m_latched_value = 0x0000; +} + WRITE_LINE_MEMBER( generic_latch_16_device::preset_w ) { m_latched_value = 0xffff; diff --git a/src/devices/machine/gen_latch.h b/src/devices/machine/gen_latch.h index 65149fc5985..2da8ca41cfb 100644 --- a/src/devices/machine/gen_latch.h +++ b/src/devices/machine/gen_latch.h @@ -35,6 +35,9 @@ public: DECLARE_READ8_MEMBER( read ); DECLARE_WRITE8_MEMBER( write ); + + DECLARE_WRITE8_MEMBER( preset_w ); + DECLARE_WRITE8_MEMBER( clear_w ); DECLARE_WRITE_LINE_MEMBER( preset_w ); DECLARE_WRITE_LINE_MEMBER( clear_w ); @@ -61,6 +64,9 @@ public: DECLARE_READ16_MEMBER( read ); DECLARE_WRITE16_MEMBER( write ); + + DECLARE_WRITE16_MEMBER( preset_w ); + DECLARE_WRITE16_MEMBER( clear_w ); DECLARE_WRITE_LINE_MEMBER( preset_w ); DECLARE_WRITE_LINE_MEMBER( clear_w );