trunk/src/mess/machine/shark.c
| r0 | r23681 | |
| 1 | /********************************************************************** |
| 2 | |
| 3 | Mator Systems SHARK Intelligent Winchester Disc Subsystem emulation |
| 4 | |
| 5 | Copyright MESS Team. |
| 6 | Visit http://mamedev.org for licensing and usage restrictions. |
| 7 | |
| 8 | **********************************************************************/ |
| 9 | |
| 10 | #include "shark.h" |
| 11 | |
| 12 | |
| 13 | |
| 14 | //************************************************************************** |
| 15 | // MACROS / CONSTANTS |
| 16 | //************************************************************************** |
| 17 | |
| 18 | #define I8085_TAG "i8085" |
| 19 | #define RS232_TAG "rs232" |
| 20 | |
| 21 | |
| 22 | |
| 23 | //************************************************************************** |
| 24 | // DEVICE DEFINITIONS |
| 25 | //************************************************************************** |
| 26 | |
| 27 | const device_type SHARK = &device_creator<shark_device>; |
| 28 | |
| 29 | |
| 30 | //------------------------------------------------- |
| 31 | // ROM( shark ) |
| 32 | //------------------------------------------------- |
| 33 | |
| 34 | ROM_START( shark ) |
| 35 | ROM_REGION( 0x5000, I8085_TAG, 0 ) |
| 36 | ROM_LOAD( "pch488 3450 v22.1 #1", 0x0000, 0x1000, CRC(03bff9d7) SHA1(ac506df6509e1b2185a69f9f8f44b8b456aa9834) ) |
| 37 | ROM_LOAD( "pch488 3450 v22.1 #2", 0x1000, 0x1000, CRC(c14fa5fe) SHA1(bcfd1dd65d692c76b90e6134b85f22c39c049430) ) |
| 38 | ROM_LOAD( "pch488 3450 v22.1 #3", 0x2000, 0x1000, CRC(4dfaa482) SHA1(fe2c44bb650572616c8bdad6358032fe64b1e363) ) |
| 39 | ROM_LOAD( "pch488 3450 v22.1 #4", 0x3000, 0x1000, NO_DUMP ) |
| 40 | ROM_LOAD( "pch488 3450 v22.1 #5", 0x4000, 0x1000, CRC(aef665e9) SHA1(80a4c00b717100b4e22fa3704e34060fffce2bc3) ) |
| 41 | |
| 42 | ROM_REGION( 0x800, "micro", 0 ) // address decoder |
| 43 | ROM_LOAD( "micro p3450 v1.3", 0x000, 0x800, CRC(0e69202e) SHA1(3b384951ff54c4b45a3a778a88966d13e2c9d57a) ) |
| 44 | ROM_END |
| 45 | |
| 46 | |
| 47 | //------------------------------------------------- |
| 48 | // rom_region - device-specific ROM region |
| 49 | //------------------------------------------------- |
| 50 | |
| 51 | const rom_entry *shark_device::device_rom_region() const |
| 52 | { |
| 53 | return ROM_NAME( shark ); |
| 54 | } |
| 55 | |
| 56 | |
| 57 | //------------------------------------------------- |
| 58 | // ADDRESS_MAP( shark_mem ) |
| 59 | //------------------------------------------------- |
| 60 | |
| 61 | static ADDRESS_MAP_START( shark_mem, AS_PROGRAM, 8, shark_device ) |
| 62 | AM_RANGE(0x0000, 0x4fff) AM_ROM AM_REGION(I8085_TAG, 0) |
| 63 | ADDRESS_MAP_END |
| 64 | |
| 65 | |
| 66 | //------------------------------------------------- |
| 67 | // ADDRESS_MAP( shark_io ) |
| 68 | //------------------------------------------------- |
| 69 | |
| 70 | static ADDRESS_MAP_START( shark_io, AS_IO, 8, shark_device ) |
| 71 | ADDRESS_MAP_END |
| 72 | |
| 73 | |
| 74 | //------------------------------------------------- |
| 75 | // I8085_CONFIG( cpu_intf ) |
| 76 | //------------------------------------------------- |
| 77 | |
| 78 | static I8085_CONFIG( cpu_intf ) |
| 79 | { |
| 80 | DEVCB_NULL, |
| 81 | DEVCB_NULL, |
| 82 | DEVCB_NULL, |
| 83 | DEVCB_NULL |
| 84 | }; |
| 85 | |
| 86 | |
| 87 | //------------------------------------------------- |
| 88 | // rs232_port_interface rs232_intf |
| 89 | //------------------------------------------------- |
| 90 | |
| 91 | static const rs232_port_interface rs232_intf = |
| 92 | { |
| 93 | DEVCB_NULL, |
| 94 | DEVCB_NULL, |
| 95 | DEVCB_NULL, |
| 96 | DEVCB_NULL, |
| 97 | DEVCB_NULL |
| 98 | }; |
| 99 | |
| 100 | |
| 101 | //------------------------------------------------- |
| 102 | // MACHINE_CONFIG_FRAGMENT( shark ) |
| 103 | //------------------------------------------------- |
| 104 | |
| 105 | static MACHINE_CONFIG_FRAGMENT( shark ) |
| 106 | // basic machine hardware |
| 107 | MCFG_CPU_ADD(I8085_TAG, I8085A, 1000000) |
| 108 | MCFG_CPU_CONFIG(cpu_intf) |
| 109 | MCFG_CPU_PROGRAM_MAP(shark_mem) |
| 110 | MCFG_CPU_IO_MAP(shark_io) |
| 111 | |
| 112 | // devices |
| 113 | MCFG_HARDDISK_ADD("harddisk1") |
| 114 | MCFG_RS232_PORT_ADD(RS232_TAG, rs232_intf, default_rs232_devices, NULL) |
| 115 | MACHINE_CONFIG_END |
| 116 | |
| 117 | |
| 118 | //------------------------------------------------- |
| 119 | // machine_config_additions - device-specific |
| 120 | // machine configurations |
| 121 | //------------------------------------------------- |
| 122 | |
| 123 | machine_config_constructor shark_device::device_mconfig_additions() const |
| 124 | { |
| 125 | return MACHINE_CONFIG_NAME( shark ); |
| 126 | } |
| 127 | |
| 128 | |
| 129 | //------------------------------------------------- |
| 130 | // INPUT_PORTS( shark ) |
| 131 | //------------------------------------------------- |
| 132 | |
| 133 | INPUT_PORTS_START( shark ) |
| 134 | INPUT_PORTS_END |
| 135 | |
| 136 | |
| 137 | //------------------------------------------------- |
| 138 | // input_ports - device-specific input ports |
| 139 | //------------------------------------------------- |
| 140 | |
| 141 | ioport_constructor shark_device::device_input_ports() const |
| 142 | { |
| 143 | return INPUT_PORTS_NAME( shark ); |
| 144 | } |
| 145 | |
| 146 | |
| 147 | |
| 148 | //************************************************************************** |
| 149 | // LIVE DEVICE |
| 150 | //************************************************************************** |
| 151 | |
| 152 | //------------------------------------------------- |
| 153 | // shark_device - constructor |
| 154 | //------------------------------------------------- |
| 155 | |
| 156 | shark_device::shark_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock) |
| 157 | : device_t(mconfig, SHARK, "Mator SHARK", tag, owner, clock, "shark", __FILE__), |
| 158 | device_ieee488_interface(mconfig, *this), |
| 159 | m_maincpu(*this, I8085_TAG) |
| 160 | { |
| 161 | } |
| 162 | |
| 163 | |
| 164 | //------------------------------------------------- |
| 165 | // device_start - device-specific startup |
| 166 | //------------------------------------------------- |
| 167 | |
| 168 | void shark_device::device_start() |
| 169 | { |
| 170 | } |
trunk/src/mess/machine/shark.h
| r0 | r23681 | |
| 1 | /********************************************************************** |
| 2 | |
| 3 | Mator Systems SHARK Intelligent Winchester Disc Subsystem emulation |
| 4 | |
| 5 | 35MB PRIAM DISKOS 3450 8" Winchester Hard Disk (-chs 525,5,? -ss ?) |
| 6 | |
| 7 | Copyright MESS Team. |
| 8 | Visit http://mamedev.org for licensing and usage restrictions. |
| 9 | |
| 10 | **********************************************************************/ |
| 11 | |
| 12 | #pragma once |
| 13 | |
| 14 | #ifndef __SHARK__ |
| 15 | #define __SHARK__ |
| 16 | |
| 17 | #include "emu.h" |
| 18 | #include "cpu/i8085/i8085.h" |
| 19 | #include "imagedev/harddriv.h" |
| 20 | #include "machine/ieee488.h" |
| 21 | #include "machine/serial.h" |
| 22 | |
| 23 | |
| 24 | |
| 25 | //************************************************************************** |
| 26 | // TYPE DEFINITIONS |
| 27 | //************************************************************************** |
| 28 | |
| 29 | // ======================> shark_device |
| 30 | |
| 31 | class shark_device : public device_t, |
| 32 | public device_ieee488_interface |
| 33 | { |
| 34 | public: |
| 35 | // construction/destruction |
| 36 | shark_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock); |
| 37 | |
| 38 | // optional information overrides |
| 39 | virtual const rom_entry *device_rom_region() const; |
| 40 | virtual machine_config_constructor device_mconfig_additions() const; |
| 41 | virtual ioport_constructor device_input_ports() const; |
| 42 | |
| 43 | protected: |
| 44 | // device-level overrides |
| 45 | virtual void device_start(); |
| 46 | |
| 47 | private: |
| 48 | required_device<cpu_device> m_maincpu; |
| 49 | }; |
| 50 | |
| 51 | |
| 52 | // device type definition |
| 53 | extern const device_type SHARK; |
| 54 | |
| 55 | |
| 56 | |
| 57 | #endif |