summaryrefslogtreecommitdiffstatshomepage
path: root/src/emu/machine/omti5100.c
blob: 8e4e8fcfa53a21e2cb4d7dcd02f611fc96c22fd0 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
/***************************************************************************

    SMS OMTI 5100

    license: MAME, GPL-2.0+
    copyright-holders: Dirk Best

    SCSI/SASI Intelligent Data Controller

    Note: - Skeleton device
          - Supports up to two ST-506/412 hard drives
          - Z8681 (Z8)
          - 8 KB RAM
          - 2 KB Buffer RAM

***************************************************************************/

#include "omti5100.h"


//**************************************************************************
//  CONSTANTS
//**************************************************************************

#define VERBOSE 1


//**************************************************************************
//  DEVICE DEFINITIONS
//**************************************************************************

const device_type OMTI5100 = &device_creator<omti5100_device>;

//-------------------------------------------------
//  rom_region - device-specific ROM region
//-------------------------------------------------

ROM_START( omti5100_firmware )
	ROM_REGION(0x2000, "firmware", 0)
	ROM_LOAD("1002401-n.7a", 0x0000, 0x2000, CRC(d531e25c) SHA1(22e4762a70841b80e843a5d76175c1fdb6838e18))
ROM_END

const rom_entry *omti5100_device::device_rom_region() const
{
	return ROM_NAME( omti5100_firmware );
}

//-------------------------------------------------
//  machine_config_additions - device-specific
//  machine configurations
//-------------------------------------------------

static MACHINE_CONFIG_FRAGMENT( omti5100_z8 )
//  MCFG_CPU_ADD("z8", Z8681, XTAL_20MHz / 3 /* ??? */)
MACHINE_CONFIG_END

machine_config_constructor omti5100_device::device_mconfig_additions() const
{
	return MACHINE_CONFIG_NAME( omti5100_z8 );
}


//**************************************************************************
//  LIVE DEVICE
//**************************************************************************

//-------------------------------------------------
//  omti5100_device - constructor
//-------------------------------------------------

omti5100_device::omti5100_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock) :
	device_t(mconfig, OMTI5100, "OMTI 5100 SCSI/SASI Controller", tag, owner, clock, "omti5100", __FILE__),
//  m_cpu(*this, "z8"),
	m_bsy_w(*this),
	m_cd_w(*this),
	m_io_w(*this),
	m_req_w(*this),
	m_msg_w(*this)
{
}

//-------------------------------------------------
//  device_start - device-specific startup
//-------------------------------------------------

void omti5100_device::device_start()
{
	// resolve callbacks
	m_bsy_w.resolve_safe();
	m_cd_w.resolve_safe();
	m_io_w.resolve_safe();
	m_req_w.resolve_safe();
	m_msg_w.resolve_safe();
}

//-------------------------------------------------
//  device_reset - device-specific reset
//-------------------------------------------------

void omti5100_device::device_reset()
{
}


//**************************************************************************
//  IMPLEMENTATION
//**************************************************************************

READ8_MEMBER( omti5100_device::data_r )
{
	if (VERBOSE)
		logerror("%s: data_r\n", tag());

	return 0xff;
}

WRITE8_MEMBER( omti5100_device::data_w )
{
	if (VERBOSE)
		logerror("%s: rst_w: %02x\n", tag(), data);
}

READ_LINE_MEMBER( omti5100_device::parity_r )
{
	if (VERBOSE)
		logerror("%s: parity_r\n", tag());

	return 1;
}

WRITE_LINE_MEMBER( omti5100_device::parity_w )
{
	if (VERBOSE)
		logerror("%s: parity_w: %d\n", tag(), state);
}

WRITE_LINE_MEMBER( omti5100_device::rst_w )
{
	if (VERBOSE)
		logerror("%s: rst_w: %d\n", tag(), state);
}

WRITE_LINE_MEMBER( omti5100_device::sel_w )
{
	if (VERBOSE)
		logerror("%s: sel_w: %d\n", tag(), state);
}

WRITE_LINE_MEMBER( omti5100_device::ack_w )
{
	if (VERBOSE)
		logerror("%s: ack_w: %d\n", tag(), state);
}