src/mess/machine/abc_fd2.c
| r0 | r13262 | |
| 1 | /*
|
| 2 | ABC FD2
|
| 3 | |
| 4 | PCB Layout
|
| 5 | ----------
|
| 6 | |
| 7 | |-------------------------------------------|
|
| 8 | |-| |
|
| 9 | |-| ROM0 4MHz |
|
| 10 | |-| |
|
| 11 | |-| Z80PIO |
|
| 12 | |-| CN1|
|
| 13 | |-| FD1771 2114 |
|
| 14 | |-| 2114 |
|
| 15 | |-| Z80 ROM1 |
|
| 16 | |-| |
|
| 17 | |-------------------------------------------|
|
| 18 | |
| 19 | Notes:
|
| 20 | Relevant IC's shown.
|
| 21 | |
| 22 | ROM0 - AMI 8005SAJ 1Kx8 EPROM
|
| 23 | ROM1 - Motorola MCM2708C 1Kx8 EPROM
|
| 24 | Z80 - Zilog Z-80 CPU
|
| 25 | Z80PIO - Zilog Z-80A PIO
|
| 26 | FD1771 - FD1771-B01
|
| 27 | 2114 - National Semiconductor MM2114N 1Kx4 Static RAM
|
| 28 | CN1 - 2x17 pin PCB header
|
| 29 | |
| 30 | */
|
| 31 | |
| 32 | #include "abc_fd2.h"
|
| 33 | |
| 34 | |
| 35 | |
| 36 | //**************************************************************************
|
| 37 | // MACROS / CONSTANTS
|
| 38 | //**************************************************************************
|
| 39 | |
| 40 | #define Z80_TAG "2e"
|
| 41 | #define Z80PIO_TAG "2c"
|
| 42 | #define FD1771_TAG "2d"
|
| 43 | |
| 44 | |
| 45 | |
| 46 | //**************************************************************************
|
| 47 | // DEVICE DEFINITIONS
|
| 48 | //**************************************************************************
|
| 49 | |
| 50 | const device_type ABC_FD2 = &device_creator<abc_fd2_device>;
|
| 51 | |
| 52 | |
| 53 | //-------------------------------------------------
|
| 54 | // ROM( abc_fd2 )
|
| 55 | //-------------------------------------------------
|
| 56 | |
| 57 | ROM_START( abc_fd2 )
|
| 58 | ROM_REGION( 0x400, Z80_TAG, 0 )
|
| 59 | ROM_LOAD( "1.02.3f", 0x000, 0x400, NO_DUMP )
|
| 60 | |
| 61 | ROM_REGION( 0x400, "abc80", 0 )
|
| 62 | ROM_LOAD( "ami 8005saj.1a", 0x000, 0x400, NO_DUMP )
|
| 63 | ROM_END
|
| 64 | |
| 65 | |
| 66 | //-------------------------------------------------
|
| 67 | // rom_region - device-specific ROM region
|
| 68 | //-------------------------------------------------
|
| 69 | |
| 70 | const rom_entry *abc_fd2_device::device_rom_region() const
|
| 71 | {
|
| 72 | return ROM_NAME( abc_fd2 );
|
| 73 | }
|
| 74 | |
| 75 | |
| 76 | //-------------------------------------------------
|
| 77 | // ADDRESS_MAP( abc_fd2_mem )
|
| 78 | //-------------------------------------------------
|
| 79 | |
| 80 | static ADDRESS_MAP_START( abc_fd2_mem, AS_PROGRAM, 8, abc_fd2_device )
|
| 81 | AM_RANGE(0x0000, 0x03ff) AM_ROM AM_REGION(Z80_TAG, 0)
|
| 82 | ADDRESS_MAP_END
|
| 83 | |
| 84 | |
| 85 | //-------------------------------------------------
|
| 86 | // ADDRESS_MAP( abc_fd2_io )
|
| 87 | //-------------------------------------------------
|
| 88 | |
| 89 | static ADDRESS_MAP_START( abc_fd2_io, AS_IO, 8, abc_fd2_device )
|
| 90 | ADDRESS_MAP_END
|
| 91 | |
| 92 | |
| 93 | //-------------------------------------------------
|
| 94 | // Z80PIO_INTERFACE( pio_intf )
|
| 95 | //-------------------------------------------------
|
| 96 | |
| 97 | static Z80PIO_INTERFACE( pio_intf )
|
| 98 | {
|
| 99 | DEVCB_NULL,
|
| 100 | DEVCB_NULL,
|
| 101 | DEVCB_NULL,
|
| 102 | DEVCB_NULL,
|
| 103 | DEVCB_NULL,
|
| 104 | DEVCB_NULL,
|
| 105 | DEVCB_NULL
|
| 106 | };
|
| 107 | |
| 108 | |
| 109 | //-------------------------------------------------
|
| 110 | // z80_daisy_config daisy_chain
|
| 111 | //-------------------------------------------------
|
| 112 | |
| 113 | static const z80_daisy_config daisy_chain[] =
|
| 114 | {
|
| 115 | { Z80PIO_TAG },
|
| 116 | { NULL }
|
| 117 | };
|
| 118 | |
| 119 | |
| 120 | //-------------------------------------------------
|
| 121 | // wd17xx_interface fdc_intf
|
| 122 | //-------------------------------------------------
|
| 123 | |
| 124 | static const wd17xx_interface fdc_intf =
|
| 125 | {
|
| 126 | DEVCB_NULL,
|
| 127 | DEVCB_NULL,
|
| 128 | DEVCB_NULL,
|
| 129 | { FLOPPY_0, FLOPPY_1, NULL, NULL }
|
| 130 | };
|
| 131 | |
| 132 | |
| 133 | //-------------------------------------------------
|
| 134 | // MACHINE_DRIVER( abc_fd2 )
|
| 135 | //-------------------------------------------------
|
| 136 | |
| 137 | static MACHINE_CONFIG_FRAGMENT( abc_fd2 )
|
| 138 | MCFG_CPU_ADD(Z80_TAG, Z80, XTAL_4MHz/2) // ?
|
| 139 | MCFG_CPU_PROGRAM_MAP(abc_fd2_mem)
|
| 140 | MCFG_CPU_IO_MAP(abc_fd2_io)
|
| 141 | MCFG_CPU_CONFIG(daisy_chain)
|
| 142 | |
| 143 | MCFG_Z80PIO_ADD(Z80PIO_TAG, XTAL_4MHz/2, pio_intf) // ?
|
| 144 | MCFG_FD1771_ADD(FD1771_TAG, fdc_intf)
|
| 145 | MACHINE_CONFIG_END
|
| 146 | |
| 147 | |
| 148 | //-------------------------------------------------
|
| 149 | // machine_config_additions - device-specific
|
| 150 | // machine configurations
|
| 151 | //-------------------------------------------------
|
| 152 | |
| 153 | machine_config_constructor abc_fd2_device::device_mconfig_additions() const
|
| 154 | {
|
| 155 | return MACHINE_CONFIG_NAME( abc_fd2 );
|
| 156 | }
|
| 157 | |
| 158 | |
| 159 | |
| 160 | //**************************************************************************
|
| 161 | // LIVE DEVICE
|
| 162 | //**************************************************************************
|
| 163 | |
| 164 | //-------------------------------------------------
|
| 165 | // abc_fd2_device - constructor
|
| 166 | //-------------------------------------------------
|
| 167 | |
| 168 | abc_fd2_device::abc_fd2_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock)
|
| 169 | : device_t(mconfig, ABC_FD2, "ABC FD2", tag, owner, clock),
|
| 170 | device_abcbus_card_interface(mconfig, *this),
|
| 171 | m_maincpu(*this, Z80_TAG),
|
| 172 | m_pio(*this, Z80PIO_TAG),
|
| 173 | m_fdc(*this, FD1771_TAG)
|
| 174 | {
|
| 175 | }
|
| 176 | |
| 177 | |
| 178 | //-------------------------------------------------
|
| 179 | // device_start - device-specific startup
|
| 180 | //-------------------------------------------------
|
| 181 | |
| 182 | void abc_fd2_device::device_start()
|
| 183 | {
|
| 184 | // find floppy image devices
|
| 185 | m_image0 = machine().device(FLOPPY_0);
|
| 186 | m_image1 = machine().device(FLOPPY_1);
|
| 187 | }
|
| 188 | |
| 189 | |
| 190 | //-------------------------------------------------
|
| 191 | // device_reset - device-specific reset
|
| 192 | //-------------------------------------------------
|
| 193 | |
| 194 | void abc_fd2_device::device_reset()
|
| 195 | {
|
| 196 | }
|
| 197 | |
| 198 | |
| 199 | |
| 200 | //**************************************************************************
|
| 201 | // ABC BUS INTERFACE
|
| 202 | //**************************************************************************
|
| 203 | |
| 204 | //-------------------------------------------------
|
| 205 | // abcbus_cs -
|
| 206 | //-------------------------------------------------
|
| 207 | |
| 208 | void abc_fd2_device::abcbus_cs(UINT8 data)
|
| 209 | {
|
| 210 | }
|
src/mess/machine/abc_fd2.h
| r0 | r13262 | |
| 1 | #pragma once
|
| 2 | |
| 3 | #ifndef __ABC_FD2__
|
| 4 | #define __ABC_FD2__
|
| 5 | |
| 6 | #define ADDRESS_MAP_MODERN
|
| 7 | |
| 8 | #include "emu.h"
|
| 9 | #include "cpu/z80/z80.h"
|
| 10 | #include "cpu/z80/z80daisy.h"
|
| 11 | #include "formats/basicdsk.h"
|
| 12 | #include "imagedev/flopdrv.h"
|
| 13 | #include "machine/abcbus.h"
|
| 14 | #include "machine/wd17xx.h"
|
| 15 | #include "machine/z80pio.h"
|
| 16 | |
| 17 | |
| 18 | |
| 19 | //**************************************************************************
|
| 20 | // TYPE DEFINITIONS
|
| 21 | //**************************************************************************
|
| 22 | |
| 23 | // ======================> abc_fd2_device
|
| 24 | |
| 25 | class abc_fd2_device : public device_t,
|
| 26 | public device_abcbus_card_interface
|
| 27 | {
|
| 28 | public:
|
| 29 | // construction/destruction
|
| 30 | abc_fd2_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 | protected:
|
| 37 | // device-level overrides
|
| 38 | virtual void device_start();
|
| 39 | virtual void device_reset();
|
| 40 | virtual void device_config_complete() { m_shortname = "abcsio"; }
|
| 41 | |
| 42 | // device_abcbus_interface overrides
|
| 43 | virtual void abcbus_cs(UINT8 data);
|
| 44 |
|
| 45 | private:
|
| 46 | required_device<cpu_device> m_maincpu;
|
| 47 | required_device<z80pio_device> m_pio;
|
| 48 | required_device<device_t> m_fdc;
|
| 49 | device_t* m_image0;
|
| 50 | device_t* m_image1;
|
| 51 | };
|
| 52 | |
| 53 | |
| 54 | // device type definition
|
| 55 | extern const device_type ABC_FD2;
|
| 56 | |
| 57 | |
| 58 | |
| 59 | #endif
|