trunk/src/emu/bus/isa/hdc.c
| r241517 | r241518 | |
| 149 | 149 | //************************************************************************** |
| 150 | 150 | |
| 151 | 151 | const device_type ISA8_HDC = &device_creator<isa8_hdc_device>; |
| 152 | const device_type ISA8_HDC_EC1841 = &device_creator<isa8_hdc_ec1841_device>; |
| 152 | 153 | |
| 153 | 154 | //------------------------------------------------- |
| 154 | 155 | // machine_config_additions - device-specific |
| r241517 | r241518 | |
| 190 | 191 | device_t(mconfig, ISA8_HDC, "Fixed Disk Controller Card", tag, owner, clock, "hdc", __FILE__), |
| 191 | 192 | device_isa8_card_interface(mconfig, *this) |
| 192 | 193 | { |
| 194 | m_type = STANDARD; |
| 193 | 195 | } |
| 194 | 196 | |
| 197 | isa8_hdc_device::isa8_hdc_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) : |
| 198 | device_t(mconfig, type, name, tag, owner, clock, shortname, source), |
| 199 | device_isa8_card_interface(mconfig, *this) |
| 200 | { |
| 201 | } |
| 202 | |
| 203 | isa8_hdc_ec1841_device::isa8_hdc_ec1841_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock) : |
| 204 | isa8_hdc_device( mconfig, ISA8_HDC_EC1841, "EC1841 HDC", tag, owner, clock, "hdc_ec1841", __FILE__) |
| 205 | { |
| 206 | m_type = EC1841; |
| 207 | } |
| 208 | |
| 195 | 209 | //------------------------------------------------- |
| 196 | 210 | // device_start - device-specific startup |
| 197 | 211 | //------------------------------------------------- |
| r241517 | r241518 | |
| 750 | 764 | |
| 751 | 765 | *buffer_ptr++ = data; |
| 752 | 766 | // XXX ec1841 wants this |
| 753 | | if (buffer[0] == CMD_SETPARAM && data_cnt == 9) { |
| 767 | if (buffer[0] == CMD_SETPARAM && data_cnt == 9 && (m_type == EC1841)) { |
| 754 | 768 | status &= ~STA_READY; |
| 755 | 769 | } else { |
| 756 | 770 | status |= STA_READY; |
trunk/src/emu/bus/isa/hdc.h
| r241517 | r241518 | |
| 25 | 25 | public: |
| 26 | 26 | // construction/destruction |
| 27 | 27 | isa8_hdc_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock); |
| 28 | isa8_hdc_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); |
| 28 | 29 | |
| 29 | 30 | // optional information overrides |
| 30 | 31 | virtual machine_config_constructor device_mconfig_additions() const; |
| r241517 | r241518 | |
| 89 | 90 | void get_drive(); |
| 90 | 91 | void get_chsn(); |
| 91 | 92 | int test_ready(); |
| 93 | |
| 94 | enum { |
| 95 | STANDARD, |
| 96 | EC1841 |
| 97 | }; |
| 98 | int m_type; |
| 92 | 99 | public: |
| 93 | 100 | void hdc_command(); |
| 94 | 101 | void pc_hdc_data_w(int data); |
| r241517 | r241518 | |
| 101 | 108 | }; |
| 102 | 109 | |
| 103 | 110 | |
| 111 | class isa8_hdc_ec1841_device : public isa8_hdc_device |
| 112 | { |
| 113 | public: |
| 114 | isa8_hdc_ec1841_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock); |
| 115 | }; |
| 116 | |
| 104 | 117 | // device type definition |
| 105 | 118 | extern const device_type ISA8_HDC; |
| 119 | extern const device_type ISA8_HDC_EC1841; |
| 106 | 120 | |
| 107 | 121 | #endif /* ISA_HDC_H */ |
trunk/src/emu/bus/isa/xsu_cards.c
| r241517 | r241518 | |
| 48 | 48 | SLOT_INTERFACE("ec1841.0004", ISA8_EC1841_0004) // BSC-like serial ports + parallel port |
| 49 | 49 | */ |
| 50 | 50 | SLOT_INTERFACE("mda", ISA8_MDA) |
| 51 | | SLOT_INTERFACE("hdc", ISA8_HDC) |
| 51 | SLOT_INTERFACE("hdc", ISA8_HDC_EC1841) |
| 52 | 52 | SLOT_INTERFACE("pccom", ISA8_COM) |
| 53 | 53 | SLOT_INTERFACE("pclpt", ISA8_LPT) |
| 54 | 54 | SLOT_INTERFACE("xtide", ISA8_XTIDE) |