summaryrefslogtreecommitdiffstatshomepage
path: root/src/mame/machine/abc80kb.cpp
blob: d689ea88c1f9b702ce59b9628d9f696813467372 (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
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
// license:BSD-3-Clause
// copyright-holders:Curt Coder
/**********************************************************************

    Luxor ABC-80 keyboard emulation

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

/*

PCB Layout
----------

KTC 65-01870-001 (dated 1978)
PCB-002B

    |---------------|
|---|      CN1      |---------------------------------------------------|
|                                                                       |
|   LS06    LS04    LS04                        LS06    LS00    LS123   |
|   LS74                    PROM        MCU             4051    900C    |
|                                                                       |
|                                                                       |
|                                                                       |
|                                                                       |
|                                                                       |
|                                                                       |
|                                                                       |
|                                                                       |
|-----------------------------------------------------------------------|

Notes:
    All IC's shown.

    MCU         - General Instruments 30293B-013 20-04592-013 (?)
    PROM        - Synertek N82S141N 512x8 bipolar PROM "053"
    900C        - Ferranti Interdesign 900C custom (?)
    CN1         - keyboard data connector

*/

/*

PCB Layout
----------

KTC A65-01870-001 (dated 1983)
PCB-201C

    |---------------|
|---|      CN1      |---------------------------------------------------|
|                                                                       |
|   LS06    LS04    LS04                                LS00    LS123   |
|                                       MCU             4051    900C    |
|                                                                       |
|                                                                       |
|                                                                       |
|                                                                       |
|                                                                       |
|                                                                       |
|                                                                       |
|                                                                       |
|-----------------------------------------------------------------------|

Notes:
    All IC's shown.

    MCU         - General Instruments 30293B-047 20-04592-047 (?)
    900C        - Ferranti Interdesign 900C custom (?)
    CN1         - keyboard data connector

*/

#include "emu.h"
#include "abc80kb.h"

#include "cpu/mcs48/mcs48.h"



//**************************************************************************
//  MACROS / CONSTANTS
//**************************************************************************

#define I8048_TAG       "i8048"



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

DEFINE_DEVICE_TYPE(ABC80_KEYBOARD, abc80_keyboard_device, "abc80kb", "ABC-80 Keyboard")


//-------------------------------------------------
//  ROM( abc80_keyboard )
//-------------------------------------------------

ROM_START( abc80_keyboard )
	ROM_REGION( 0x400, I8048_TAG, 0 )
	ROM_LOAD( "053.z5", 0x0000, 0x0400, NO_DUMP )
ROM_END


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

const tiny_rom_entry *abc80_keyboard_device::device_rom_region() const
{
	return ROM_NAME( abc80_keyboard );
}


//-------------------------------------------------
//  ADDRESS_MAP( abc80_keyboard_io )
//-------------------------------------------------

static ADDRESS_MAP_START( abc80_keyboard_io, AS_IO, 8, abc80_keyboard_device )
ADDRESS_MAP_END


//-------------------------------------------------
//  MACHINE_DRIVER( abc80_keyboard )
//-------------------------------------------------

static MACHINE_CONFIG_FRAGMENT( abc80_keyboard )
	MCFG_CPU_ADD(I8048_TAG, I8048, 4000000)
	MCFG_CPU_IO_MAP(abc80_keyboard_io)
	MCFG_DEVICE_DISABLE()
MACHINE_CONFIG_END


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

machine_config_constructor abc80_keyboard_device::device_mconfig_additions() const
{
	return MACHINE_CONFIG_NAME( abc80_keyboard );
}


//-------------------------------------------------
//  INPUT_PORTS( abc80_keyboard )
//-------------------------------------------------

INPUT_PORTS_START( abc80_keyboard )
INPUT_PORTS_END


//-------------------------------------------------
//  input_ports - device-specific input ports
//-------------------------------------------------

ioport_constructor abc80_keyboard_device::device_input_ports() const
{
	return INPUT_PORTS_NAME( abc80_keyboard );
}



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

//-------------------------------------------------
//  abc80_keyboard_device - constructor
//-------------------------------------------------

abc80_keyboard_device::abc80_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock)
	: device_t(mconfig, ABC80_KEYBOARD, tag, owner, clock)
	, m_write_keydown(*this)
	, m_maincpu(*this, I8048_TAG)
{
}


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

void abc80_keyboard_device::device_start()
{
	// resolve callbacks
	m_write_keydown.resolve_safe();
}


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

void abc80_keyboard_device::device_reset()
{
}


//-------------------------------------------------
//  data_r - keyboard data read
//-------------------------------------------------

uint8_t abc80_keyboard_device::data_r()
{
	return 0;
}