| Previous | 199869 Revisions | Next |
| r31661 Friday 15th August, 2014 at 07:30:57 UTC by Sandro Ronco |
|---|
| (MESS) dmv: added expansions slot interface. [rfka01, Sandro Ronco] (MESS) dmv: added boot ROMs from 4 different boards. [rfka01] |
| [src/emu/bus] | bus.mak |
| [src/emu/bus/dmv] | dmv_dsk.c* dmv_dsk.h* dmvbus.c* dmvbus.h* k220.c* k220.h* k230.c* k230.h* k806.c* k806.h* ram.c* ram.h* |
| [src/lib] | lib.mak |
| [src/lib/formats] | dmv_dsk.c* dmv_dsk.h* |
| [src/mess] | mess.mak |
| [src/mess/drivers] | dmv.c |
| [src/mess/layout] | dmv.lay |
| [src/mess/machine] | dmv_keyb.c |
| r0 | r31661 | |
|---|---|---|
| 1 | /********************************************************************* | |
| 2 | ||
| 3 | formats/dmv_dsk.h | |
| 4 | ||
| 5 | NCR Decision Mate V format | |
| 6 | ||
| 7 | *********************************************************************/ | |
| 8 | ||
| 9 | #ifndef DMV_DSK_H_ | |
| 10 | #define DMV_DSK_H_ | |
| 11 | ||
| 12 | #include "upd765_dsk.h" | |
| 13 | ||
| 14 | class dmv_format : public upd765_format { | |
| 15 | public: | |
| 16 | dmv_format(); | |
| 17 | ||
| 18 | virtual const char *name() const; | |
| 19 | virtual const char *description() const; | |
| 20 | virtual const char *extensions() const; | |
| 21 | ||
| 22 | private: | |
| 23 | static const format formats[]; | |
| 24 | }; | |
| 25 | ||
| 26 | extern const floppy_format_type FLOPPY_DMV_FORMAT; | |
| 27 | ||
| 28 | #endif /* DMV_DSK_H_ */ |
| Added: svn:eol-style + native Added: svn:mime-type + text/plain |
| r0 | r31661 | |
|---|---|---|
| 1 | // license:BSD-3-Clause | |
| 2 | // copyright-holders:Sandro Ronco | |
| 3 | #pragma once | |
| 4 | ||
| 5 | #ifndef __DMV_K806_H__ | |
| 6 | #define __DMV_K806_H__ | |
| 7 | ||
| 8 | #include "emu.h" | |
| 9 | #include "dmvbus.h" | |
| 10 | #include "cpu/mcs48/mcs48.h" | |
| 11 | ||
| 12 | ||
| 13 | //************************************************************************** | |
| 14 | // TYPE DEFINITIONS | |
| 15 | //************************************************************************** | |
| 16 | ||
| 17 | // ======================> dmv_k806_device | |
| 18 | ||
| 19 | class dmv_k806_device : | |
| 20 | public device_t, | |
| 21 | public device_dmvslot_interface | |
| 22 | { | |
| 23 | public: | |
| 24 | // construction/destruction | |
| 25 | dmv_k806_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock); | |
| 26 | ||
| 27 | // optional information overrides | |
| 28 | virtual const rom_entry *device_rom_region() const; | |
| 29 | virtual ioport_constructor device_input_ports() const; | |
| 30 | virtual machine_config_constructor device_mconfig_additions() const; | |
| 31 | ||
| 32 | DECLARE_READ8_MEMBER(portt1_r); | |
| 33 | DECLARE_READ8_MEMBER(port1_r); | |
| 34 | DECLARE_WRITE8_MEMBER(port1_w); | |
| 35 | ||
| 36 | protected: | |
| 37 | // device-level overrides | |
| 38 | virtual void device_start(); | |
| 39 | virtual void device_reset(); | |
| 40 | ||
| 41 | virtual void io_read(address_space &space, int ifsel, offs_t offset, UINT8 &data); | |
| 42 | virtual void io_write(address_space &space, int ifsel, offs_t offset, UINT8 data); | |
| 43 | ||
| 44 | private: | |
| 45 | required_device<upi41_cpu_device> m_mcu; | |
| 46 | required_ioport m_jumpers; | |
| 47 | }; | |
| 48 | ||
| 49 | ||
| 50 | // device type definition | |
| 51 | extern const device_type DMV_K806; | |
| 52 | ||
| 53 | #endif /* __DMV_K806_H__ */ |
| Added: svn:mime-type + text/plain Added: svn:eol-style + native |
| r0 | r31661 | |
|---|---|---|
| 1 | // license:BSD-3-Clause | |
| 2 | // copyright-holders:Sandro Ronco | |
| 3 | /*************************************************************************** | |
| 4 | ||
| 5 | NCR DMV K220 Diagnostic module | |
| 6 | ||
| 7 | to be inserted into slot 7 only | |
| 8 | ||
| 9 | all semiconductors shown: | |
| 10 | ||
| 11 | |-----------------------------------------------------------------------| | |
| 12 | | | | |
| 13 | | S S NEC D8255AC-5 | | |
| 14 | | PB1 E E | | |
| 15 | | X1 G G | | |
| 16 | | 1 2 SN84LS247N ROM1 | | |
| 17 | | LED1 | | |
| 18 | | LED2 SW1 SN74LS247N C | | |
| 19 | | LED3 TCA965 SW2 N | | |
| 20 | | 8302 SW3 PROM1 ROM2 1 | | |
| 21 | | LED4 SW4 | | |
| 22 | | LED5 TCA965 SW5 | | |
| 23 | | LED6 8240 SW6 | | |
| 24 | | SW7 M5L8253P-5 RAM | | |
| 25 | | LED7 SW8 | | |
| 26 | | LED8 SN7407N | | |
| 27 | | LED9 | | |
| 28 | | | | |
| 29 | | SN74LS14N DM74LS05N DM74LS00M DM74LS04N | | |
| 30 | |-----------------------------------------------------------------------| | |
| 31 | ||
| 32 | PB1: Push Button | |
| 33 | X1: Crystal 24 MHz | |
| 34 | LED 1: red, 5V> | |
| 35 | LED 2: green, 5V- | |
| 36 | LED 3: red, 5V< | |
| 37 | LED 4: red, 12V> | |
| 38 | LED 5: green, 12V- | |
| 39 | LED 6: red, 12V< | |
| 40 | LED 7: green, PCLK/ | |
| 41 | LED 8: green, MEMR/ | |
| 42 | LED 9: green, HLDA | |
| 43 | SEG 1&2 Seven segment displays | |
| 44 | SW1-8 Switches marked top=>bottom Off / Start, S Run / Loop, M Mes / D Mes, CRT / LED, SEL 1, SEL 2, SEL 3, SEL 4 | |
| 45 | PROM 1: TBP24S10N marked 32084 | |
| 46 | ROM 1: MBM2764-30 marked 32564 | |
| 47 | ROM 2: M5L2764K marked 32563 | |
| 48 | RAM: HM6116LP-3 | |
| 49 | ||
| 50 | Inserting the diagnostics module into Slot 7 changes the DMV's memory map: | |
| 51 | ||
| 52 | The diagnostics ROM is inserted between 0x2000 and 0x3FFF, the diagnostics RAM between 0xF000 and 0xF7FF with the diagnostics stack at 0xF700 | |
| 53 | ||
| 54 | ***************************************************************************/ | |
| 55 | ||
| 56 | #include "emu.h" | |
| 57 | #include "k220.h" | |
| 58 | ||
| 59 | ||
| 60 | /*************************************************************************** | |
| 61 | IMPLEMENTATION | |
| 62 | ***************************************************************************/ | |
| 63 | ||
| 64 | ROM_START( dmv_k220 ) | |
| 65 | ROM_REGION(0x4000, "rom", 0) | |
| 66 | ROM_LOAD( "ncr_32563_diagnostics_rom.bin", 0x0000, 0x2000, CRC(57445768) SHA1(59b615437444789bf10ba6768cd3c43a69c7ed7b)) | |
| 67 | ROM_LOAD( "ncr_32564_diagnostics_rom.bin", 0x2000, 0x2000, CRC(172e0c60) SHA1(eedae538636009a5b86fc78e50a03c72eeb0e73b)) | |
| 68 | ||
| 69 | ROM_REGION(0x0080, "prom", 0) | |
| 70 | ROM_LOAD( "u11.bin", 0x0000, 0x0080, NO_DUMP) // used for address decoding | |
| 71 | ||
| 72 | ROM_REGION(0x0800, "ram", ROMREGION_ERASE) | |
| 73 | ROM_END | |
| 74 | ||
| 75 | static MACHINE_CONFIG_FRAGMENT( dmv_k220 ) | |
| 76 | MCFG_DEVICE_ADD("ppi8255", I8255, 0) | |
| 77 | MCFG_I8255_OUT_PORTA_CB(WRITE8(dmv_k220_device, porta_w)) | |
| 78 | MCFG_I8255_IN_PORTB_CB(IOPORT("SWITCH")) | |
| 79 | MCFG_I8255_OUT_PORTC_CB(WRITE8(dmv_k220_device, portc_w)) | |
| 80 | ||
| 81 | MCFG_DEVICE_ADD("pit8253", PIT8253, 0) | |
| 82 | MCFG_PIT8253_CLK0(XTAL_1MHz) // CLK1 | |
| 83 | MCFG_PIT8253_OUT0_HANDLER(WRITELINE(dmv_k220_device, write_out0)) | |
| 84 | MCFG_PIT8253_OUT1_HANDLER(WRITELINE(dmv_k220_device, write_out1)) | |
| 85 | MCFG_PIT8253_OUT2_HANDLER(WRITELINE(dmv_k220_device, write_out2)) | |
| 86 | MACHINE_CONFIG_END | |
| 87 | ||
| 88 | static INPUT_PORTS_START( dmv_k220 ) | |
| 89 | PORT_START("SWITCH") | |
| 90 | PORT_DIPNAME( 0x01, 0x00, "Select 1" ) | |
| 91 | PORT_DIPSETTING( 0x00, DEF_STR(Off) ) | |
| 92 | PORT_DIPSETTING( 0x01, DEF_STR(On) ) | |
| 93 | PORT_DIPNAME( 0x02, 0x00, "Select 2" ) | |
| 94 | PORT_DIPSETTING( 0x00, DEF_STR(Off) ) | |
| 95 | PORT_DIPSETTING( 0x02, DEF_STR(On) ) | |
| 96 | PORT_DIPNAME( 0x04, 0x00, "Select 3" ) | |
| 97 | PORT_DIPSETTING( 0x00, DEF_STR(Off) ) | |
| 98 | PORT_DIPSETTING( 0x04, DEF_STR(On) ) | |
| 99 | PORT_DIPNAME( 0x08, 0x00, "Select 4" ) | |
| 100 | PORT_DIPSETTING( 0x00, DEF_STR(Off) ) | |
| 101 | PORT_DIPSETTING( 0x08, DEF_STR(On) ) | |
| 102 | PORT_DIPNAME( 0x10, 0x10, "Maintenance" ) | |
| 103 | PORT_DIPSETTING( 0x00, DEF_STR(Off) ) | |
| 104 | PORT_DIPSETTING( 0x10, DEF_STR(On) ) | |
| 105 | PORT_DIPNAME( 0x20, 0x20, "Detail Message" ) | |
| 106 | PORT_DIPSETTING( 0x00, DEF_STR(Off) ) | |
| 107 | PORT_DIPSETTING( 0x20, DEF_STR(On) ) | |
| 108 | PORT_DIPNAME( 0x40, 0x40, "Continous Run" ) | |
| 109 | PORT_DIPSETTING( 0x00, DEF_STR(Off) ) | |
| 110 | PORT_DIPSETTING( 0x40, DEF_STR(On) ) | |
| 111 | PORT_DIPNAME( 0x80, 0x80, "Diagnostic module" ) | |
| 112 | PORT_DIPSETTING( 0x00, DEF_STR(Off) ) | |
| 113 | PORT_DIPSETTING( 0x80, DEF_STR(On) ) | |
| 114 | INPUT_PORTS_END | |
| 115 | ||
| 116 | //************************************************************************** | |
| 117 | // GLOBAL VARIABLES | |
| 118 | //************************************************************************** | |
| 119 | ||
| 120 | const device_type DMV_K220 = &device_creator<dmv_k220_device>; | |
| 121 | ||
| 122 | //************************************************************************** | |
| 123 | // LIVE DEVICE | |
| 124 | //************************************************************************** | |
| 125 | ||
| 126 | //------------------------------------------------- | |
| 127 | // dmv_k220_device - constructor | |
| 128 | //------------------------------------------------- | |
| 129 | ||
| 130 | dmv_k220_device::dmv_k220_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock) | |
| 131 | : device_t(mconfig, DMV_K220, "K220 diagnostic", tag, owner, clock, "dmv_k220", __FILE__), | |
| 132 | device_dmvslot_interface( mconfig, *this ), | |
| 133 | m_pit(*this, "pit8253"), | |
| 134 | m_ppi(*this, "ppi8255"), | |
| 135 | m_ram(*this, "ram"), | |
| 136 | m_rom(*this, "rom") | |
| 137 | { | |
| 138 | } | |
| 139 | ||
| 140 | //------------------------------------------------- | |
| 141 | // device_start - device-specific startup | |
| 142 | //------------------------------------------------- | |
| 143 | ||
| 144 | void dmv_k220_device::device_start() | |
| 145 | { | |
| 146 | address_space &space = machine().device<cpu_device>("maincpu")->space(AS_IO); | |
| 147 | space.install_readwrite_handler(0x08, 0x0b, 0, 0, read8_delegate(FUNC(pit8253_device::read), &(*m_pit)), write8_delegate(FUNC(pit8253_device::write), &(*m_pit)), 0); | |
| 148 | space.install_readwrite_handler(0x0c, 0x0f, 0, 0, read8_delegate(FUNC(i8255_device::read), &(*m_ppi)), write8_delegate(FUNC(i8255_device::write), &(*m_ppi)), 0); | |
| 149 | } | |
| 150 | ||
| 151 | //------------------------------------------------- | |
| 152 | // device_reset - device-specific reset | |
| 153 | //------------------------------------------------- | |
| 154 | ||
| 155 | void dmv_k220_device::device_reset() | |
| 156 | { | |
| 157 | // active the correct layout | |
| 158 | machine().render().first_target()->set_view(1); | |
| 159 | } | |
| 160 | ||
| 161 | //------------------------------------------------- | |
| 162 | // machine_config_additions - device-specific | |
| 163 | // machine configurations | |
| 164 | //------------------------------------------------- | |
| 165 | ||
| 166 | machine_config_constructor dmv_k220_device::device_mconfig_additions() const | |
| 167 | { | |
| 168 | return MACHINE_CONFIG_NAME( dmv_k220 ); | |
| 169 | } | |
| 170 | ||
| 171 | //------------------------------------------------- | |
| 172 | // input_ports - device-specific input ports | |
| 173 | //------------------------------------------------- | |
| 174 | ||
| 175 | ioport_constructor dmv_k220_device::device_input_ports() const | |
| 176 | { | |
| 177 | return INPUT_PORTS_NAME( dmv_k220 ); | |
| 178 | } | |
| 179 | ||
| 180 | //------------------------------------------------- | |
| 181 | // device_rom_region | |
| 182 | //------------------------------------------------- | |
| 183 | ||
| 184 | const rom_entry *dmv_k220_device::device_rom_region() const | |
| 185 | { | |
| 186 | return ROM_NAME( dmv_k220 ); | |
| 187 | } | |
| 188 | ||
| 189 | //------------------------------------------------- | |
| 190 | // read | |
| 191 | //------------------------------------------------- | |
| 192 | ||
| 193 | bool dmv_k220_device::read(offs_t offset, UINT8 &data) | |
| 194 | { | |
| 195 | if ((m_portc & 0x01) && offset >= 0x2000 && offset < 0x6000) | |
| 196 | { | |
| 197 | data = m_rom->base()[offset - 0x2000]; | |
| 198 | return true; | |
| 199 | } | |
| 200 | else if ((m_portc & 0x02) && offset >= 0xf000 && offset < 0xf800) | |
| 201 | { | |
| 202 | data = m_ram->base()[offset]; | |
| 203 | return true; | |
| 204 | } | |
| 205 | ||
| 206 | return false; | |
| 207 | } | |
| 208 | ||
| 209 | //------------------------------------------------- | |
| 210 | // write | |
| 211 | //------------------------------------------------- | |
| 212 | ||
| 213 | bool dmv_k220_device::write(offs_t offset, UINT8 data) | |
| 214 | { | |
| 215 | if ((m_portc & 0x01) && offset >= 0x2000 && offset < 0x4000) | |
| 216 | { | |
| 217 | logerror("k220: write on ROM %x %x\n", offset, data); | |
| 218 | return true; | |
| 219 | } | |
| 220 | else if ((m_portc & 0x02) && offset >= 0xf000 && offset < 0xf800) | |
| 221 | { | |
| 222 | m_ram->base()[offset] = data; | |
| 223 | return true; | |
| 224 | } | |
| 225 | ||
| 226 | return false; | |
| 227 | } | |
| 228 | ||
| 229 | WRITE8_MEMBER( dmv_k220_device::porta_w ) | |
| 230 | { | |
| 231 | // 74LS247 BCD-to-Seven-Segment Decoder | |
| 232 | static UINT8 bcd2hex[] = { 0x3f, 0x06, 0x5b, 0x4f, 0x66, 0x6d, 0x7d, 0x07, 0x7f, 0x6f, 0x58, 0x4c, 0x62, 0x69, 0x78, 0x00 }; | |
| 233 | ||
| 234 | output_set_digit_value(0, bcd2hex[(data >> 4) & 0x0f]); | |
| 235 | output_set_digit_value(1, bcd2hex[data & 0x0f]); | |
| 236 | }; | |
| 237 | ||
| 238 | ||
| 239 | WRITE8_MEMBER( dmv_k220_device::portc_w ) | |
| 240 | { | |
| 241 | /* | |
| 242 | xxxx ---- not connected | |
| 243 | ---- x--- PIT gate 2 | |
| 244 | ---- -x-- PIT gate 1 | |
| 245 | ---- --x- enable RAM | |
| 246 | ---- ---x enable ROM | |
| 247 | ||
| 248 | */ | |
| 249 | m_pit->write_gate1(BIT(data, 2)); | |
| 250 | m_pit->write_gate2(BIT(data, 3)); | |
| 251 | ||
| 252 | m_portc = data; | |
| 253 | }; | |
| 254 | ||
| 255 | ||
| 256 | WRITE_LINE_MEMBER( dmv_k220_device::write_out0 ) | |
| 257 | { | |
| 258 | m_pit->write_clk1(state); | |
| 259 | m_pit->write_clk2(state); | |
| 260 | } | |
| 261 | ||
| 262 | ||
| 263 | WRITE_LINE_MEMBER( dmv_k220_device::write_out1 ) | |
| 264 | { | |
| 265 | } | |
| 266 | ||
| 267 | ||
| 268 | WRITE_LINE_MEMBER( dmv_k220_device::write_out2 ) | |
| 269 | { | |
| 270 | } |
| Added: svn:mime-type + text/plain Added: svn:eol-style + native |
| r0 | r31661 | |
|---|---|---|
| 1 | // license:BSD-3-Clause | |
| 2 | // copyright-holders:Sandro Ronco | |
| 3 | /*************************************************************************** | |
| 4 | ||
| 5 | K230 Internal 8088 module without interrupt controller | |
| 6 | K231 External 8088 module without interrupt controller | |
| 7 | K235 Internal 8088 module with interrupt controller | |
| 8 | ||
| 9 | ***************************************************************************/ | |
| 10 | ||
| 11 | #include "emu.h" | |
| 12 | #include "k230.h" | |
| 13 | ||
| 14 | ||
| 15 | /*************************************************************************** | |
| 16 | IMPLEMENTATION | |
| 17 | ***************************************************************************/ | |
| 18 | ||
| 19 | ROM_START( dmv_k230 ) | |
| 20 | ROM_REGION(0x1000, "rom", 0) | |
| 21 | ROM_LOAD( "dmv_int_8088_32167.bin", 0x0000, 0x1000, CRC(f4a58880) SHA1(4f50ef25008851ae6f0c670f19d63f4e61249581)) | |
| 22 | ROM_END | |
| 23 | ||
| 24 | ROM_START( dmv_k231 ) | |
| 25 | ROM_REGION(0x1000, "rom", 0) | |
| 26 | ROM_LOAD( "dmv_ext_8088_32167.bin", 0x0000, 0x1000, CRC(f4a58880) SHA1(4f50ef25008851ae6f0c670f19d63f4e61249581)) | |
| 27 | ROM_END | |
| 28 | ||
| 29 | ROM_START( dmv_k235 ) | |
| 30 | ROM_REGION(0x1000, "rom", 0) | |
| 31 | ROM_LOAD( "dmv_int_8088_pic_33473.bin", 0x0000, 0x1000, CRC(104195dc) SHA1(08d48ca3b84ab26c1a764792e04ec4def7dad2ad)) | |
| 32 | ROM_END | |
| 33 | ||
| 34 | static ADDRESS_MAP_START(k230_mem, AS_PROGRAM, 8, dmv_k230_device) | |
| 35 | ADDRESS_MAP_UNMAP_HIGH | |
| 36 | AM_RANGE( 0x00000, 0x7ffff ) AM_READWRITE(program_r, program_w) | |
| 37 | AM_RANGE( 0x80000, 0xfffff ) AM_READ(rom_r) | |
| 38 | ADDRESS_MAP_END | |
| 39 | ||
| 40 | static ADDRESS_MAP_START(k230_io, AS_IO, 8, dmv_k230_device) | |
| 41 | ADDRESS_MAP_UNMAP_HIGH | |
| 42 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 43 | AM_RANGE( 0x00, 0xff ) AM_READWRITE(io_r, io_w) | |
| 44 | ADDRESS_MAP_END | |
| 45 | ||
| 46 | ||
| 47 | static ADDRESS_MAP_START(k235_io, AS_IO, 8, dmv_k230_device) | |
| 48 | ADDRESS_MAP_UNMAP_HIGH | |
| 49 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 50 | AM_RANGE( 0x90, 0x91 ) AM_DEVREADWRITE("pic8259", pic8259_device, read, write) | |
| 51 | AM_RANGE( 0x00, 0xff ) AM_READWRITE(io_r, io_w) | |
| 52 | ADDRESS_MAP_END | |
| 53 | ||
| 54 | static MACHINE_CONFIG_FRAGMENT( dmv_k230 ) | |
| 55 | MCFG_CPU_ADD("maincpu", I8088, XTAL_24MHz / 6) | |
| 56 | MCFG_CPU_PROGRAM_MAP(k230_mem) | |
| 57 | MCFG_CPU_IO_MAP(k230_io) | |
| 58 | MACHINE_CONFIG_END | |
| 59 | ||
| 60 | static MACHINE_CONFIG_FRAGMENT( dmv_k235 ) | |
| 61 | MCFG_CPU_ADD("maincpu", V20, XTAL_24MHz / 6) | |
| 62 | MCFG_CPU_PROGRAM_MAP(k230_mem) | |
| 63 | MCFG_CPU_IO_MAP(k235_io) | |
| 64 | MCFG_CPU_IRQ_ACKNOWLEDGE_DEVICE("pic8259", pic8259_device, inta_cb) | |
| 65 | ||
| 66 | MCFG_PIC8259_ADD("pic8259", INPUTLINE("maincpu", 0), VCC, NULL) | |
| 67 | MACHINE_CONFIG_END | |
| 68 | ||
| 69 | ||
| 70 | //************************************************************************** | |
| 71 | // GLOBAL VARIABLES | |
| 72 | //************************************************************************** | |
| 73 | ||
| 74 | const device_type DMV_K230 = &device_creator<dmv_k230_device>; | |
| 75 | const device_type DMV_K231 = &device_creator<dmv_k231_device>; | |
| 76 | const device_type DMV_K235 = &device_creator<dmv_k235_device>; | |
| 77 | ||
| 78 | //************************************************************************** | |
| 79 | // LIVE DEVICE | |
| 80 | //************************************************************************** | |
| 81 | ||
| 82 | //------------------------------------------------- | |
| 83 | // dmv_k230_device - constructor | |
| 84 | //------------------------------------------------- | |
| 85 | ||
| 86 | dmv_k230_device::dmv_k230_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock) | |
| 87 | : device_t(mconfig, DMV_K230, "K230 8088 without interrupt controller", tag, owner, clock, "dmv_k230", __FILE__), | |
| 88 | device_dmvslot_interface( mconfig, *this ), | |
| 89 | m_maincpu(*this, "maincpu"), | |
| 90 | m_rom(*this, "rom") | |
| 91 | { | |
| 92 | } | |
| 93 | ||
| 94 | dmv_k230_device::dmv_k230_device(const machine_config &mconfig, device_type type, const char *name, const char *tag, device_t *owner, UINT32 clock, const char *shortname, const char *source) | |
| 95 | : device_t(mconfig, type, name, tag, owner, clock, shortname, source), | |
| 96 | device_dmvslot_interface( mconfig, *this ), | |
| 97 | m_maincpu(*this, "maincpu"), | |
| 98 | m_rom(*this, "rom") | |
| 99 | { | |
| 100 | } | |
| 101 | ||
| 102 | //------------------------------------------------- | |
| 103 | // dmv_k231_device - constructor | |
| 104 | //------------------------------------------------- | |
| 105 | ||
| 106 | dmv_k231_device::dmv_k231_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock) | |
| 107 | : dmv_k230_device(mconfig, DMV_K231, "K231 8088 without interrupt controller", tag, owner, clock, "dmv_k231", __FILE__) | |
| 108 | { | |
| 109 | } | |
| 110 | ||
| 111 | //------------------------------------------------- | |
| 112 | // dmv_k235_device - constructor | |
| 113 | //------------------------------------------------- | |
| 114 | ||
| 115 | dmv_k235_device::dmv_k235_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock) | |
| 116 | : dmv_k230_device(mconfig, DMV_K235, "K235 8088 with interrupt controller", tag, owner, clock, "dmv_k235", __FILE__), | |
| 117 | m_pic(*this, "pic8259") | |
| 118 | { | |
| 119 | } | |
| 120 | ||
| 121 | ||
| 122 | //------------------------------------------------- | |
| 123 | // device_start - device-specific startup | |
| 124 | //------------------------------------------------- | |
| 125 | ||
| 126 | void dmv_k230_device::device_start() | |
| 127 | { | |
| 128 | m_bus = static_cast<dmvcart_slot_device*>(owner()); | |
| 129 | m_io = &machine().device<cpu_device>("maincpu")->space(AS_IO); | |
| 130 | } | |
| 131 | ||
| 132 | //------------------------------------------------- | |
| 133 | // device_reset - device-specific reset | |
| 134 | //------------------------------------------------- | |
| 135 | ||
| 136 | void dmv_k230_device::device_reset() | |
| 137 | { | |
| 138 | } | |
| 139 | ||
| 140 | //------------------------------------------------- | |
| 141 | // machine_config_additions - device-specific | |
| 142 | // machine configurations | |
| 143 | //------------------------------------------------- | |
| 144 | ||
| 145 | machine_config_constructor dmv_k230_device::device_mconfig_additions() const | |
| 146 | { | |
| 147 | return MACHINE_CONFIG_NAME( dmv_k230 ); | |
| 148 | } | |
| 149 | ||
| 150 | machine_config_constructor dmv_k235_device::device_mconfig_additions() const | |
| 151 | { | |
| 152 | return MACHINE_CONFIG_NAME( dmv_k235 ); | |
| 153 | } | |
| 154 | ||
| 155 | //------------------------------------------------- | |
| 156 | // device_rom_region | |
| 157 | //------------------------------------------------- | |
| 158 | ||
| 159 | const rom_entry *dmv_k230_device::device_rom_region() const | |
| 160 | { | |
| 161 | return ROM_NAME( dmv_k230 ); | |
| 162 | } | |
| 163 | ||
| 164 | const rom_entry *dmv_k231_device::device_rom_region() const | |
| 165 | { | |
| 166 | return ROM_NAME( dmv_k231 ); | |
| 167 | } | |
| 168 | ||
| 169 | const rom_entry *dmv_k235_device::device_rom_region() const | |
| 170 | { | |
| 171 | return ROM_NAME( dmv_k235 ); | |
| 172 | } | |
| 173 | ||
| 174 | bool dmv_k230_device::av16bit() | |
| 175 | { | |
| 176 | return true; | |
| 177 | } | |
| 178 | ||
| 179 | void dmv_k230_device::hold_w(int state) | |
| 180 | { | |
| 181 | m_maincpu->set_input_line(INPUT_LINE_HALT, state); | |
| 182 | } | |
| 183 | ||
| 184 | READ8_MEMBER(dmv_k230_device::rom_r) | |
| 185 | { | |
| 186 | return m_rom->base()[offset & 0x0fff]; | |
| 187 | } | |
| 188 | ||
| 189 | READ8_MEMBER( dmv_k230_device::io_r ) | |
| 190 | { | |
| 191 | return m_io->read_byte(offset); | |
| 192 | } | |
| 193 | ||
| 194 | WRITE8_MEMBER( dmv_k230_device::io_w ) | |
| 195 | { | |
| 196 | m_io->write_byte(offset, data); | |
| 197 | }; | |
| 198 | ||
| 199 | READ8_MEMBER( dmv_k230_device::program_r ) | |
| 200 | { | |
| 201 | return m_bus->m_prog_read_cb(space, offset); | |
| 202 | }; | |
| 203 | ||
| 204 | WRITE8_MEMBER( dmv_k230_device::program_w ) | |
| 205 | { | |
| 206 | m_bus->m_prog_write_cb(space, offset, data); | |
| 207 | }; |
| Added: svn:mime-type + text/plain Added: svn:eol-style + native |
| r0 | r31661 | |
|---|---|---|
| 1 | // license:BSD-3-Clause | |
| 2 | // copyright-holders:Sandro Ronco | |
| 3 | /*************************************************************************** | |
| 4 | ||
| 5 | K200 64K RAM expansion | |
| 6 | K202 192K RAM expansion | |
| 7 | K208 448K RAM expansion | |
| 8 | ||
| 9 | ***************************************************************************/ | |
| 10 | ||
| 11 | #include "emu.h" | |
| 12 | #include "ram.h" | |
| 13 | ||
| 14 | ||
| 15 | /*************************************************************************** | |
| 16 | IMPLEMENTATION | |
| 17 | ***************************************************************************/ | |
| 18 | ||
| 19 | //************************************************************************** | |
| 20 | // GLOBAL VARIABLES | |
| 21 | //************************************************************************** | |
| 22 | ||
| 23 | const device_type DMV_K200 = &device_creator<dmv_k200_device>; | |
| 24 | const device_type DMV_K202 = &device_creator<dmv_k202_device>; | |
| 25 | const device_type DMV_K208 = &device_creator<dmv_k208_device>; | |
| 26 | ||
| 27 | //************************************************************************** | |
| 28 | // LIVE DEVICE | |
| 29 | //************************************************************************** | |
| 30 | ||
| 31 | //------------------------------------------------- | |
| 32 | // dmv_ram_device - constructor | |
| 33 | //------------------------------------------------- | |
| 34 | ||
| 35 | dmv_ram_device::dmv_ram_device(const machine_config &mconfig, device_type type, UINT32 size, const char *name, const char *tag, device_t *owner, UINT32 clock, const char *shortname, const char *source) | |
| 36 | : device_t(mconfig, type, name, tag, owner, clock, shortname, source), | |
| 37 | device_dmvslot_interface( mconfig, *this ), | |
| 38 | m_size(size) | |
| 39 | { | |
| 40 | } | |
| 41 | ||
| 42 | //------------------------------------------------- | |
| 43 | // dmv_k200_device - constructor | |
| 44 | //------------------------------------------------- | |
| 45 | ||
| 46 | dmv_k200_device::dmv_k200_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock) | |
| 47 | : dmv_ram_device(mconfig, DMV_K200, 1, "K200 64K RAM expansion", tag, owner, clock, "dmv_k200", __FILE__) | |
| 48 | { | |
| 49 | } | |
| 50 | ||
| 51 | //------------------------------------------------- | |
| 52 | // dmv_k202_device - constructor | |
| 53 | //------------------------------------------------- | |
| 54 | ||
| 55 | dmv_k202_device::dmv_k202_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock) | |
| 56 | : dmv_ram_device(mconfig, DMV_K202, 3, "K202 192K RAM expansion", tag, owner, clock, "dmv_k202", __FILE__) | |
| 57 | { | |
| 58 | } | |
| 59 | ||
| 60 | //------------------------------------------------- | |
| 61 | // dmv_k208_device - constructor | |
| 62 | //------------------------------------------------- | |
| 63 | ||
| 64 | dmv_k208_device::dmv_k208_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock) | |
| 65 | : dmv_ram_device(mconfig, DMV_K208, 7 , "K208 448K RAM expansion", tag, owner, clock, "dmv_k208", __FILE__) | |
| 66 | { | |
| 67 | } | |
| 68 | ||
| 69 | //------------------------------------------------- | |
| 70 | // device_start - device-specific startup | |
| 71 | //------------------------------------------------- | |
| 72 | ||
| 73 | void dmv_ram_device::device_start() | |
| 74 | { | |
| 75 | m_ram = machine().memory().region_alloc( "expram", m_size * 0x10000, 1, ENDIANNESS_LITTLE )->base(); | |
| 76 | } | |
| 77 | ||
| 78 | //------------------------------------------------- | |
| 79 | // read | |
| 80 | //------------------------------------------------- | |
| 81 | ||
| 82 | void dmv_ram_device::ram_read(UINT8 cas, offs_t offset, UINT8 &data) | |
| 83 | { | |
| 84 | if (cas && cas <= m_size) | |
| 85 | data = m_ram[((cas - 1) << 16) | (offset & 0xffff)]; | |
| 86 | } | |
| 87 | ||
| 88 | //------------------------------------------------- | |
| 89 | // write | |
| 90 | //------------------------------------------------- | |
| 91 | ||
| 92 | void dmv_ram_device::ram_write(UINT8 cas, offs_t offset, UINT8 data) | |
| 93 | { | |
| 94 | if (cas && cas <= m_size) | |
| 95 | m_ram[((cas - 1) << 16) | (offset & 0xffff)] = data; | |
| 96 | } |
| Added: svn:mime-type + text/plain Added: svn:eol-style + native |
| r0 | r31661 | |
|---|---|---|
| 1 | // license:BSD-3-Clause | |
| 2 | // copyright-holders:Sandro Ronco | |
| 3 | /********************************************************************* | |
| 4 | ||
| 5 | NCR Decision mate slot bus and module emulation | |
| 6 | ||
| 7 | From the NCR System Technical manual: | |
| 8 | ||
| 9 | "The lower part of the controller board contains the I/0 bus together with | |
| 10 | seven user-accessible connectors. These connectors are identified on the board | |
| 11 | as J1 through J7 (reading from left to right), and correspond to the seven slots | |
| 12 | (numbers 1 through 7) at the rear of the cabinet. | |
| 13 | Position J1 is reserved for the connection of any one of the memory expansion modules | |
| 14 | (K200, K202, K208). | |
| 15 | Position J7 is reserved for the connection of either the diagnostic module (K220), | |
| 16 | or the customer-installable 16-bit processor module (K231). | |
| 17 | Positions J2 through J6 are the general purpose slots for the connection of the peripheral | |
| 18 | adapter and other interfaces to the computer. These five positions are identical, and Figure 2.2 | |
| 19 | defines the type of connector, while the pin assignments are shown in Figure 2.3." | |
| 20 | ||
| 21 | Pinout (/ indicates an inverted signal, ie, one that would have a bar over it | |
| 22 | on a schematic diagram) | |
| 23 | ||
| 24 | a c | |
| 25 | |-------------------------| | |
| 26 | |+5V 1 +5 V | | |
| 27 | | | | |
| 28 | | 2 +12 V | | |
| 29 | | | | |
| 30 | System Reset Output, act. low |RESET/ 3 RESET IN/| active low, general system RESET | |
| 31 | | | | |
| 32 | I/O Write |IOW/ 4 IOR/ | I/O read R/W lines are Processor control lines | |
| 33 | | | | |
| 34 | Memory Write |MEMW/ 5 MEMR/ | Memory read active low, Tri-State possible | |
| 35 | | | | |
| 36 | BD0-BD7: Switch by IFSEL |BD1 6 BDO | BD0 - BD7: Data-Bus lines (8 bit) | |
| 37 | (I/O-Read). Normal Output. | | bidirectional, active high | |
| 38 | |BD3 7 BD2 | | |
| 39 | | | | |
| 40 | Direction can be changed |BD5 8 BD4 | Bus-Driver to peripheral Bus (LS245) | |
| 41 | by DIR/ signal. | | automatic detection | |
| 42 | |BD7 9 BD6 | | |
| 43 | | | | |
| 44 | Ready Signal from the |READY DMA 10 ABTRI / | Address Bus Tri-State, active low signal | |
| 45 | mem. contr. (XACK), act. hi. | | | |
| 46 | End of Process-EOP signals that|EOP/ 11 | cf. 8234A-6 spec. | |
| 47 | DMA service has been completed | | | |
| 48 | |INTACK/ 12 IFSEL 4/ | | |
| 49 | | | | |
| 50 | Change peripheral from board |AUTO/ 13 DIR/ | Direction of the databus driver. Low signal | |
| 51 | type 1 to 2.NC on type 1 | | change to input. | |
| 52 | Test Hold. External request |THOLD/ 14 HLDA | Hold Acknowledge. A response from the Z80 | |
| 53 | to set the Z80 in hold state. | | The Z80 CPU is in hold state, active high. | |
| 54 | Processor-Clock: inverse signal|PCLK/ 15 CLK1 | Clock Output 1 MHz | |
| 55 | of the CPU clock, freq. 4MHz | | | |
| 56 | Logic Ground |LGRD 16 TRAMD/ | Test RAM-Disable. For ext. ROM or RAM expansion. | |
| 57 | | | Switching with the System RAM, RAM output disabled. act. low | |
| 58 | |BA19 17 BA18 | BA0-BA19: Buffered 20bit Address Bus | |
| 59 | | | | |
| 60 | |BA17 18 BA16 | | |
| 61 | | | | |
| 62 | |BA15 19 BA14 | Range to 1MB Normal output, active high | |
| 63 | | | | |
| 64 | |BA13 20 BA12 | | |
| 65 | | | | |
| 66 | |BA11 21 BA10 | Tri-State possible with ABTRI/ signal | |
| 67 | | | | |
| 68 | |BA9 22 BA8 | | |
| 69 | | | | |
| 70 | |BA7 23 BA6 | | |
| 71 | | | | |
| 72 | |BA5 24 BA4 | | |
| 73 | | | | |
| 74 | |BA3 25 BA2 | | |
| 75 | | | | |
| 76 | |BA1 26 BAO | | |
| 77 | | | | |
| 78 | IFSEL 0-4, active low |IFSEL3/ 27 IFSEL2/ | The select of the I/O pprts in the peripherals is made | |
| 79 | The interface does not need | | by any IFSEL and BA3 (BA3/). (10 peripherals). Automatic | |
| 80 | own address decoder |IFSEL1/ 28 IFSELO/ | change of the data bus direction. This change is not possible | |
| 81 | | | while a dma function is performed | |
| 82 | DRQ0-DRQ1: DMA Request for |DRQ1 29 DRQ0 | Asynchr. channel requests are used by peripherals | |
| 83 | resp. channels, act. high | | to request DMA service | |
| 84 | DACK0-DACK1: |DACK1 / 30 DACK0/ | DMA-Acknowledge Channels 0 and 1, active low | |
| 85 | | | These lines indicate an active DMA channel | |
| 86 | |WAIT/ 31 INT/ | | |
| 87 | | | | |
| 88 | Logic Ground |LGRD 32 LGRD | Logic Ground | |
| 89 | |-------------------------| | |
| 90 | ||
| 91 | Two additional plug/socket connections are possible on the bus. These are made on the solder side of the controller board | |
| 92 | and are designated J2A and J7 A. These connectors are not considered to be user accessible , rather for factory use , | |
| 93 | or for use by field engineers and system integrators. Normally, these two connectors are used for: | |
| 94 | ??? J2A - The connection of the fixed disk interface board, or a custom design board. | |
| 95 | ??? J7A - The connection of the 16-bit processor board (factory option and kit K230). | |
| 96 | ||
| 97 | The processor and diagnostics module for Slots J7 and J7A have the following additional signals in addition to the ones present on Slots J2-J6. | |
| 98 | Note that the middle row of the connector (row "b") carries some signals too: | |
| 99 | ||
| 100 | A2 - OPT 2 | |
| 101 | Signals A19-A26 and C19-C26 are called e.g. A7 instead of BA7 in the processor module schematic (fig. 2.14, page 2.21 System Technical Manual Hardware) | |
| 102 | Signals A6-A9 and C6-D9 are called e.g. D4 instead of BD4 in the processor module schematic | |
| 103 | B10 - READYP | |
| 104 | B11 - HOLD | |
| 105 | B12 - SWITCH 16/ | |
| 106 | B13 - HLDA 16 | |
| 107 | B14 - 16 BITAV | |
| 108 | B15 - STDMARQ | |
| 109 | B16 - LGRD | |
| 110 | B17 - 16 BITSET/ | |
| 111 | B20 - MEMRQ/ | |
| 112 | B32 - LGRD | |
| 113 | ||
| 114 | The memory modules on J1 share the same physical connector with the other expansion modules, but carry different signals: | |
| 115 | ||
| 116 | A1 - +5V C1 - +5V | |
| 117 | A2 C2 | |
| 118 | A3 - AOUT7 C3 | |
| 119 | A4 - AOUT6 C4 - AOUT5 | |
| 120 | A5 - AOUT4 C5 - AOUT3 | |
| 121 | A6 C6 | |
| 122 | A7 C7 | |
| 123 | A8 C8 | |
| 124 | A9 C9 | |
| 125 | A10 C10 - AOUT2 | |
| 126 | A11 C11 - AOUT1 | |
| 127 | A12 - OD0 C12 - AOUT0 | |
| 128 | A13 - OD1 C13 - OD2 | |
| 129 | A14 - OD3 C14 | |
| 130 | A15 C15 | |
| 131 | A16 - LGRD C16 - LGRD | |
| 132 | A17 C17 | |
| 133 | A18 C18 | |
| 134 | A19 - ID0 C19 | |
| 135 | A20 - ID1 C20 | |
| 136 | A21 - ID2 C21 | |
| 137 | A22 - ID3 C22 | |
| 138 | A23 - ID4 C23 - CAS7/ | |
| 139 | A24 - ID5 C24 - CAS6/ | |
| 140 | A25 - ID6 C25 - CAS5/ | |
| 141 | A26 - ID7 C26 - CAS4/ | |
| 142 | A27 - CAS2/ C27 - CAS1/ | |
| 143 | A28 - CAS3/ C28 | |
| 144 | A29 - OD4 C29 - OD5 | |
| 145 | A30 - RAS/ C30 - WE/ | |
| 146 | A31 - OD6 C31 - OD7 | |
| 147 | A32 - LGRD C32 - LGRD | |
| 148 | ||
| 149 | ||
| 150 | ***************************************************************************/ | |
| 151 | ||
| 152 | ||
| 153 | #include "emu.h" | |
| 154 | #include "dmvbus.h" | |
| 155 | ||
| 156 | ||
| 157 | /*************************************************************************** | |
| 158 | PARAMETERS | |
| 159 | ***************************************************************************/ | |
| 160 | ||
| 161 | //************************************************************************** | |
| 162 | // GLOBAL VARIABLES | |
| 163 | //************************************************************************** | |
| 164 | ||
| 165 | const device_type DMVCART_SLOT = &device_creator<dmvcart_slot_device>; | |
| 166 | ||
| 167 | //************************************************************************** | |
| 168 | // DMV cartridge interface | |
| 169 | //************************************************************************** | |
| 170 | ||
| 171 | //------------------------------------------------- | |
| 172 | // device_dmvslot_interface - constructor | |
| 173 | //------------------------------------------------- | |
| 174 | ||
| 175 | device_dmvslot_interface::device_dmvslot_interface(const machine_config &mconfig, device_t &device) | |
| 176 | : device_slot_card_interface(mconfig, device) | |
| 177 | { | |
| 178 | } | |
| 179 | ||
| 180 | ||
| 181 | //------------------------------------------------- | |
| 182 | // ~device_dmvslot_interface - destructor | |
| 183 | //------------------------------------------------- | |
| 184 | ||
| 185 | device_dmvslot_interface::~device_dmvslot_interface() | |
| 186 | { | |
| 187 | } | |
| 188 | ||
| 189 | ||
| 190 | //************************************************************************** | |
| 191 | // LIVE DEVICE | |
| 192 | //************************************************************************** | |
| 193 | ||
| 194 | //------------------------------------------------- | |
| 195 | // dmvcart_slot_device - constructor | |
| 196 | //------------------------------------------------- | |
| 197 | dmvcart_slot_device::dmvcart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock) : | |
| 198 | device_t(mconfig, DMVCART_SLOT, "Decision Mate V cartridge slot", tag, owner, clock, "dmvcart_slot", __FILE__), | |
| 199 | device_slot_interface(mconfig, *this), | |
| 200 | m_prog_read_cb(*this), | |
| 201 | m_prog_write_cb(*this), | |
| 202 | m_out_irq_cb(*this) | |
| 203 | { | |
| 204 | } | |
| 205 | ||
| 206 | ||
| 207 | //------------------------------------------------- | |
| 208 | // dmvcart_slot_device - destructor | |
| 209 | //------------------------------------------------- | |
| 210 | ||
| 211 | dmvcart_slot_device::~dmvcart_slot_device() | |
| 212 | { | |
| 213 | } | |
| 214 | ||
| 215 | //------------------------------------------------- | |
| 216 | // device_start - device-specific startup | |
| 217 | //------------------------------------------------- | |
| 218 | ||
| 219 | void dmvcart_slot_device::device_start() | |
| 220 | { | |
| 221 | m_cart = dynamic_cast<device_dmvslot_interface *>(get_card_device()); | |
| 222 | ||
| 223 | // resolve callbacks | |
| 224 | m_prog_read_cb.resolve_safe(0); | |
| 225 | m_prog_write_cb.resolve_safe(); | |
| 226 | m_out_irq_cb.resolve_safe(); | |
| 227 | } | |
| 228 | ||
| 229 | /*------------------------------------------------- | |
| 230 | read | |
| 231 | -------------------------------------------------*/ | |
| 232 | ||
| 233 | bool dmvcart_slot_device::read(offs_t offset, UINT8 &data) | |
| 234 | { | |
| 235 | if (m_cart) | |
| 236 | return m_cart->read(offset, data); | |
| 237 | return false; | |
| 238 | } | |
| 239 | ||
| 240 | /*------------------------------------------------- | |
| 241 | write | |
| 242 | -------------------------------------------------*/ | |
| 243 | ||
| 244 | bool dmvcart_slot_device::write(offs_t offset, UINT8 data) | |
| 245 | { | |
| 246 | if (m_cart) | |
| 247 | return m_cart->write(offset, data); | |
| 248 | return false; | |
| 249 | } | |
| 250 | ||
| 251 | /*------------------------------------------------- | |
| 252 | read | |
| 253 | -------------------------------------------------*/ | |
| 254 | ||
| 255 | void dmvcart_slot_device::ram_read(UINT8 cas, offs_t offset, UINT8 &data) | |
| 256 | { | |
| 257 | if (m_cart) | |
| 258 | m_cart->ram_read(cas, offset, data); | |
| 259 | } | |
| 260 | ||
| 261 | /*------------------------------------------------- | |
| 262 | write | |
| 263 | -------------------------------------------------*/ | |
| 264 | ||
| 265 | void dmvcart_slot_device::ram_write(UINT8 cas, offs_t offset, UINT8 data) | |
| 266 | { | |
| 267 | if (m_cart) | |
| 268 | return m_cart->ram_write(cas, offset, data); | |
| 269 | } | |
| 270 | ||
| 271 | /*------------------------------------------------- | |
| 272 | IO read | |
| 273 | -------------------------------------------------*/ | |
| 274 | ||
| 275 | void dmvcart_slot_device::io_read(address_space &space, int ifsel, offs_t offset, UINT8 &data) | |
| 276 | { | |
| 277 | if (m_cart) | |
| 278 | m_cart->io_read(space, ifsel, offset, data); | |
| 279 | } | |
| 280 | ||
| 281 | ||
| 282 | /*------------------------------------------------- | |
| 283 | IO write | |
| 284 | -------------------------------------------------*/ | |
| 285 | ||
| 286 | void dmvcart_slot_device::io_write(address_space &space, int ifsel, offs_t offset, UINT8 data) | |
| 287 | { | |
| 288 | if (m_cart) | |
| 289 | m_cart->io_write(space, ifsel, offset, data); | |
| 290 | } | |
| 291 | ||
| 292 | /*------------------------------------------------- | |
| 293 | av16bit | |
| 294 | -------------------------------------------------*/ | |
| 295 | ||
| 296 | bool dmvcart_slot_device::av16bit() | |
| 297 | { | |
| 298 | if (m_cart) | |
| 299 | return m_cart->av16bit(); | |
| 300 | return false; | |
| 301 | } | |
| 302 | ||
| 303 | /*------------------------------------------------- | |
| 304 | hold_w | |
| 305 | -------------------------------------------------*/ | |
| 306 | ||
| 307 | void dmvcart_slot_device::hold_w(int state) | |
| 308 | { | |
| 309 | if (m_cart) | |
| 310 | m_cart->hold_w(state); | |
| 311 | } | |
| 312 | ||
| 313 | void dmvcart_slot_device::irq0_w(int state) | |
| 314 | { | |
| 315 | if (m_cart) | |
| 316 | m_cart->irq0_w(state); | |
| 317 | } | |
| 318 | ||
| 319 | void dmvcart_slot_device::irq1_w(int state) | |
| 320 | { | |
| 321 | if (m_cart) | |
| 322 | m_cart->irq1_w(state); | |
| 323 | } | |
| 324 | ||
| 325 | void dmvcart_slot_device::irq2_w(int state) | |
| 326 | { | |
| 327 | if (m_cart) | |
| 328 | m_cart->irq2_w(state); | |
| 329 | } | |
| 330 | ||
| 331 | void dmvcart_slot_device::irq3_w(int state) | |
| 332 | { | |
| 333 | if (m_cart) | |
| 334 | m_cart->irq3_w(state); | |
| 335 | } | |
| 336 | ||
| 337 | void dmvcart_slot_device::irq4_w(int state) | |
| 338 | { | |
| 339 | if (m_cart) | |
| 340 | m_cart->irq4_w(state); | |
| 341 | } | |
| 342 | ||
| 343 | void dmvcart_slot_device::irq5_w(int state) | |
| 344 | { | |
| 345 | if (m_cart) | |
| 346 | m_cart->irq5_w(state); | |
| 347 | } | |
| 348 | ||
| 349 | void dmvcart_slot_device::irq6_w(int state) | |
| 350 | { | |
| 351 | if (m_cart) | |
| 352 | m_cart->irq6_w(state); | |
| 353 | } | |
| 354 | ||
| 355 | void dmvcart_slot_device::irq7_w(int state) | |
| 356 | { | |
| 357 | if (m_cart) | |
| 358 | m_cart->irq7_w(state); | |
| 359 | } |
| Added: svn:mime-type + text/plain Added: svn:eol-style + native |
| r0 | r31661 | |
|---|---|---|
| 1 | // license:BSD-3-Clause | |
| 2 | // copyright-holders:Sandro Ronco | |
| 3 | #pragma once | |
| 4 | ||
| 5 | #ifndef __DMV_K220_H__ | |
| 6 | #define __DMV_K220_H__ | |
| 7 | ||
| 8 | #include "emu.h" | |
| 9 | #include "dmvbus.h" | |
| 10 | #include "machine/i8255.h" | |
| 11 | #include "machine/pit8253.h" | |
| 12 | ||
| 13 | //************************************************************************** | |
| 14 | // TYPE DEFINITIONS | |
| 15 | //************************************************************************** | |
| 16 | ||
| 17 | // ======================> dmv_k220_device | |
| 18 | ||
| 19 | class dmv_k220_device : | |
| 20 | public device_t, | |
| 21 | public device_dmvslot_interface | |
| 22 | { | |
| 23 | public: | |
| 24 | // construction/destruction | |
| 25 | dmv_k220_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock); | |
| 26 | ||
| 27 | // optional information overrides | |
| 28 | virtual const rom_entry *device_rom_region() const; | |
| 29 | virtual machine_config_constructor device_mconfig_additions() const; | |
| 30 | virtual ioport_constructor device_input_ports() const; | |
| 31 | ||
| 32 | DECLARE_WRITE8_MEMBER(porta_w); | |
| 33 | DECLARE_WRITE8_MEMBER(portc_w); | |
| 34 | DECLARE_WRITE_LINE_MEMBER(write_out0); | |
| 35 | DECLARE_WRITE_LINE_MEMBER(write_out1); | |
| 36 | DECLARE_WRITE_LINE_MEMBER(write_out2); | |
| 37 | ||
| 38 | protected: | |
| 39 | // device-level overrides | |
| 40 | virtual void device_start(); | |
| 41 | virtual void device_reset(); | |
| 42 | ||
| 43 | // dmvcart_interface overrides | |
| 44 | virtual bool read(offs_t offset, UINT8 &data); | |
| 45 | virtual bool write(offs_t offset, UINT8 data); | |
| 46 | ||
| 47 | private: | |
| 48 | required_device<pit8253_device> m_pit; | |
| 49 | required_device<i8255_device> m_ppi; | |
| 50 | required_memory_region m_ram; | |
| 51 | required_memory_region m_rom; | |
| 52 | ||
| 53 | UINT8 m_portc; | |
| 54 | }; | |
| 55 | ||
| 56 | ||
| 57 | // device type definition | |
| 58 | extern const device_type DMV_K220; | |
| 59 | ||
| 60 | #endif /* __DMV_K220_H__ */ |
| Added: svn:mime-type + text/plain Added: svn:eol-style + native |
| r0 | r31661 | |
|---|---|---|
| 1 | // license:BSD-3-Clause | |
| 2 | // copyright-holders:Sandro Ronco | |
| 3 | #pragma once | |
| 4 | ||
| 5 | #ifndef __DMV_K230_H__ | |
| 6 | #define __DMV_K230_H__ | |
| 7 | ||
| 8 | #include "emu.h" | |
| 9 | #include "dmvbus.h" | |
| 10 | #include "cpu/i86/i86.h" | |
| 11 | ||
| 12 | // K235 | |
| 13 | #include "cpu/nec/nec.h" | |
| 14 | #include "machine/pic8259.h" | |
| 15 | ||
| 16 | ||
| 17 | //************************************************************************** | |
| 18 | // TYPE DEFINITIONS | |
| 19 | //************************************************************************** | |
| 20 | ||
| 21 | // ======================> dmv_k230_device | |
| 22 | ||
| 23 | class dmv_k230_device : | |
| 24 | public device_t, | |
| 25 | public device_dmvslot_interface | |
| 26 | { | |
| 27 | public: | |
| 28 | // construction/destruction | |
| 29 | dmv_k230_device(const machine_config &mconfig, device_type type, const char *name, const char *tag, device_t *owner, UINT32 clock, const char *shortname, const char *source); | |
| 30 | dmv_k230_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock); | |
| 31 | ||
| 32 | // optional information overrides | |
| 33 | virtual const rom_entry *device_rom_region() const; | |
| 34 | virtual machine_config_constructor device_mconfig_additions() const; | |
| 35 | ||
| 36 | DECLARE_READ8_MEMBER(io_r); | |
| 37 | DECLARE_READ8_MEMBER(program_r); | |
| 38 | DECLARE_WRITE8_MEMBER(io_w); | |
| 39 | DECLARE_WRITE8_MEMBER(program_w); | |
| 40 | DECLARE_READ8_MEMBER(rom_r); | |
| 41 | ||
| 42 | protected: | |
| 43 | // device-level overrides | |
| 44 | virtual void device_start(); | |
| 45 | virtual void device_reset(); | |
| 46 | ||
| 47 | // dmvcart_interface overrides | |
| 48 | virtual void hold_w(int state); | |
| 49 | virtual bool av16bit(); | |
| 50 | ||
| 51 | private: | |
| 52 | required_device<cpu_device> m_maincpu; | |
| 53 | required_memory_region m_rom; | |
| 54 | dmvcart_slot_device * m_bus; | |
| 55 | address_space * m_io; | |
| 56 | }; | |
| 57 | ||
| 58 | ||
| 59 | // ======================> dmv_k231_device | |
| 60 | ||
| 61 | class dmv_k231_device : | |
| 62 | public dmv_k230_device | |
| 63 | { | |
| 64 | public: | |
| 65 | // construction/destruction | |
| 66 | dmv_k231_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock); | |
| 67 | ||
| 68 | // optional information overrides | |
| 69 | virtual const rom_entry *device_rom_region() const; | |
| 70 | }; | |
| 71 | ||
| 72 | ||
| 73 | // ======================> dmv_k235_device | |
| 74 | ||
| 75 | class dmv_k235_device : | |
| 76 | public dmv_k230_device | |
| 77 | { | |
| 78 | public: | |
| 79 | // construction/destruction | |
| 80 | dmv_k235_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock); | |
| 81 | ||
| 82 | // optional information overrides | |
| 83 | virtual const rom_entry *device_rom_region() const; | |
| 84 | virtual machine_config_constructor device_mconfig_additions() const; | |
| 85 | ||
| 86 | void irq0_w(int state) { m_pic->ir0_w(state); } | |
| 87 | void irq1_w(int state) { m_pic->ir1_w(state); } | |
| 88 | void irq2_w(int state) { m_pic->ir2_w(state); } | |
| 89 | void irq3_w(int state) { m_pic->ir3_w(state); } | |
| 90 | void irq4_w(int state) { m_pic->ir4_w(state); } | |
| 91 | void irq5_w(int state) { m_pic->ir5_w(state); } | |
| 92 | void irq6_w(int state) { m_pic->ir6_w(state); } | |
| 93 | void irq7_w(int state) { m_pic->ir7_w(state); } | |
| 94 | ||
| 95 | private: | |
| 96 | required_device<pic8259_device> m_pic; | |
| 97 | ||
| 98 | }; | |
| 99 | ||
| 100 | // device type definition | |
| 101 | extern const device_type DMV_K230; | |
| 102 | extern const device_type DMV_K231; | |
| 103 | extern const device_type DMV_K235; | |
| 104 | ||
| 105 | #endif /* __DMV_K230_H__ */ |
| Added: svn:mime-type + text/plain Added: svn:eol-style + native |
| r0 | r31661 | |
|---|---|---|
| 1 | // license:BSD-3-Clause | |
| 2 | // copyright-holders:Sandro Ronco | |
| 3 | #pragma once | |
| 4 | ||
| 5 | #ifndef __DMV_RAM_H__ | |
| 6 | #define __DMV_RAM_H__ | |
| 7 | ||
| 8 | #include "emu.h" | |
| 9 | #include "dmvbus.h" | |
| 10 | ||
| 11 | //************************************************************************** | |
| 12 | // TYPE DEFINITIONS | |
| 13 | //************************************************************************** | |
| 14 | ||
| 15 | // ======================> | |
| 16 | ||
| 17 | class dmv_ram_device : | |
| 18 | public device_t, | |
| 19 | public device_dmvslot_interface | |
| 20 | { | |
| 21 | public: | |
| 22 | // construction/destruction | |
| 23 | dmv_ram_device(const machine_config &mconfig, device_type type, UINT32 size, const char *name, const char *tag, device_t *owner, UINT32 clock, const char *shortname, const char *source); | |
| 24 | ||
| 25 | protected: | |
| 26 | // device-level overrides | |
| 27 | virtual void device_start(); | |
| 28 | ||
| 29 | // dmvcart_interface overrides | |
| 30 | virtual void ram_read(UINT8 cas, offs_t offset, UINT8 &data); | |
| 31 | virtual void ram_write(UINT8 cas, offs_t offset, UINT8 data); | |
| 32 | ||
| 33 | private: | |
| 34 | UINT8 * m_ram; | |
| 35 | UINT8 m_size; | |
| 36 | }; | |
| 37 | ||
| 38 | ||
| 39 | class dmv_k200_device : | |
| 40 | public dmv_ram_device | |
| 41 | { | |
| 42 | public: | |
| 43 | // construction/destruction | |
| 44 | dmv_k200_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock); | |
| 45 | }; | |
| 46 | ||
| 47 | ||
| 48 | class dmv_k202_device : | |
| 49 | public dmv_ram_device | |
| 50 | { | |
| 51 | public: | |
| 52 | // construction/destruction | |
| 53 | dmv_k202_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock); | |
| 54 | }; | |
| 55 | ||
| 56 | ||
| 57 | class dmv_k208_device : | |
| 58 | public dmv_ram_device | |
| 59 | { | |
| 60 | public: | |
| 61 | // construction/destruction | |
| 62 | dmv_k208_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock); | |
| 63 | }; | |
| 64 | ||
| 65 | ||
| 66 | // device type definition | |
| 67 | extern const device_type DMV_K200; | |
| 68 | extern const device_type DMV_K202; | |
| 69 | extern const device_type DMV_K208; | |
| 70 | ||
| 71 | #endif /* __DMV_RAM_H__ */ |
| Added: svn:mime-type + text/plain Added: svn:eol-style + native |
| r0 | r31661 | |
|---|---|---|
| 1 | // license:BSD-3-Clause | |
| 2 | // copyright-holders:Sandro Ronco | |
| 3 | /********************************************************************* | |
| 4 | ||
| 5 | Decision Mate V expansion slot | |
| 6 | ||
| 7 | *********************************************************************/ | |
| 8 | ||
| 9 | #ifndef __DMV_CART_H__ | |
| 10 | #define __DMV_CART_H__ | |
| 11 | ||
| 12 | /*************************************************************************** | |
| 13 | TYPE DEFINITIONS | |
| 14 | ***************************************************************************/ | |
| 15 | ||
| 16 | // ======================> device_dmvslot_interface | |
| 17 | ||
| 18 | class device_dmvslot_interface : public device_slot_card_interface | |
| 19 | { | |
| 20 | public: | |
| 21 | // construction/destruction | |
| 22 | device_dmvslot_interface(const machine_config &mconfig, device_t &device); | |
| 23 | virtual ~device_dmvslot_interface(); | |
| 24 | ||
| 25 | virtual bool read(offs_t offset, UINT8 &data) { return false; } | |
| 26 | virtual bool write(offs_t offset, UINT8 data) { return false; } | |
| 27 | virtual void io_read(address_space &space, int ifsel, offs_t offset, UINT8 &data) { } | |
| 28 | virtual void io_write(address_space &space, int ifsel, offs_t offset, UINT8 data) { } | |
| 29 | ||
| 30 | // slot 1 | |
| 31 | virtual void ram_read(UINT8 cas, offs_t offset, UINT8 &data) { } | |
| 32 | virtual void ram_write(UINT8 cas, offs_t offset, UINT8 data) { } | |
| 33 | ||
| 34 | // slot 7 and 7A | |
| 35 | virtual bool av16bit() { return false; } | |
| 36 | virtual void hold_w(int state) { } | |
| 37 | virtual void irq0_w(int state) { } | |
| 38 | virtual void irq1_w(int state) { } | |
| 39 | virtual void irq2_w(int state) { } | |
| 40 | virtual void irq3_w(int state) { } | |
| 41 | virtual void irq4_w(int state) { } | |
| 42 | virtual void irq5_w(int state) { } | |
| 43 | virtual void irq6_w(int state) { } | |
| 44 | virtual void irq7_w(int state) { } | |
| 45 | }; | |
| 46 | ||
| 47 | ||
| 48 | // ======================> dmvcart_slot_device | |
| 49 | ||
| 50 | class dmvcart_slot_device : public device_t, | |
| 51 | public device_slot_interface | |
| 52 | { | |
| 53 | public: | |
| 54 | // construction/destruction | |
| 55 | dmvcart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock); | |
| 56 | virtual ~dmvcart_slot_device(); | |
| 57 | ||
| 58 | template<class _Object> static devcb_base &set_prog_read_callback(device_t &device, _Object object) { return downcast<dmvcart_slot_device &>(device).m_prog_read_cb.set_callback(object); } | |
| 59 | template<class _Object> static devcb_base &set_prog_write_callback(device_t &device, _Object object) { return downcast<dmvcart_slot_device &>(device).m_prog_write_cb.set_callback(object); } | |
| 60 | template<class _Object> static devcb_base &set_out_irq_callback(device_t &device, _Object object) { return downcast<dmvcart_slot_device &>(device).m_out_irq_cb.set_callback(object); } | |
| 61 | ||
| 62 | // device-level overrides | |
| 63 | virtual void device_start(); | |
| 64 | ||
| 65 | // reading and writing | |
| 66 | virtual bool read(offs_t offset, UINT8 &data); | |
| 67 | virtual bool write(offs_t offset, UINT8 data); | |
| 68 | virtual void ram_read(UINT8 cas, offs_t offset, UINT8 &data); | |
| 69 | virtual void ram_write(UINT8 cas, offs_t offset, UINT8 data); | |
| 70 | virtual void io_read(address_space &space, int ifsel, offs_t offset, UINT8 &data); | |
| 71 | virtual void io_write(address_space &space, int ifsel, offs_t offset, UINT8 data); | |
| 72 | virtual void hold_w(int state); | |
| 73 | virtual void irq0_w(int state); | |
| 74 | virtual void irq1_w(int state); | |
| 75 | virtual void irq2_w(int state); | |
| 76 | virtual void irq3_w(int state); | |
| 77 | virtual void irq4_w(int state); | |
| 78 | virtual void irq5_w(int state); | |
| 79 | virtual void irq6_w(int state); | |
| 80 | virtual void irq7_w(int state); | |
| 81 | virtual bool av16bit(); | |
| 82 | ||
| 83 | // internal state | |
| 84 | devcb_read8 m_prog_read_cb; | |
| 85 | devcb_write8 m_prog_write_cb; | |
| 86 | devcb_write_line m_out_irq_cb; | |
| 87 | device_dmvslot_interface* m_cart; | |
| 88 | }; | |
| 89 | ||
| 90 | ||
| 91 | // device type definition | |
| 92 | extern const device_type DMVCART_SLOT; | |
| 93 | ||
| 94 | ||
| 95 | /*************************************************************************** | |
| 96 | DEVICE CONFIGURATION MACROS | |
| 97 | ***************************************************************************/ | |
| 98 | ||
| 99 | #define MCFG_DMVCART_SLOT_PROGRAM_READWRITE_CB(_read_devcb, _write_devcb) \ | |
| 100 | devcb = &dmvcart_slot_device::set_prog_read_callback(*device, DEVCB_##_read_devcb); \ | |
| 101 | devcb = &dmvcart_slot_device::set_prog_write_callback(*device, DEVCB_##_write_devcb); | |
| 102 | ||
| 103 | #define MCFG_DMVCART_SLOT_OUT_IRQ_CB(_devcb) \ | |
| 104 | devcb = &dmvcart_slot_device::set_out_irq_callback(*device, DEVCB_##_devcb); | |
| 105 | ||
| 106 | #endif /* __DMV_CART_H__ */ |
| Added: svn:mime-type + text/plain Added: svn:eol-style + native |
| r0 | r31661 | |
|---|---|---|
| 1 | // license:BSD-3-Clause | |
| 2 | // copyright-holders:Olivier Galibert | |
| 3 | /********************************************************************* | |
| 4 | ||
| 5 | formats/dmv_dsk.c | |
| 6 | ||
| 7 | NCR Decision Mate V format | |
| 8 | ||
| 9 | *********************************************************************/ | |
| 10 | ||
| 11 | #include "emu.h" | |
| 12 | #include "formats/dmv_dsk.h" | |
| 13 | ||
| 14 | dmv_format::dmv_format() : upd765_format(formats) | |
| 15 | { | |
| 16 | } | |
| 17 | ||
| 18 | const char *dmv_format::name() const | |
| 19 | { | |
| 20 | return "dmv"; | |
| 21 | } | |
| 22 | ||
| 23 | const char *dmv_format::description() const | |
| 24 | { | |
| 25 | return "Decision Mate V disk image"; | |
| 26 | } | |
| 27 | ||
| 28 | const char *dmv_format::extensions() const | |
| 29 | { | |
| 30 | return "img"; | |
| 31 | } | |
| 32 | ||
| 33 | // gap size from hardware reference manual | |
| 34 | const dmv_format::format dmv_format::formats[] = { | |
| 35 | { | |
| 36 | floppy_image::FF_525, floppy_image::DSDD, floppy_image::MFM, | |
| 37 | 2000, | |
| 38 | 9, 40, 2, | |
| 39 | 512, {}, | |
| 40 | 1, {}, | |
| 41 | 80, 50, 22, 80 | |
| 42 | }, | |
| 43 | { | |
| 44 | floppy_image::FF_525, floppy_image::DSDD, floppy_image::MFM, | |
| 45 | 2000, | |
| 46 | 8, 40, 2, | |
| 47 | 512, {}, | |
| 48 | 1, {}, | |
| 49 | 80, 50, 22, 80 | |
| 50 | }, | |
| 51 | {} | |
| 52 | }; | |
| 53 | ||
| 54 | const floppy_format_type FLOPPY_DMV_FORMAT = &floppy_image_format_creator<dmv_format>; |
| Added: svn:mime-type + text/plain Added: svn:eol-style + native |
| r0 | r31661 | |
|---|---|---|
| 1 | // license:BSD-3-Clause | |
| 2 | // copyright-holders:Sandro Ronco | |
| 3 | /*************************************************************************** | |
| 4 | ||
| 5 | K806 Mouse module | |
| 6 | ||
| 7 | ***************************************************************************/ | |
| 8 | ||
| 9 | #include "emu.h" | |
| 10 | #include "k806.h" | |
| 11 | ||
| 12 | ||
| 13 | /*************************************************************************** | |
| 14 | IMPLEMENTATION | |
| 15 | ***************************************************************************/ | |
| 16 | ||
| 17 | ROM_START( dmv_k806 ) | |
| 18 | ROM_REGION( 0x0400, "mcu", 0 ) | |
| 19 | ROM_LOAD( "dmv_mouse_8741a.bin", 0x0000, 0x0400, CRC(2163737a) SHA1(b82c14dba6c25cb1f60cf623989ca8c0c1ee4cc3)) | |
| 20 | ROM_END | |
| 21 | ||
| 22 | static ADDRESS_MAP_START( k806_io, AS_IO, 8, dmv_k806_device ) | |
| 23 | AM_RANGE(MCS48_PORT_P1, MCS48_PORT_P1) AM_READWRITE(port1_r, port1_w) | |
| 24 | AM_RANGE(MCS48_PORT_T1, MCS48_PORT_T1) AM_READ(portt1_r) | |
| 25 | ADDRESS_MAP_END | |
| 26 | ||
| 27 | static MACHINE_CONFIG_FRAGMENT( dmv_k806 ) | |
| 28 | MCFG_CPU_ADD("mcu", I8741, XTAL_6MHz) | |
| 29 | MCFG_CPU_IO_MAP(k806_io) | |
| 30 | MACHINE_CONFIG_END | |
| 31 | ||
| 32 | static INPUT_PORTS_START( dmv_k806 ) | |
| 33 | PORT_START("JUMPERS") | |
| 34 | PORT_DIPNAME( 0x7f, 0x24, "K806 IFSEL" ) PORT_DIPLOCATION("J:!1,J:!2,J:!3,J:!4,J:!5,J:!6,J:!7") | |
| 35 | PORT_DIPSETTING( 0x21, "0A" ) | |
| 36 | PORT_DIPSETTING( 0x41, "0B" ) | |
| 37 | PORT_DIPSETTING( 0x22, "1A" ) | |
| 38 | PORT_DIPSETTING( 0x42, "1B" ) | |
| 39 | PORT_DIPSETTING( 0x24, "2A" ) // default | |
| 40 | PORT_DIPSETTING( 0x44, "2B" ) | |
| 41 | PORT_DIPSETTING( 0x28, "3A" ) | |
| 42 | PORT_DIPSETTING( 0x48, "3B" ) | |
| 43 | PORT_DIPSETTING( 0x30, "4A" ) | |
| 44 | PORT_DIPSETTING( 0x50, "4B" ) | |
| 45 | PORT_DIPNAME( 0x380, 0x00, "K806 Mouse" ) PORT_DIPLOCATION("J:!8,J:!9,J:!10") | |
| 46 | PORT_DIPSETTING( 0x000, "Hawley, Alps" ) | |
| 47 | PORT_DIPSETTING( 0x380, "Depraz" ) | |
| 48 | INPUT_PORTS_END | |
| 49 | ||
| 50 | //************************************************************************** | |
| 51 | // GLOBAL VARIABLES | |
| 52 | //************************************************************************** | |
| 53 | ||
| 54 | const device_type DMV_K806 = &device_creator<dmv_k806_device>; | |
| 55 | ||
| 56 | //************************************************************************** | |
| 57 | // LIVE DEVICE | |
| 58 | //************************************************************************** | |
| 59 | ||
| 60 | //------------------------------------------------- | |
| 61 | // dmv_k806_device - constructor | |
| 62 | //------------------------------------------------- | |
| 63 | ||
| 64 | dmv_k806_device::dmv_k806_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock) | |
| 65 | : device_t(mconfig, DMV_K806, "K806 mouse", tag, owner, clock, "dmv_k806", __FILE__), | |
| 66 | device_dmvslot_interface( mconfig, *this ), | |
| 67 | m_mcu(*this, "mcu"), | |
| 68 | m_jumpers(*this, "JUMPERS") | |
| 69 | { | |
| 70 | } | |
| 71 | ||
| 72 | //------------------------------------------------- | |
| 73 | // device_start - device-specific startup | |
| 74 | //------------------------------------------------- | |
| 75 | ||
| 76 | void dmv_k806_device::device_start() | |
| 77 | { | |
| 78 | } | |
| 79 | ||
| 80 | //------------------------------------------------- | |
| 81 | // device_reset - device-specific reset | |
| 82 | //------------------------------------------------- | |
| 83 | ||
| 84 | void dmv_k806_device::device_reset() | |
| 85 | { | |
| 86 | } | |
| 87 | ||
| 88 | //------------------------------------------------- | |
| 89 | // machine_config_additions - device-specific | |
| 90 | // machine configurations | |
| 91 | //------------------------------------------------- | |
| 92 | ||
| 93 | machine_config_constructor dmv_k806_device::device_mconfig_additions() const | |
| 94 | { | |
| 95 | return MACHINE_CONFIG_NAME( dmv_k806 ); | |
| 96 | } | |
| 97 | ||
| 98 | //------------------------------------------------- | |
| 99 | // input_ports - device-specific input ports | |
| 100 | //------------------------------------------------- | |
| 101 | ||
| 102 | ioport_constructor dmv_k806_device::device_input_ports() const | |
| 103 | { | |
| 104 | return INPUT_PORTS_NAME( dmv_k806 ); | |
| 105 | } | |
| 106 | ||
| 107 | //------------------------------------------------- | |
| 108 | // device_rom_region | |
| 109 | //------------------------------------------------- | |
| 110 | ||
| 111 | const rom_entry *dmv_k806_device::device_rom_region() const | |
| 112 | { | |
| 113 | return ROM_NAME( dmv_k806 ); | |
| 114 | } | |
| 115 | ||
| 116 | void dmv_k806_device::io_read(address_space &space, int ifsel, offs_t offset, UINT8 &data) | |
| 117 | { | |
| 118 | UINT8 jumpers = m_jumpers->read(); | |
| 119 | if (BIT(jumpers, ifsel) && ((!BIT(offset, 3) && BIT(jumpers, 5)) || (BIT(offset, 3) && BIT(jumpers, 6)))) | |
| 120 | data = m_mcu->upi41_master_r(space, offset & 1); | |
| 121 | } | |
| 122 | ||
| 123 | void dmv_k806_device::io_write(address_space &space, int ifsel, offs_t offset, UINT8 data) | |
| 124 | { | |
| 125 | UINT8 jumpers = m_jumpers->read(); | |
| 126 | if (BIT(jumpers, ifsel) && ((!BIT(offset, 3) && BIT(jumpers, 5)) || (BIT(offset, 3) && BIT(jumpers, 6)))) | |
| 127 | m_mcu->upi41_master_w(space, offset & 1, data); | |
| 128 | } | |
| 129 | ||
| 130 | READ8_MEMBER( dmv_k806_device::port1_r ) | |
| 131 | { | |
| 132 | // TODO | |
| 133 | return 0xff; | |
| 134 | } | |
| 135 | ||
| 136 | READ8_MEMBER( dmv_k806_device::portt1_r ) | |
| 137 | { | |
| 138 | return BIT(m_jumpers->read(), 7) ? 0 : 1; | |
| 139 | } | |
| 140 | ||
| 141 | WRITE8_MEMBER( dmv_k806_device::port1_w ) | |
| 142 | { | |
| 143 | // TODO | |
| 144 | }; |
| Added: svn:mime-type + text/plain Added: svn:eol-style + native |
| r31660 | r31661 | |
|---|---|---|
| 233 | 233 | |
| 234 | 234 | #------------------------------------------------- |
| 235 | 235 | # |
| 236 | #@src/emu/bus/dmv/dmv.h,BUSES += DMV | |
| 237 | #------------------------------------------------- | |
| 238 | ||
| 239 | ifneq ($(filter DMV,$(BUSES)),) | |
| 240 | OBJDIRS += $(BUSOBJ)/dmv | |
| 241 | BUSOBJS += $(BUSOBJ)/dmv/dmvbus.o | |
| 242 | BUSOBJS += $(BUSOBJ)/dmv/k220.o | |
| 243 | BUSOBJS += $(BUSOBJ)/dmv/k230.o | |
| 244 | BUSOBJS += $(BUSOBJ)/dmv/k806.o | |
| 245 | BUSOBJS += $(BUSOBJ)/dmv/ram.o | |
| 246 | endif | |
| 247 | ||
| 248 | ||
| 249 | #------------------------------------------------- | |
| 250 | # | |
| 236 | 251 | #@src/emu/bus/ecbbus/ecbbus.h,BUSES += ECBBUS |
| 237 | 252 | #------------------------------------------------- |
| 238 | 253 |
| r0 | r31661 | |
|---|---|---|
| 1 | // license:BSD-3-Clause | |
| 2 | // copyright-holders:Olivier Galibert | |
| 3 | /********************************************************************* | |
| 4 | ||
| 5 | formats/dmv_dsk.c | |
| 6 | ||
| 7 | NCR Decision Mate V format | |
| 8 | ||
| 9 | *********************************************************************/ | |
| 10 | ||
| 11 | #include "emu.h" | |
| 12 | #include "formats/dmv_dsk.h" | |
| 13 | ||
| 14 | dmv_format::dmv_format() : upd765_format(formats) | |
| 15 | { | |
| 16 | } | |
| 17 | ||
| 18 | const char *dmv_format::name() const | |
| 19 | { | |
| 20 | return "dmv"; | |
| 21 | } | |
| 22 | ||
| 23 | const char *dmv_format::description() const | |
| 24 | { | |
| 25 | return "Decision Mate V disk image"; | |
| 26 | } | |
| 27 | ||
| 28 | const char *dmv_format::extensions() const | |
| 29 | { | |
| 30 | return "img"; | |
| 31 | } | |
| 32 | ||
| 33 | // gap size from hardware reference manual | |
| 34 | const dmv_format::format dmv_format::formats[] = { | |
| 35 | { | |
| 36 | floppy_image::FF_525, floppy_image::DSDD, floppy_image::MFM, | |
| 37 | 2000, | |
| 38 | 9, 40, 2, | |
| 39 | 512, {}, | |
| 40 | 1, {}, | |
| 41 | 80, 50, 22, 80 | |
| 42 | }, | |
| 43 | { | |
| 44 | floppy_image::FF_525, floppy_image::DSDD, floppy_image::MFM, | |
| 45 | 2000, | |
| 46 | 8, 40, 2, | |
| 47 | 512, {}, | |
| 48 | 1, {}, | |
| 49 | 80, 50, 22, 80 | |
| 50 | }, | |
| 51 | {} | |
| 52 | }; | |
| 53 | ||
| 54 | const floppy_format_type FLOPPY_DMV_FORMAT = &floppy_image_format_creator<dmv_format>; |
| Added: svn:mime-type + text/plain Added: svn:eol-style + native |
| r0 | r31661 | |
|---|---|---|
| 1 | /********************************************************************* | |
| 2 | ||
| 3 | formats/dmv_dsk.h | |
| 4 | ||
| 5 | NCR Decision Mate V format | |
| 6 | ||
| 7 | *********************************************************************/ | |
| 8 | ||
| 9 | #ifndef DMV_DSK_H_ | |
| 10 | #define DMV_DSK_H_ | |
| 11 | ||
| 12 | #include "upd765_dsk.h" | |
| 13 | ||
| 14 | class dmv_format : public upd765_format { | |
| 15 | public: | |
| 16 | dmv_format(); | |
| 17 | ||
| 18 | virtual const char *name() const; | |
| 19 | virtual const char *description() const; | |
| 20 | virtual const char *extensions() const; | |
| 21 | ||
| 22 | private: | |
| 23 | static const format formats[]; | |
| 24 | }; | |
| 25 | ||
| 26 | extern const floppy_format_type FLOPPY_DMV_FORMAT; | |
| 27 | ||
| 28 | #endif /* DMV_DSK_H_ */ |
| Added: svn:mime-type + text/plain Added: svn:eol-style + native |
| r31660 | r31661 | |
|---|---|---|
| 139 | 139 | $(LIBOBJ)/formats/d88_dsk.o \ |
| 140 | 140 | $(LIBOBJ)/formats/dfi_dsk.o \ |
| 141 | 141 | $(LIBOBJ)/formats/dim_dsk.o \ |
| 142 | $(LIBOBJ)/formats/dmv_dsk.o \ | |
| 142 | 143 | $(LIBOBJ)/formats/dsk_dsk.o \ |
| 143 | 144 | $(LIBOBJ)/formats/ep64_dsk.o \ |
| 144 | 145 | $(LIBOBJ)/formats/esq8_dsk.o \ |
| r31660 | r31661 | |
|---|---|---|
| 1 | <?xml version="1.0"?> | |
| 1 | 2 | <mamelayout version="2"> |
| 2 | 3 | <element name="led" defstate="0"> |
| 3 | 4 | <disk state="0"> |
| r31660 | r31661 | |
| 48 | 49 | <color red="1.0" green="1.0" blue="1.0" /> |
| 49 | 50 | </text> |
| 50 | 51 | </element> |
| 52 | <element name="digit" defstate="0"> | |
| 53 | <led7seg> | |
| 54 | <color red="0.75" green="0.0" blue="0.0" /> | |
| 55 | </led7seg> | |
| 56 | </element> | |
| 51 | 57 | |
| 52 | 58 | |
| 53 | 59 | <view name="Default Layout"> |
| r31660 | r31661 | |
| 106 | 112 | </bezel> |
| 107 | 113 | </view> |
| 108 | 114 | |
| 115 | <view name="Diagnostic module"> | |
| 116 | <screen index="0"> | |
| 117 | <bounds x="30" y="0" width="640" height="480" /> | |
| 118 | </screen> | |
| 119 | ||
| 120 | <bezel name="led1" element="led"> | |
| 121 | <bounds x="15" y="33" width="10" height="10" /> | |
| 122 | </bezel> | |
| 123 | <bezel name="led2" element="led"> | |
| 124 | <bounds x="15" y="53" width="10" height="10" /> | |
| 125 | </bezel> | |
| 126 | <bezel name="led3" element="led"> | |
| 127 | <bounds x="15" y="73" width="10" height="10" /> | |
| 128 | </bezel> | |
| 129 | <bezel name="led4" element="led"> | |
| 130 | <bounds x="15" y="93" width="10" height="10" /> | |
| 131 | </bezel> | |
| 132 | <bezel name="led5" element="led"> | |
| 133 | <bounds x="15" y="113" width="10" height="10" /> | |
| 134 | </bezel> | |
| 135 | <bezel name="led6" element="led"> | |
| 136 | <bounds x="15" y="133" width="10" height="10" /> | |
| 137 | </bezel> | |
| 138 | <bezel name="led7" element="led"> | |
| 139 | <bounds x="15" y="153" width="10" height="10" /> | |
| 140 | </bezel> | |
| 141 | <bezel name="led8" element="led"> | |
| 142 | <bounds x="15" y="173" width="10" height="10" /> | |
| 143 | </bezel> | |
| 144 | ||
| 145 | <bezel name="label1" element="l1"> | |
| 146 | <bounds x="0" y="30" width="15" height="16" /> | |
| 147 | </bezel> | |
| 148 | <bezel name="label2" element="l2"> | |
| 149 | <bounds x="0" y="50" width="15" height="16" /> | |
| 150 | </bezel> | |
| 151 | <bezel name="label3" element="l3"> | |
| 152 | <bounds x="0" y="70" width="15" height="16" /> | |
| 153 | </bezel> | |
| 154 | <bezel name="label4" element="l4"> | |
| 155 | <bounds x="0" y="90" width="15" height="16" /> | |
| 156 | </bezel> | |
| 157 | <bezel name="label5" element="l5"> | |
| 158 | <bounds x="0" y="110" width="15" height="16" /> | |
| 159 | </bezel> | |
| 160 | <bezel name="label6" element="l6"> | |
| 161 | <bounds x="0" y="130" width="15" height="16" /> | |
| 162 | </bezel> | |
| 163 | <bezel name="label7" element="l7"> | |
| 164 | <bounds x="0" y="150" width="15" height="16" /> | |
| 165 | </bezel> | |
| 166 | <bezel name="label8" element="l8"> | |
| 167 | <bounds x="0" y="170" width="15" height="16" /> | |
| 168 | </bezel> | |
| 169 | ||
| 170 | <bezel name="digit0" element="digit"> | |
| 171 | <bounds x="5" y="200" width="20" height="30" /> | |
| 172 | </bezel> | |
| 173 | <bezel name="digit1" element="digit"> | |
| 174 | <bounds x="5" y="240" width="20" height="30" /> | |
| 175 | </bezel> | |
| 176 | </view> | |
| 177 | ||
| 109 | 178 | <view name="Screen Only"> |
| 110 | 179 | <screen index="0"> |
| 111 | 180 | <bounds x="0" y="0" width="640" height="480" /> |
| r31660 | r31661 | |
|---|---|---|
| 18 | 18 | #include "machine/dmv_keyb.h" |
| 19 | 19 | #include "sound/speaker.h" |
| 20 | 20 | #include "video/upd7220.h" |
| 21 | #include "formats/dmv_dsk.h" | |
| 22 | ||
| 23 | // expansion slots | |
| 24 | #include "bus/dmv/dmvbus.h" | |
| 25 | #include "bus/dmv/k220.h" | |
| 26 | #include "bus/dmv/k230.h" | |
| 27 | #include "bus/dmv/k806.h" | |
| 28 | #include "bus/dmv/ram.h" | |
| 29 | ||
| 30 | ||
| 21 | 31 | #include "dmv.lh" |
| 22 | 32 | |
| 23 | 33 | class dmv_state : public driver_device |
| r31660 | r31661 | |
| 35 | 45 | m_keyboard(*this, "keyboard"), |
| 36 | 46 | m_speaker(*this, "speaker"), |
| 37 | 47 | m_video_ram(*this, "video_ram"), |
| 38 | m_palette(*this, "palette") | |
| 48 | m_palette(*this, "palette"), | |
| 49 | m_ram(*this, "ram"), | |
| 50 | m_bootrom(*this, "boot"), | |
| 51 | m_chargen(*this, "chargen"), | |
| 52 | m_slot1(*this, "slot1"), | |
| 53 | m_slot2(*this, "slot2"), | |
| 54 | m_slot2a(*this, "slot2a"), | |
| 55 | m_slot3(*this, "slot3"), | |
| 56 | m_slot4(*this, "slot4"), | |
| 57 | m_slot5(*this, "slot5"), | |
| 58 | m_slot6(*this, "slot6"), | |
| 59 | m_slot7(*this, "slot7"), | |
| 60 | m_slot7a(*this, "slot7a") | |
| 39 | 61 | { } |
| 40 | 62 | |
| 41 | 63 | required_device<cpu_device> m_maincpu; |
| r31660 | r31661 | |
| 47 | 69 | required_device<floppy_connector> m_floppy1; |
| 48 | 70 | required_device<dmv_keyboard_device> m_keyboard; |
| 49 | 71 | required_device<speaker_sound_device> m_speaker; |
| 72 | required_shared_ptr<UINT8> m_video_ram; | |
| 73 | required_device<palette_device> m_palette; | |
| 74 | required_memory_region m_ram; | |
| 75 | required_memory_region m_bootrom; | |
| 76 | required_memory_region m_chargen; | |
| 50 | 77 | |
| 51 | virtual void video_start(); | |
| 78 | required_device<dmvcart_slot_device> m_slot1; | |
| 79 | required_device<dmvcart_slot_device> m_slot2; | |
| 80 | required_device<dmvcart_slot_device> m_slot2a; | |
| 81 | required_device<dmvcart_slot_device> m_slot3; | |
| 82 | required_device<dmvcart_slot_device> m_slot4; | |
| 83 | required_device<dmvcart_slot_device> m_slot5; | |
| 84 | required_device<dmvcart_slot_device> m_slot6; | |
| 85 | required_device<dmvcart_slot_device> m_slot7; | |
| 86 | required_device<dmvcart_slot_device> m_slot7a; | |
| 87 | ||
| 52 | 88 | virtual void machine_start(); |
| 53 | 89 | virtual void machine_reset(); |
| 90 | void update_halt_line(); | |
| 54 | 91 | |
| 55 | 92 | DECLARE_WRITE8_MEMBER(leds_w); |
| 56 | 93 | DECLARE_WRITE_LINE_MEMBER(dma_hrq_changed); |
| r31660 | r31661 | |
| 58 | 95 | DECLARE_WRITE_LINE_MEMBER(dmac_dack3); |
| 59 | 96 | DECLARE_WRITE_LINE_MEMBER(fdc_irq); |
| 60 | 97 | DECLARE_WRITE_LINE_MEMBER(pit_out0); |
| 98 | DECLARE_WRITE_LINE_MEMBER(timint_w); | |
| 61 | 99 | DECLARE_WRITE8_MEMBER(fdd_motor_w); |
| 62 | 100 | DECLARE_READ8_MEMBER(sys_status_r); |
| 63 | 101 | DECLARE_WRITE8_MEMBER(tc_set_w); |
| 64 | DECLARE_READ8_MEMBER(memory_read_byte); | |
| 65 | DECLARE_WRITE8_MEMBER(memory_write_byte); | |
| 102 | DECLARE_WRITE8_MEMBER(switch16_w); | |
| 66 | 103 | DECLARE_WRITE8_MEMBER(ramsel_w); |
| 67 | 104 | DECLARE_WRITE8_MEMBER(romsel_w); |
| 68 | 105 | DECLARE_READ8_MEMBER(kb_mcu_port1_r); |
| 69 | 106 | DECLARE_WRITE8_MEMBER(kb_mcu_port1_w); |
| 70 | 107 | DECLARE_WRITE8_MEMBER(kb_mcu_port2_w); |
| 108 | DECLARE_WRITE8_MEMBER(rambank_w); | |
| 109 | DECLARE_READ8_MEMBER(program_r); | |
| 110 | DECLARE_WRITE8_MEMBER(program_w); | |
| 111 | DECLARE_FLOPPY_FORMATS( floppy_formats ); | |
| 71 | 112 | |
| 72 | required_shared_ptr<UINT8> m_video_ram; | |
| 73 | required_device<palette_device> m_palette; | |
| 113 | void ifsel_r(address_space &space, int ifsel, offs_t offset, UINT8 &data); | |
| 114 | void ifsel_w(address_space &space, int ifsel, offs_t offset, UINT8 data); | |
| 115 | DECLARE_READ8_MEMBER(ifsel0_r) { UINT8 data = 0xff; ifsel_r(space, 0, offset, data); return data; } | |
| 116 | DECLARE_READ8_MEMBER(ifsel1_r) { UINT8 data = 0xff; ifsel_r(space, 1, offset, data); return data; } | |
| 117 | DECLARE_READ8_MEMBER(ifsel2_r) { UINT8 data = 0xff; ifsel_r(space, 2, offset, data); return data; } | |
| 118 | DECLARE_READ8_MEMBER(ifsel3_r) { UINT8 data = 0xff; ifsel_r(space, 3, offset, data); return data; } | |
| 119 | DECLARE_READ8_MEMBER(ifsel4_r) { UINT8 data = 0xff; ifsel_r(space, 4, offset, data); return data; } | |
| 120 | DECLARE_WRITE8_MEMBER(ifsel0_w) { ifsel_w(space, 0, offset, data); } | |
| 121 | DECLARE_WRITE8_MEMBER(ifsel1_w) { ifsel_w(space, 1, offset, data); } | |
| 122 | DECLARE_WRITE8_MEMBER(ifsel2_w) { ifsel_w(space, 2, offset, data); } | |
| 123 | DECLARE_WRITE8_MEMBER(ifsel3_w) { ifsel_w(space, 3, offset, data); } | |
| 124 | DECLARE_WRITE8_MEMBER(ifsel4_w) { ifsel_w(space, 4, offset, data); } | |
| 74 | 125 | |
| 75 | 126 | UPD7220_DISPLAY_PIXELS_MEMBER( hgdc_display_pixels ); |
| 76 | 127 | UPD7220_DRAW_TEXT_LINE_MEMBER( hgdc_draw_text ); |
| 77 | 128 | |
| 129 | bool m_ramoutdis; | |
| 130 | int m_switch16; | |
| 131 | int m_dma_hrq; | |
| 132 | int m_ram_bank; | |
| 133 | bool m_color_mode; | |
| 78 | 134 | int m_eop_line; |
| 79 | 135 | int m_dack3_line; |
| 80 | 136 | int m_sd_poll_state; |
| 81 | 137 | int m_floppy_motor; |
| 82 | UINT8 m_ram[0x2000]; | |
| 83 | 138 | }; |
| 84 | 139 | |
| 85 | 140 | WRITE8_MEMBER(dmv_state::tc_set_w) |
| r31660 | r31661 | |
| 87 | 142 | m_fdc->tc_w(true); |
| 88 | 143 | } |
| 89 | 144 | |
| 145 | WRITE8_MEMBER(dmv_state::switch16_w) | |
| 146 | { | |
| 147 | m_switch16 = !m_switch16; | |
| 148 | update_halt_line(); | |
| 149 | } | |
| 150 | ||
| 90 | 151 | WRITE8_MEMBER(dmv_state::leds_w) |
| 91 | 152 | { |
| 92 | 153 | /* |
| r31660 | r31661 | |
| 109 | 170 | |
| 110 | 171 | WRITE8_MEMBER(dmv_state::ramsel_w) |
| 111 | 172 | { |
| 112 | m_ | |
| 173 | m_ramoutdis = false; | |
| 113 | 174 | } |
| 114 | 175 | |
| 115 | 176 | WRITE8_MEMBER(dmv_state::romsel_w) |
| 116 | 177 | { |
| 117 | m_ | |
| 178 | m_ramoutdis = true; | |
| 118 | 179 | } |
| 119 | 180 | |
| 181 | WRITE8_MEMBER(dmv_state::rambank_w) | |
| 182 | { | |
| 183 | m_ram_bank = offset; | |
| 184 | } | |
| 185 | ||
| 120 | 186 | WRITE8_MEMBER(dmv_state::fdd_motor_w) |
| 121 | 187 | { |
| 122 | 188 | m_pit->write_gate0(1); |
| r31660 | r31661 | |
| 145 | 211 | if (m_floppy_motor) |
| 146 | 212 | data |= 0x01; |
| 147 | 213 | |
| 148 | // 16-bit CPU not available | |
| 149 | data |= 0x02; | |
| 214 | // 16-bit CPU | |
| 215 | if (!(m_slot7->av16bit() || m_slot7a->av16bit())) | |
| 216 | data |= 0x02; | |
| 150 | 217 | |
| 151 | 218 | if (!m_floppy0->get_device()->ready_r()) |
| 152 | 219 | data |= 0x04; |
| r31660 | r31661 | |
| 159 | 226 | |
| 160 | 227 | UPD7220_DISPLAY_PIXELS_MEMBER( dmv_state::hgdc_display_pixels ) |
| 161 | 228 | { |
| 162 | //TODO | |
| 229 | if (m_color_mode) | |
| 230 | { | |
| 231 | // 96KB videoram (32KB green + 32KB red + 32KB blue) | |
| 232 | UINT8 green = m_video_ram[0x00000 + (address & 0x7fff)]; | |
| 233 | UINT8 red = m_video_ram[0x08000 + (address & 0x7fff)]; | |
| 234 | UINT8 blue = m_video_ram[0x10000 + (address & 0x7fff)]; | |
| 235 | ||
| 236 | for(int xi=0; xi<8; xi++) | |
| 237 | { | |
| 238 | int r = ((red >> (7-xi)) & 1) ? 255 : 0; | |
| 239 | int g = ((green >> (7-xi)) & 1) ? 255 : 0; | |
| 240 | int b = ((blue >> (7-xi)) & 1) ? 255 : 0; | |
| 241 | ||
| 242 | if (bitmap.cliprect().contains(x + xi, y)) | |
| 243 | bitmap.pix32(y, x + xi) = rgb_t(r, g, b); | |
| 244 | } | |
| 245 | } | |
| 246 | else | |
| 247 | { | |
| 248 | const rgb_t *palette = m_palette->palette()->entry_list_raw(); | |
| 249 | ||
| 250 | // 32KB videoram | |
| 251 | UINT8 gfx = m_video_ram[address & 0x7fff]; | |
| 252 | ||
| 253 | for(int xi=0;xi<8;xi++) | |
| 254 | { | |
| 255 | if (bitmap.cliprect().contains(x + xi, y)) | |
| 256 | bitmap.pix32(y, x + xi) = ((gfx >> (7-xi)) & 1) ? palette[1] : palette[0]; | |
| 257 | } | |
| 258 | } | |
| 163 | 259 | } |
| 164 | 260 | |
| 165 | 261 | UPD7220_DRAW_TEXT_LINE_MEMBER( dmv_state::hgdc_draw_text ) |
| 166 | 262 | { |
| 167 | const rgb_t *palette = m_palette->palette()->entry_list_raw(); | |
| 168 | UINT8 * chargen = memregion("maincpu")->base() + 0x1000; | |
| 169 | ||
| 170 | 263 | for( int x = 0; x < pitch; x++ ) |
| 171 | 264 | { |
| 172 | 265 | UINT8 tile = m_video_ram[((addr+x)*2) & 0x1ffff] & 0xff; |
| 266 | UINT8 attr = m_video_ram[((addr+x)*2 + 1) & 0x1ffff] & 0xff; | |
| 173 | 267 | |
| 268 | rgb_t bg, fg; | |
| 269 | if (m_color_mode) | |
| 270 | { | |
| 271 | bg = rgb_t(attr & 0x20 ? 0 : 255, attr & 0x40 ? 0 : 255, attr & 0x80 ? 0 : 255); | |
| 272 | fg = rgb_t(attr & 0x04 ? 255 : 0, attr & 0x08 ? 255 : 0, attr & 0x10 ? 255 : 0); | |
| 273 | } | |
| 274 | else | |
| 275 | { | |
| 276 | const rgb_t *palette = m_palette->palette()->entry_list_raw(); | |
| 277 | bg = palette[(attr & 1) ? 1 : 0]; | |
| 278 | fg = palette[(attr & 1) ? 0 : 1]; | |
| 279 | } | |
| 280 | ||
| 174 | 281 | for( int yi = 0; yi < lr; yi++) |
| 175 | 282 | { |
| 176 | UINT8 tile_data = chargen[(tile*16+yi) & 0x7ff]; | |
| 283 | UINT8 tile_data = m_chargen->base()[(tile*16+yi) & 0x7ff]; | |
| 177 | 284 | |
| 178 | 285 | if(cursor_on && cursor_addr == addr+x) //TODO |
| 179 | 286 | tile_data^=0xff; |
| r31660 | r31661 | |
| 191 | 298 | |
| 192 | 299 | if(yi >= 16) { pen = 0; } |
| 193 | 300 | |
| 194 | bitmap.pix32(res_y, res_x) = p | |
| 301 | bitmap.pix32(res_y, res_x) = pen ? fg : bg; | |
| 195 | 302 | } |
| 196 | 303 | } |
| 197 | 304 | } |
| r31660 | r31661 | |
| 201 | 308 | SLOT_INTERFACE( "525dd", FLOPPY_525_DD ) |
| 202 | 309 | SLOT_INTERFACE_END |
| 203 | 310 | |
| 311 | ||
| 312 | void dmv_state::ifsel_r(address_space &space, int ifsel, offs_t offset, UINT8 &data) | |
| 313 | { | |
| 314 | dmvcart_slot_device *slots[] = { m_slot2, m_slot2a, m_slot3, m_slot4, m_slot5, m_slot6, m_slot7, m_slot7a }; | |
| 315 | for(int i=0; i<8; i++) | |
| 316 | slots[i]->io_read(space, ifsel, offset, data); | |
| 317 | } | |
| 318 | ||
| 319 | void dmv_state::ifsel_w(address_space &space, int ifsel, offs_t offset, UINT8 data) | |
| 320 | { | |
| 321 | dmvcart_slot_device *slots[] = { m_slot2, m_slot2a, m_slot3, m_slot4, m_slot5, m_slot6, m_slot7, m_slot7a }; | |
| 322 | for(int i=0; i<8; i++) | |
| 323 | slots[i]->io_write(space, ifsel, offset, data); | |
| 324 | } | |
| 325 | ||
| 326 | WRITE8_MEMBER(dmv_state::program_w) | |
| 327 | { | |
| 328 | bool tramd = false; | |
| 329 | dmvcart_slot_device *slots[] = { m_slot2, m_slot2a, m_slot3, m_slot4, m_slot5, m_slot6, m_slot7, m_slot7a }; | |
| 330 | for(int i=0; i<8 && !tramd; i++) | |
| 331 | tramd = slots[i]->write(offset, data); | |
| 332 | ||
| 333 | if (!tramd) | |
| 334 | { | |
| 335 | int cas = (m_switch16 ? offset >> 16 : m_ram_bank) & 0x07; | |
| 336 | ||
| 337 | if (cas == 0) | |
| 338 | m_ram->base()[offset & 0xffff] = data; | |
| 339 | else | |
| 340 | m_slot1->ram_write(cas, offset & 0xffff, data); | |
| 341 | } | |
| 342 | } | |
| 343 | ||
| 344 | READ8_MEMBER(dmv_state::program_r) | |
| 345 | { | |
| 346 | UINT8 data = 0xff; | |
| 347 | if (m_ramoutdis && offset < 0x2000) | |
| 348 | { | |
| 349 | data = m_bootrom->base()[offset]; | |
| 350 | } | |
| 351 | else | |
| 352 | { | |
| 353 | bool tramd = false; | |
| 354 | dmvcart_slot_device *slots[] = { m_slot2, m_slot2a, m_slot3, m_slot4, m_slot5, m_slot6, m_slot7, m_slot7a }; | |
| 355 | for(int i=0; i<8 && !tramd; i++) | |
| 356 | tramd = slots[i]->read(offset, data); | |
| 357 | ||
| 358 | if (!tramd) | |
| 359 | { | |
| 360 | int cas = (m_switch16 ? offset >> 16 : m_ram_bank) & 0x07; | |
| 361 | ||
| 362 | if (cas == 0) | |
| 363 | data = m_ram->base()[offset & 0xffff]; | |
| 364 | else | |
| 365 | m_slot1->ram_read(cas, offset & 0xffff, data); | |
| 366 | } | |
| 367 | } | |
| 368 | ||
| 369 | return data; | |
| 370 | } | |
| 371 | ||
| 204 | 372 | static ADDRESS_MAP_START(dmv_mem, AS_PROGRAM, 8, dmv_state) |
| 205 | 373 | ADDRESS_MAP_UNMAP_HIGH |
| 206 | AM_RANGE( 0x0000, 0x1fff ) AM_ROM | |
| 207 | AM_RANGE( 0x2000, 0xffff ) AM_RAM | |
| 374 | AM_RANGE( 0x0000, 0xffff ) AM_READWRITE(program_r, program_w) | |
| 208 | 375 | ADDRESS_MAP_END |
| 209 | 376 | |
| 210 | 377 | static ADDRESS_MAP_START( dmv_io , AS_IO, 8, dmv_state) |
| r31660 | r31661 | |
| 221 | 388 | AM_RANGE(0x50, 0x51) AM_DEVICE("i8272", i8272a_device, map) |
| 222 | 389 | AM_RANGE(0x80, 0x83) AM_DEVREADWRITE("pit8253", pit8253_device, read, write) |
| 223 | 390 | AM_RANGE(0xa0, 0xa1) AM_DEVREADWRITE("upd7220", upd7220_device, read, write) |
| 391 | AM_RANGE(0xd0, 0xd7) AM_WRITE(switch16_w) | |
| 392 | AM_RANGE(0xe0, 0xe7) AM_WRITE(rambank_w) | |
| 224 | 393 | |
| 225 | //AM_RANGE(0xe0, 0xe7) RAM bankswitch | |
| 394 | AM_RANGE(0x60, 0x6f) AM_READWRITE(ifsel0_r, ifsel0_w) | |
| 395 | AM_RANGE(0x70, 0x7f) AM_READWRITE(ifsel1_r, ifsel1_w) | |
| 396 | AM_RANGE(0x30, 0x3f) AM_READWRITE(ifsel2_r, ifsel2_w) | |
| 397 | AM_RANGE(0xb0, 0xbf) AM_READWRITE(ifsel3_r, ifsel3_w) | |
| 398 | AM_RANGE(0xc0, 0xcf) AM_READWRITE(ifsel4_r, ifsel4_w) | |
| 226 | 399 | ADDRESS_MAP_END |
| 227 | 400 | |
| 228 | 401 | READ8_MEMBER(dmv_state::kb_mcu_port1_r) |
| r31660 | r31661 | |
| 239 | 412 | WRITE8_MEMBER(dmv_state::kb_mcu_port2_w) |
| 240 | 413 | { |
| 241 | 414 | m_speaker->level_w(BIT(data, 0)); |
| 415 | m_slot7a->irq1_w(BIT(data, 4)); | |
| 416 | m_slot7->irq1_w(BIT(data, 4)); | |
| 242 | 417 | } |
| 243 | 418 | |
| 244 | 419 | static ADDRESS_MAP_START( dmv_kb_ctrl_io, AS_IO, 8, dmv_state ) |
| r31660 | r31661 | |
| 253 | 428 | |
| 254 | 429 | /* Input ports */ |
| 255 | 430 | INPUT_PORTS_START( dmv ) |
| 431 | PORT_START("CONFIG") | |
| 432 | PORT_CONFNAME( 0x01, 0x00, "Video Board" ) | |
| 433 | PORT_CONFSETTING( 0x00, "Monochrome" ) | |
| 434 | PORT_CONFSETTING( 0x01, "Color" ) | |
| 256 | 435 | INPUT_PORTS_END |
| 257 | 436 | |
| 258 | 437 | void dmv_state::machine_start() |
| r31660 | r31661 | |
| 261 | 440 | |
| 262 | 441 | void dmv_state::machine_reset() |
| 263 | 442 | { |
| 443 | m_color_mode = ioport("CONFIG")->read() & 0x01; | |
| 444 | ||
| 445 | m_ramoutdis = true; | |
| 446 | m_ram_bank = 0; | |
| 264 | 447 | m_eop_line = 0; |
| 265 | 448 | m_dack3_line = 0; |
| 266 | 449 | m_sd_poll_state = 0; |
| 267 | 450 | m_floppy_motor = 1; |
| 268 | m_maincpu->space(AS_PROGRAM).install_rom(0x0000, 0x1fff, memregion("maincpu")->base()); | |
| 451 | m_switch16 = 0; | |
| 452 | m_dma_hrq = 0; | |
| 453 | ||
| 454 | update_halt_line(); | |
| 269 | 455 | } |
| 270 | 456 | |
| 271 | void dmv_state:: | |
| 457 | void dmv_state::update_halt_line() | |
| 272 | 458 | { |
| 459 | m_slot7->hold_w(!m_switch16 || m_dma_hrq ? ASSERT_LINE : CLEAR_LINE); | |
| 460 | m_slot7a->hold_w(!m_switch16 || m_dma_hrq ? ASSERT_LINE : CLEAR_LINE); | |
| 461 | m_maincpu->set_input_line(INPUT_LINE_HALT, m_switch16 || m_dma_hrq ? ASSERT_LINE : CLEAR_LINE); | |
| 273 | 462 | } |
| 274 | 463 | |
| 275 | 464 | /* F4 Character Displayer */ |
| r31660 | r31661 | |
| 287 | 476 | }; |
| 288 | 477 | |
| 289 | 478 | static GFXDECODE_START( dmv ) |
| 290 | GFXDECODE_ENTRY(" | |
| 479 | GFXDECODE_ENTRY("chargen", 0x0000, dmv_charlayout, 0, 1) | |
| 291 | 480 | GFXDECODE_END |
| 292 | 481 | |
| 293 | 482 | |
| r31660 | r31661 | |
| 297 | 486 | |
| 298 | 487 | WRITE_LINE_MEMBER( dmv_state::dma_hrq_changed ) |
| 299 | 488 | { |
| 300 | m_maincpu->set_input_line(INPUT_LINE_HALT, state ? ASSERT_LINE : CLEAR_LINE); | |
| 489 | m_dma_hrq = state; | |
| 490 | update_halt_line(); | |
| 301 | 491 | |
| 302 | 492 | // Assert HLDA |
| 303 | 493 | m_dmac->hack_w(state); |
| r31660 | r31661 | |
| 329 | 519 | } |
| 330 | 520 | } |
| 331 | 521 | |
| 522 | WRITE_LINE_MEMBER( dmv_state::timint_w ) | |
| 523 | { | |
| 524 | m_slot7a->irq0_w(state); | |
| 525 | m_slot7->irq0_w(state); | |
| 526 | } | |
| 527 | ||
| 332 | 528 | WRITE_LINE_MEMBER( dmv_state::fdc_irq ) |
| 333 | 529 | { |
| 530 | m_slot7a->irq6_w(state); | |
| 531 | m_slot7->irq6_w(state); | |
| 532 | ||
| 334 | 533 | if (state) |
| 335 | 534 | m_fdc->tc_w(false); |
| 336 | 535 | } |
| 337 | 536 | |
| 338 | READ8_MEMBER(dmv_state::memory_read_byte) | |
| 339 | { | |
| 340 | address_space& prog_space = m_maincpu->space(AS_PROGRAM); | |
| 341 | return prog_space.read_byte(offset); | |
| 342 | } | |
| 343 | 537 | |
| 344 | WRITE8_MEMBER(dmv_state::memory_write_byte) | |
| 345 | { | |
| 346 | address_space& prog_space = m_maincpu->space(AS_PROGRAM); | |
| 347 | prog_space.write_byte(offset, data); | |
| 348 | } | |
| 538 | FLOPPY_FORMATS_MEMBER( dmv_state::floppy_formats ) | |
| 539 | FLOPPY_DMV_FORMAT | |
| 540 | FLOPPY_FORMATS_END | |
| 349 | 541 | |
| 350 | 542 | |
| 543 | static SLOT_INTERFACE_START(dmv_slot1) | |
| 544 | SLOT_INTERFACE("k200", DMV_K200) // K200 64K RAM expansion | |
| 545 | SLOT_INTERFACE("k202", DMV_K202) // K202 192K RAM expansion | |
| 546 | SLOT_INTERFACE("k208", DMV_K208) // K208 448K RAM expansion | |
| 547 | SLOT_INTERFACE_END | |
| 548 | ||
| 549 | static SLOT_INTERFACE_START(dmv_slot2_6) | |
| 550 | SLOT_INTERFACE("k806", DMV_K806) // K806 Mouse module | |
| 551 | SLOT_INTERFACE_END | |
| 552 | ||
| 553 | static SLOT_INTERFACE_START(dmv_slot7) | |
| 554 | SLOT_INTERFACE("k220", DMV_K220) // K220 Diagnostic Module | |
| 555 | SLOT_INTERFACE("k231", DMV_K231) // K231 External 8088 module without interrupt controller | |
| 556 | SLOT_INTERFACE_END | |
| 557 | ||
| 558 | ||
| 559 | static SLOT_INTERFACE_START(dmv_slot2a) | |
| 560 | ||
| 561 | SLOT_INTERFACE_END | |
| 562 | ||
| 563 | static SLOT_INTERFACE_START(dmv_slot7a) | |
| 564 | SLOT_INTERFACE("k230", DMV_K230) // K230 Internal 8088 module without interrupt controller | |
| 565 | SLOT_INTERFACE("k235", DMV_K235) // K235 Internal 8088 module with interrupt controller | |
| 566 | SLOT_INTERFACE_END | |
| 567 | ||
| 351 | 568 | static MACHINE_CONFIG_START( dmv, dmv_state ) |
| 352 | 569 | /* basic machine hardware */ |
| 353 | 570 | MCFG_CPU_ADD("maincpu",Z80, XTAL_24MHz / 6) |
| r31660 | r31661 | |
| 366 | 583 | MCFG_SCREEN_REFRESH_RATE(50) |
| 367 | 584 | MCFG_SCREEN_VBLANK_TIME(ATTOSECONDS_IN_USEC(2500)) /* not accurate */ |
| 368 | 585 | MCFG_SCREEN_UPDATE_DEVICE("upd7220", upd7220_device, screen_update) |
| 369 | MCFG_SCREEN_SIZE(640, 480) | |
| 370 | MCFG_SCREEN_VISIBLE_AREA(0, 640-1, 0, 480-1) | |
| 586 | MCFG_SCREEN_SIZE(640, 400) | |
| 587 | MCFG_SCREEN_VISIBLE_AREA(0, 640-1, 0, 400-1) | |
| 371 | 588 | |
| 372 | 589 | MCFG_GFXDECODE_ADD("gfxdecode", "palette", dmv) |
| 373 | MCFG_PALETTE_ADD_ | |
| 590 | MCFG_PALETTE_ADD_MONOCHROME_GREEN("palette") | |
| 374 | 591 | MCFG_DEFAULT_LAYOUT(layout_dmv) |
| 375 | 592 | |
| 376 | 593 | // devices |
| r31660 | r31661 | |
| 382 | 599 | MCFG_DEVICE_ADD( "dma8237", AM9517A, XTAL_4MHz ) |
| 383 | 600 | MCFG_I8237_OUT_HREQ_CB(WRITELINE(dmv_state, dma_hrq_changed)) |
| 384 | 601 | MCFG_I8237_OUT_EOP_CB(WRITELINE(dmv_state, dmac_eop)) |
| 385 | MCFG_I8237_IN_MEMR_CB(READ8(dmv_state, memory_read_byte)) | |
| 386 | MCFG_I8237_OUT_MEMW_CB(WRITE8(dmv_state, memory_write_byte)) | |
| 602 | MCFG_I8237_IN_MEMR_CB(READ8(dmv_state, program_r)) | |
| 603 | MCFG_I8237_OUT_MEMW_CB(WRITE8(dmv_state, program_w)) | |
| 604 | MCFG_I8237_IN_IOR_0_CB(LOGGER("DMA CH1", 0)) | |
| 605 | MCFG_I8237_OUT_IOW_0_CB(LOGGER("DMA CH1", 0)) | |
| 606 | MCFG_I8237_IN_IOR_1_CB(LOGGER("DMA CH2", 0)) | |
| 607 | MCFG_I8237_OUT_IOW_1_CB(LOGGER("DMA CH2", 0)) | |
| 608 | MCFG_I8237_IN_IOR_2_CB(DEVREAD8("upd7220", upd7220_device, dack_r)) | |
| 609 | MCFG_I8237_OUT_IOW_2_CB(DEVWRITE8("upd7220", upd7220_device, dack_w)) | |
| 387 | 610 | MCFG_I8237_IN_IOR_3_CB(DEVREAD8("i8272", i8272a_device, mdma_r)) |
| 388 | 611 | MCFG_I8237_OUT_IOW_3_CB(DEVWRITE8("i8272", i8272a_device, mdma_w)) |
| 389 | 612 | MCFG_I8237_OUT_DACK_3_CB(WRITELINE(dmv_state, dmac_dack3)) |
| r31660 | r31661 | |
| 391 | 614 | MCFG_I8272A_ADD( "i8272", true ) |
| 392 | 615 | MCFG_UPD765_INTRQ_CALLBACK(WRITELINE(dmv_state, fdc_irq)) |
| 393 | 616 | MCFG_UPD765_DRQ_CALLBACK(DEVWRITELINE("dma8237", am9517a_device, dreq3_w)) |
| 394 | MCFG_FLOPPY_DRIVE_ADD("i8272:0", dmv_floppies, "525dd", floppy_image_device::default_floppy_formats) | |
| 395 | MCFG_FLOPPY_DRIVE_ADD("i8272:1", dmv_floppies, "525dd", floppy_image_device::default_floppy_formats) | |
| 617 | MCFG_FLOPPY_DRIVE_ADD("i8272:0", dmv_floppies, "525dd", dmv_state::floppy_formats) | |
| 618 | MCFG_FLOPPY_DRIVE_ADD("i8272:1", dmv_floppies, "525dd", dmv_state::floppy_formats) | |
| 396 | 619 | |
| 397 | 620 | MCFG_DEVICE_ADD("pit8253", PIT8253, 0) |
| 398 | 621 | MCFG_PIT8253_CLK0(50) |
| 399 | 622 | MCFG_PIT8253_OUT0_HANDLER(WRITELINE(dmv_state, pit_out0)) |
| 400 | //MCFG_PIT8253_CLK2(XTAL_24MHz / 3 / 16) | |
| 401 | //MCFG_PIT8253_OUT2_HANDLER(WRITELINE(dmv_state, timint_w)) | |
| 623 | MCFG_PIT8253_CLK2(XTAL_24MHz / 3 / 16) | |
| 624 | MCFG_PIT8253_OUT2_HANDLER(WRITELINE(dmv_state, timint_w)) | |
| 402 | 625 | |
| 403 | 626 | /* sound hardware */ |
| 404 | 627 | MCFG_SPEAKER_STANDARD_MONO( "mono" ) |
| 405 | 628 | MCFG_SOUND_ADD("speaker", SPEAKER_SOUND, 0) |
| 406 | 629 | MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50) |
| 630 | ||
| 631 | MCFG_DEVICE_ADD("slot1", DMVCART_SLOT, 0) | |
| 632 | MCFG_DEVICE_SLOT_INTERFACE(dmv_slot1, NULL, false) | |
| 633 | MCFG_DEVICE_ADD("slot2", DMVCART_SLOT, 0) | |
| 634 | MCFG_DEVICE_SLOT_INTERFACE(dmv_slot2_6, NULL, false) | |
| 635 | MCFG_DEVICE_ADD("slot2a", DMVCART_SLOT, 0) | |
| 636 | MCFG_DEVICE_SLOT_INTERFACE(dmv_slot2a, NULL, false) | |
| 637 | MCFG_DEVICE_ADD("slot3", DMVCART_SLOT, 0) | |
| 638 | MCFG_DEVICE_SLOT_INTERFACE(dmv_slot2_6, NULL, false) | |
| 639 | MCFG_DEVICE_ADD("slot4", DMVCART_SLOT, 0) | |
| 640 | MCFG_DEVICE_SLOT_INTERFACE(dmv_slot2_6, NULL, false) | |
| 641 | MCFG_DEVICE_ADD("slot5", DMVCART_SLOT, 0) | |
| 642 | MCFG_DEVICE_SLOT_INTERFACE(dmv_slot2_6, NULL, false) | |
| 643 | MCFG_DEVICE_ADD("slot6", DMVCART_SLOT, 0) | |
| 644 | MCFG_DEVICE_SLOT_INTERFACE(dmv_slot2_6, NULL, false) | |
| 645 | ||
| 646 | MCFG_DEVICE_ADD("slot7", DMVCART_SLOT, 0) | |
| 647 | MCFG_DEVICE_SLOT_INTERFACE(dmv_slot7, NULL, false) | |
| 648 | MCFG_DMVCART_SLOT_PROGRAM_READWRITE_CB(READ8(dmv_state, program_r), WRITE8(dmv_state, program_w)) | |
| 649 | MCFG_DEVICE_ADD("slot7a", DMVCART_SLOT, 0) | |
| 650 | MCFG_DEVICE_SLOT_INTERFACE(dmv_slot7a, "k230", false) | |
| 651 | MCFG_DMVCART_SLOT_PROGRAM_READWRITE_CB(READ8(dmv_state, program_r), WRITE8(dmv_state, program_w)) | |
| 652 | ||
| 407 | 653 | MACHINE_CONFIG_END |
| 408 | 654 | |
| 409 | 655 | /* ROM definition */ |
| 410 | 656 | ROM_START( dmv ) |
| 411 | ROM_REGION( 0x10000, "maincpu", ROMREGION_ERASEFF ) | |
| 412 | ROM_LOAD( "dmv_norm.bin", 0x0000, 0x2000, CRC(bf25f3f0) SHA1(0c7dd37704db4799e340cc836f887cd543e5c964)) | |
| 657 | ROM_REGION( 0x2000, "boot", 0 ) | |
| 658 | ROM_SYSTEM_BIOS(0, "c07", "C.07.00") // ROM bears the handwritten note "Color 7.0", this is from the machine that originally had Color, 68K and internal 8088 | |
| 659 | ROM_SYSTEM_BIOS(1, "m07", "M.07.00") // Mono machine with internal 8088 and internal HD | |
| 660 | ROM_SYSTEM_BIOS(2, "m06", "M.06.00") // Mono machine | |
| 661 | ROM_SYSTEM_BIOS(3, "m05", "M.05.00") // Mono machine, marked "updated" | |
| 413 | 662 | |
| 663 | ROMX_LOAD( "dmv_mb_rom_33610.bin", 0x00000, 0x02000, CRC(bf25f3f0) SHA1(0c7dd37704db4799e340cc836f887cd543e5c964), ROM_BIOS(1) ) | |
| 664 | ROMX_LOAD( "dmv_mb_rom_33609.bin", 0x00000, 0x02000, CRC(120951b6) SHA1(57bef9cc6379dea5730bc1477e8896508e00a349), ROM_BIOS(2) ) | |
| 665 | ROMX_LOAD( "dmv_mb_rom_32676.bin", 0x00000, 0x02000, CRC(7796519e) SHA1(8d5dd9c1e66c96fcca271b6f673d6a0e784acb33), ROM_BIOS(3) ) | |
| 666 | ROMX_LOAD( "dmv_mb_rom_32664.bin", 0x00000, 0x02000, CRC(6624610e) SHA1(e9226be897d2c5f875784ab77dad8807f14c7714), ROM_BIOS(4) ) | |
| 667 | ||
| 414 | 668 | ROM_REGION(0x400, "kb_ctrl_mcu", 0) |
| 415 | ROM_LOAD( "dmv_kb_ctrl_mcu.bin", 0x0000, 0x0400, CRC(a03af298) SHA1(144cba41294c46f5ca79b7ad8ced0e4408168775)) | |
| 669 | ROMX_LOAD( "dmv_mb_8741_32678.bin", 0x00000, 0x00400, CRC(50d1dc4c) SHA1(2c8251d6c8df9f507e11bf920869657f4d074db1), ROM_BIOS(1) ) | |
| 670 | ROMX_LOAD( "dmv_mb_8741_32678.bin", 0x00000, 0x00400, CRC(50d1dc4c) SHA1(2c8251d6c8df9f507e11bf920869657f4d074db1), ROM_BIOS(2) ) | |
| 671 | ROMX_LOAD( "dmv_mb_8741_32678.bin", 0x00000, 0x00400, CRC(50d1dc4c) SHA1(2c8251d6c8df9f507e11bf920869657f4d074db1), ROM_BIOS(3) ) | |
| 672 | ROMX_LOAD( "dmv_mb_8741_32121.bin", 0x00000, 0x00400, CRC(a03af298) SHA1(144cba41294c46f5ca79b7ad8ced0e4408168775), ROM_BIOS(4) ) | |
| 673 | ||
| 674 | ROM_REGION(0x800, "chargen", 0) | |
| 675 | ROM_LOAD( "76161.bin", 0x00000, 0x00800, CRC(6e4df4f9) SHA1(20ff4fc48e55eaf5131f6573fff93e7f97d2f45d)) // same for both color and monochrome board | |
| 676 | ||
| 677 | ROM_REGION(0x10000, "ram", ROMREGION_ERASE) // 64K RAM on mainboard | |
| 416 | 678 | ROM_END |
| 417 | 679 | |
| 418 | 680 | /* Driver */ |
| r31660 | r31661 | |
|---|---|---|
| 575 | 575 | BUSES += COMPUCOLOR |
| 576 | 576 | BUSES += COMX35 |
| 577 | 577 | BUSES += CPC |
| 578 | BUSES += DMV | |
| 578 | 579 | BUSES += ECBBUS |
| 579 | 580 | BUSES += ECONET |
| 580 | 581 | BUSES += EP64 |
| r31660 | r31661 | |
|---|---|---|
| 52 | 52 | PORT_START("COL.1") |
| 53 | 53 | PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_0_PAD) PORT_CHAR(UCHAR_MAMEKEY(0_PAD)) |
| 54 | 54 | PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_CAPSLOCK) PORT_CHAR(UCHAR_MAMEKEY(CAPSLOCK)) |
| 55 | PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_BACKSLASH) PORT_CHAR( | |
| 55 | PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_BACKSLASH) PORT_CHAR('\\') PORT_CHAR('|') | |
| 56 | 56 | PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_PGUP) PORT_NAME("00") |
| 57 | 57 | PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_DEL_PAD) PORT_CHAR(UCHAR_MAMEKEY(DEL_PAD)) |
| 58 | 58 | PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_LCONTROL) PORT_CHAR(UCHAR_MAMEKEY(LCONTROL)) |
| r31660 | r31661 | |
| 112 | 112 | PORT_START("COL.7") |
| 113 | 113 | PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_NAME("F14") |
| 114 | 114 | PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_BACKSLASH2) PORT_CHAR('`') PORT_CHAR('~') |
| 115 | PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_ENTER) PORT_CHAR(UCHAR_MAMEKEY(ENTER)) | |
| 115 | PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_ENTER) PORT_CHAR(UCHAR_MAMEKEY(ENTER)) PORT_NAME("Enter") | |
| 116 | 116 | PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_UNUSED ) |
| 117 | 117 | PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_UNUSED ) |
| 118 | 118 | PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_CLOSEBRACE) PORT_CHAR(']') PORT_CHAR('}') |
| Previous | 199869 Revisions | Next |