diff options
author | angelosa <salese_corp_ltd@email.it> | 2016-06-14 19:50:02 +0200 |
---|---|---|
committer | angelosa <salese_corp_ltd@email.it> | 2016-06-14 19:50:43 +0200 |
commit | 3c030752cf3feebf7c50e15bb47bf16aa9ac1960 (patch) | |
tree | 9191d67dbc462d5c7c547365ef18c9af30e9bc30 /src/devices | |
parent | 4ceb1a97f3eda4413b0f94d2956e21818af65c78 (diff) |
Added bare-bones Sony LDP-1000 device (nw)
Diffstat (limited to 'src/devices')
-rw-r--r-- | src/devices/machine/ldp1000.cpp | 120 | ||||
-rw-r--r-- | src/devices/machine/ldp1000.h | 67 |
2 files changed, 187 insertions, 0 deletions
diff --git a/src/devices/machine/ldp1000.cpp b/src/devices/machine/ldp1000.cpp new file mode 100644 index 00000000000..922f3c2b63e --- /dev/null +++ b/src/devices/machine/ldp1000.cpp @@ -0,0 +1,120 @@ +// license:BSD-3-Clause +// copyright-holders:Angelo Salese +/*************************************************************************** + + Sony LDP-1000 laserdisc emulation. + + TODO: + - Dump BIOSes (seven of them according to docs) + - Hookup with Sony SMC-70 / SMC-777 + +***************************************************************************/ + +#include "emu.h" +#include "machine/ldp1000.h" + + +ROM_START( ldp1000 ) + ROM_REGION( 0x2000, "ldp1000", 0 ) + ROM_LOAD( "ldp1000_bios.bin", 0x0000, 0x2000, NO_DUMP ) +ROM_END + +//************************************************************************** +// GLOBAL VARIABLES +//************************************************************************** + +// device type definition +const device_type SONY_LDP1000 = &device_creator<sony_ldp1000_device>; + + +//************************************************************************** +// LIVE DEVICE +//************************************************************************** + +//------------------------------------------------- +// ldp1000_device - constructor +//------------------------------------------------- + +sony_ldp1000_device::sony_ldp1000_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock) + : laserdisc_device(mconfig, SONY_LDP1000, "Sony LDP-1000", tag, owner, clock, "ldp1000", __FILE__) +{ +} + + +//------------------------------------------------- +// device_validity_check - perform validity checks +// on this device +//------------------------------------------------- + +void sony_ldp1000_device::device_validity_check(validity_checker &valid) const +{ +} + + +//------------------------------------------------- +// device_start - device-specific startup +//------------------------------------------------- + +void sony_ldp1000_device::device_start() +{ + laserdisc_device::device_start(); +} + + +//------------------------------------------------- +// device_reset - device-specific reset +//------------------------------------------------- + +void sony_ldp1000_device::device_reset() +{ + laserdisc_device::device_reset(); + +} + +//------------------------------------------------- +// device_rom_region - return a pointer to our +// ROM region definitions +//------------------------------------------------- + +const rom_entry *sony_ldp1000_device::device_rom_region() const +{ + return ROM_NAME(ldp1000); +} + + +//------------------------------------------------- +// player_vsync - VSYNC callback, called at the +// start of the blanking period +//------------------------------------------------- + +void sony_ldp1000_device::player_vsync(const vbi_metadata &vbi, int fieldnum, const attotime &curtime) +{ + //printf("%d vsync\n",fieldnum); +} + + +//------------------------------------------------- +// player_update - update callback, called on +// the first visible line of the frame +//------------------------------------------------- + +INT32 sony_ldp1000_device::player_update(const vbi_metadata &vbi, int fieldnum, const attotime &curtime) +{ + //printf("%d update\n",fieldnum); + + return fieldnum; +} + + +//************************************************************************** +// READ/WRITE HANDLERS +//************************************************************************** + +READ8_MEMBER( sony_ldp1000_device::read ) +{ + return 0; +} + +WRITE8_MEMBER( sony_ldp1000_device::write ) +{ +} diff --git a/src/devices/machine/ldp1000.h b/src/devices/machine/ldp1000.h new file mode 100644 index 00000000000..ee7acc789bf --- /dev/null +++ b/src/devices/machine/ldp1000.h @@ -0,0 +1,67 @@ +// license:BSD-3-Clause +// copyright-holders:Angelo Salese +/*************************************************************************** + + Sony LDP-1000 laserdisc emulation. + +***************************************************************************/ + +#pragma once + +#ifndef __LDP1000DEV_H__ +#define __LDP1000DEV_H__ + +#include "laserdsc.h" + + +//************************************************************************** +// INTERFACE CONFIGURATION MACROS +//************************************************************************** + +#define MCFG_LASERDISC_LDP1000_ADD(_tag) \ + MCFG_DEVICE_ADD(_tag, SONY_LDP1000, 0) + +//************************************************************************** +// TYPE DEFINITIONS +//************************************************************************** + +// device type definition +extern const device_type SONY_LDP1000; + +// ======================> sony_ldp1000_device + +class sony_ldp1000_device : public laserdisc_device +{ +public: + // construction/destruction + sony_ldp1000_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock); + + // I/O operations + DECLARE_WRITE8_MEMBER( write ); + DECLARE_READ8_MEMBER( read ); + +protected: + // device-level overrides + virtual void device_validity_check(validity_checker &valid) const override; + virtual void device_start() override; + virtual void device_reset() override; + virtual const rom_entry *device_rom_region() const override; + + virtual void player_vsync(const vbi_metadata &vbi, int fieldnum, const attotime &curtime) override; + virtual INT32 player_update(const vbi_metadata &vbi, int fieldnum, const attotime &curtime) override; + virtual void player_overlay(bitmap_yuy16 &bitmap) override { } + +}; + + + + + + +//************************************************************************** +// GLOBAL VARIABLES +//************************************************************************** + + + +#endif |