diff --git a/.gitattributes b/.gitattributes index b74fb3fb6e3..7e6c1bdb8ab 100644 --- a/.gitattributes +++ b/.gitattributes @@ -96,6 +96,7 @@ hash/cpc_cass.xml svneol=native#text/xml hash/cpc_flop.xml svneol=native#text/xml hash/crvision.xml svneol=native#text/xml hash/dim68k.xml svneol=native#text/xml +hash/dmv.xml svneol=native#text/xml hash/dps1.xml svneol=native#text/xml hash/ec1841.xml svneol=native#text/xml hash/einstein.xml svneol=native#text/xml @@ -3788,6 +3789,7 @@ src/lib/formats/coupedsk.h svneol=native#text/plain src/lib/formats/cpis_dsk.c svneol=native#text/plain src/lib/formats/cpis_dsk.h svneol=native#text/plain src/lib/formats/cqm_dsk.c svneol=native#text/plain +src/lib/formats/cqm_dsk.h svneol=native#text/plain src/lib/formats/csw_cas.c svneol=native#text/plain src/lib/formats/csw_cas.h svneol=native#text/plain src/lib/formats/d64_dsk.c svneol=native#text/plain diff --git a/hash/dmv.xml b/hash/dmv.xml new file mode 100644 index 00000000000..c1620d32ccd --- /dev/null +++ b/hash/dmv.xml @@ -0,0 +1,1397 @@ + + + + + + CP/M 2.2 + 1983 + NCR Corporation + + + + + + + + + CP/M 2.2 (Alt 1) + 1983 + NCR Corporation + + + + + + + + + CP/M 2.2 (Alt 2) + 1983 + NCR Corporation + + + + + + + + + CP/M 2.2 (Alt 3) + 1983 + NCR Corporation + + + + + + + + + CP/M 2.2 (Alt 4) + 1983 + NCR Corporation + + + + + + + + + CP/M 2.2 (Alt 5) + 1983 + NCR Corporation + + + + + + + + + CP/M 2.2 Supplement + 1983 + NCR Corporation + + + + + + + + + CP/M 2.2 Supplement (Alt 1) + 1983 + NCR Corporation + + + + + + + + + CP/M 2.2 Supplement (Alt 2) + 1983 + NCR Corporation + + + + + + + + + CP/M 2.2 Supplement (Alt 3) + 1983 + NCR Corporation + + + + + + + + + CP/M-86 1.1 + 1983 + NCR Corporation + + + + + + + + + CP/M-86 1.1 (Alt 1) + 1983 + NCR Corporation + + + + + + + + + CP/M-86 1.1 (Alt 2) + 1983 + NCR Corporation + + + + + + + + + CP/M-86 1.1 (Alt 3) + 1983 + NCR Corporation + + + + + + + + + CP/M-86 1.1 (Alt 4) + 1983 + NCR Corporation + + + + + + + + + CP/M-86 1.1 (Alt 5) + 1983 + NCR Corporation + + + + + + + + + CP/M-86 1.1 (Alt 6) + 1983 + NCR Corporation + + + + + + + + + CP/M-68k + 198? + NCR Corporation + + + + + + + + + + CP/M-68k (Alt) + 198? + NCR Corporation + + + + + + + + + + UCSD p-System IV.13 + 198? + <unknown> + + + + + + + + + + + + + + + + + + + + + + + + UCSD p-System IV.13 (Alt) + 198? + <unknown> + + + + + + + + + + + + + + + + + + + + + + + + MS-DOS v2.11 + 1983 + Microsoft + + + + + + + + + MS-DOS v2.0 Master disk + 1983 + Microsoft + + + + + + + + + + + + + + MS-DOS v2.11 Master disk + 1983 + Microsoft + + + + + + + + + + + + + + Graphics Extension v1.1 + 1983 + NCR Corporation + + + + + + + + + Graphics Extension v1.0 + 1983 + NCR Corporation + + + + + + + + + OPEN ACCESS + 1984 + Software Products International + + + + + + + + + + + + + + + + + + + + + + + + + GW-BASIC v1.06 + 1983 + Microsoft + + + + + + + + + GW-BASIC v1.04 + 1983 + Microsoft + + + + + + + + + Z-Com v2.0 + 1988 + Alpha Systems + + + + + + + + + Z-Com v2.0 HD + 198? + <unknown> + + + + + + + + + + BASIC-86 v5.28 (DOS) + 1983 + Microsoft + + + + + + + + + + BASIC-86 v5.22 (CP/M) + 1983 + Microsoft + + + + + + + + + DMV Diagnostic Diskette + 198? + NCR Corporation + + + + + + + + + DMV RS232 Inteface Diagnostic + 198? + NCR Corporation + + + + + + + + + DMV IEEE-448 Inteface Diagnostic + 198? + NCR Corporation + + + + + + + + + + Nevada COBOL + 198? + Ellis Computing + + + + + + + + + Nevada Edit + 198? + Ellis Computing + + + + + + + + + Nevada Pascal + 198? + Ellis Computing + + + + + + + + + + + + + + Nevada Pilot + 198? + Ellis Computing + + + + + + + + + NCR PC2PC Network Requester v1.01.00 + 1985 + NCR Corporation + + + + + + + + + + NCR PC2PC Network Requester v1.01.00 (Alt) + 1985 + NCR Corporation + + + + + + + + + + StarBurst v1.01 + 198? + MicroPro International + + + + + + + + + + NCR 7900 Terminal Emulators (DOS) + 1984 + NCR Corporation + + + + + + + + + + NCR 7900 Terminal Emulators V2.0 (CP/M) + 1983 + NCR Corporation + + + + + + + + + C Compiler V1.2.3 + 1983 + SuperSoft + + + + + + + + + + + + + + + DESQ + 198? + <unknown> + + + + + + + + + + + + + + + + + + + + + + + + RM/COBOL Compiler v1.5E + 1983 + <unknown> + + + + + + + + + + Supersort v1.62 + 1983 + MicroPro International + + + + + + + + + + T.I.M. III v3.31 + 1983 + Innovative Software, Inc. + + + + + + + + + + + + + + + + + + + + Microsoft FORTRAN 77 v3.13 + 1983 + Microsoft + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + SuperCalc V1.12 + 1983 + SORCIM CORP. + + + + + + + + + + WordStar 3.21 + 198? + <unknown> + + + + + + + + + WordStar V3.0 + 198? + <unknown> + + + + + + + + + + WordStar V3.30 + 198? + <unknown> + + + + + + + + + + WordStar V3.30 (Alt) + 198? + <unknown> + + + + + + + + + + WordStar V3.30 (Alt 2) + 198? + <unknown> + + + + + + + + + + WordStar V3.30 (CP/M-86) + 198? + <unknown> + + + + + + + + + WordStar V3.40 + 198? + <unknown> + + + + + + + + + + WordStar V3.30 with SpellStar, Mailmerge and DataStar + 198? + <unknown> + + + + + + + + + + Mailmerge + 198? + <unknown> + + + + + + + + + + + SpellStar + 198? + <unknown> + + + + + + + + + + Mailmerge + SpellStar (CP/M-86) + 198? + <unknown> + + + + + + + + + COBOL + 198? + <unknown> + + + + + + + + + + + + + + MS-Pascal Compiler + 198? + Microsoft + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Microsoft BASIC Compiler v5.50 + 1983 + Microsoft + + + + + + + + + + MicroPlan v4.04 + 198? + <unknown> + + + + + + + + + FORTRAN v3.44 + 198? + <unknown> + + + + + + + + + DR Graph + 1983 + Digital Research + + + + + + + + + DR Graph (Alt) + 1983 + Digital Research + + + + + + + + + dBASE II v2.38 + 198? + <unknown> + + + + + + + + + dBASE II v2.38 + WordStar + 198? + <unknown> + + + + + + + + + dBASE II v2.40 + 198? + <unknown> + + + + + + + + + + TURBO Pascal v3.01A + 1985 + BORLAND Inc. + + + + + + + + + DataStar v1.42 + 1983 + MicroPro International + + + + + + + + + + ReportStar v1.03 + 1983 + MicroPro International + + + + + + + + + + DataStar v1.42 + ReportStar v1.03 + 198? + <unknown> + + + + + + + + + + EXCHANGE CP/M + 1983 + NCR Corporation + + + + + + + + + EXCHANGE DOS + 1983 + NCR Corporation + + + + + + + + + + AutoCAD + 1987 + <unknown> + + + + + + + + + + + + + + + AutoCAD (Alt 1) + 1987 + <unknown> + + + + + + + + + + + + + + + + + + + + + + + + + AutoCAD (Alt 2) + 1987 + <unknown> + + + + + + + + + + + + + + + Move-It + 198? + Woolf Software Systems + + + + + + + + + CP/M 2.2 Spiele + 198? + <unknown> + + + + + + + + + CP/M 2.2 Sprei + 198? + <unknown> + + + + + + + + + CP/M 2.2 Utilities + 198? + <unknown> + + + + + + + + + CP/M Utilities (Alt) + 198? + <unknown> + + + + + + + + + CP/M 2.2 Games + 198? + <unknown> + + + + + + + + + CP/M 2.2 Games (Alt) + 198? + <unknown> + + + + + + + + + CP/M-86 Games + 198? + <unknown> + + + + + + + + + CP/M 2.2 Milestone + 198? + <unknown> + + + + + + + + + MS-BASIC + NCR-BASIC + 198? + <unknown> + + + + + + + + + MS-DOS v2.11 HD + 198? + Microsoft + + + + + + + + + + MS-DOS v2.11 HD (Alt) + 198? + Microsoft + + + + + + + + + + MS-DOS v2.11 HD (Alt 2) + 198? + <unknown> + + + + + + + + + + MS-DOS v2.11 HD (Alt 3) + 198? + <unknown> + + + + + + + + + + DOS Tools + 198? + <unknown> + + + + + + + + + + DOS Utilities + 198? + <unknown> + + + + + + + + + + Norton Utilities v3.00 + 1985 + <unknown> + + + + + + + + + + Norton Utilities v3.00 (Alt) + 198? + <unknown> + + + + + + + + + + OPEN ACCESS (3 LZH archives) + 198? + <unknown> + + + + + + + + + + Print Master (2 LZH archives) + 198? + <unknown> + + + + + + + + + + WordStar V4 (2 LZH archives) + 198? + <unknown> + + + + + + + + + Bradford (LZH archive) + 198? + <unknown> + + + + + + + + + + BD Software C Compiler + 198? + <unknown> + + + + + + + + + + + + + + Assembler Plus Tools + 198? + <unknown> + + + + + + + + + MS-BASIC v5.21 + 198? + Microsoft + + + + + + + diff --git a/src/emu/imagedev/floppy.c b/src/emu/imagedev/floppy.c index 94d108df4db..a73463f77b7 100644 --- a/src/emu/imagedev/floppy.c +++ b/src/emu/imagedev/floppy.c @@ -105,6 +105,7 @@ const floppy_format_type floppy_image_device::default_floppy_formats[] = { FLOPPY_MFI_FORMAT, FLOPPY_MFM_FORMAT, FLOPPY_TD0_FORMAT, + FLOPPY_CQM_FORMAT, NULL }; diff --git a/src/emu/imagedev/floppy.h b/src/emu/imagedev/floppy.h index 36f42fad2fe..89db2e4bff6 100644 --- a/src/emu/imagedev/floppy.h +++ b/src/emu/imagedev/floppy.h @@ -15,6 +15,7 @@ #include "formats/ipf_dsk.h" #include "formats/mfi_dsk.h" #include "formats/td0_dsk.h" +#include "formats/cqm_dsk.h" #include "ui/imgcntrl.h" #define MCFG_FLOPPY_DRIVE_ADD(_tag, _slot_intf, _def_slot, _formats) \ @@ -36,6 +37,7 @@ FLOPPY_MFI_FORMAT, \ FLOPPY_MFM_FORMAT, \ FLOPPY_TD0_FORMAT, \ + FLOPPY_CQM_FORMAT, \ NULL }; diff --git a/src/lib/formats/cqm_dsk.c b/src/lib/formats/cqm_dsk.c index 3df90f72c2e..ca8ae98039b 100644 --- a/src/lib/formats/cqm_dsk.c +++ b/src/lib/formats/cqm_dsk.c @@ -225,3 +225,154 @@ FLOPPY_CONSTRUCT( cqm_dsk_construct ) return FLOPPY_ERROR_SUCCESS; } + + + + +/********************************************************************* + + formats/cqm_dsk.c + + CopyQM disk images + +*********************************************************************/ + +#include "cqm_dsk.h" + +cqm_format::cqm_format() +{ +} + +const char *cqm_format::name() const +{ + return "cqm"; +} + +const char *cqm_format::description() const +{ + return "CopyQM disk image"; +} + +const char *cqm_format::extensions() const +{ + return "cqm,cqi,dsk"; +} + +int cqm_format::identify(io_generic *io, UINT32 form_factor) +{ + UINT8 h[3]; + io_generic_read(io, h, 0, 3); + + if (h[0] == 'C' && h[1] == 'Q' && h[2] == 0x14) + return 100; + + return 0; +} + +bool cqm_format::load(io_generic *io, UINT32 form_factor, floppy_image *image) +{ + const int max_size = 4*1024*1024; // 4MB ought to be large enough for any floppy + dynamic_buffer imagebuf(max_size); + UINT8 header[CQM_HEADER_SIZE]; + io_generic_read(io, header, 0, CQM_HEADER_SIZE); + + int sector_size = (header[0x04] << 8) | header[0x03]; + int sector_per_track = (header[0x11] << 8) | header[0x10]; + int heads = (header[0x13] << 8) | header[0x12]; + int tracks = header[0x5b]; +// int blind = header[0x58]; // 0=DOS, 1=blind, 2=HFS + int density = header[0x59]; // 0=DD, 1=HD, 2=ED + int comment_size = (header[0x70] << 8) | header[0x6f]; + int sector_base = header[0x71] + 1; +// int interleave = header[0x74]; // TODO +// int skew = header[0x75]; // TODO +// int drive = header[0x76]; // source drive type: 1=5.25" 360KB, 2=5.25" 1.2MB, 3=3.5" 720KB, 4=3.5" 1.44MB, 6=3.5" 2.88MB, 8" is unknown (0 or 5?) + + switch(density) + { + case 0: + if (form_factor == floppy_image::FF_525 && tracks > 50) + image->set_variant(heads == 1 ? floppy_image::SSQD : floppy_image::DSQD); + else + image->set_variant(heads == 1 ? floppy_image::SSDD : floppy_image::DSDD); + break; + case 1: + if (heads == 1) + return false; // single side HD ? + image->set_variant(floppy_image::DSHD); + break; + case 2: + if (heads == 1) + return false; // single side ED ? + image->set_variant(floppy_image::DSED); + default: + return false; + } + + static const int rates[3] = { 250000, 300000, 500000 }; + int rate = density >= 3 ? 500000 : rates[density]; + int rpm = form_factor == floppy_image::FF_8 || (form_factor == floppy_image::FF_525 && rate >= 300000) ? 360 : 300; + int base_cell_count = rate*60/rpm; + + int cqm_size = io_generic_size(io); + dynamic_buffer cqmbuf(cqm_size); + io_generic_read(io, cqmbuf, 0, cqm_size); + + // decode the RLE data + for (int s = 0, pos = CQM_HEADER_SIZE + comment_size; pos < cqm_size; ) + { + INT16 len = (cqmbuf[pos + 1] << 8) | cqmbuf[pos]; + pos += 2; + if(len < 0) + { + len = -len; + memset(&imagebuf[s], cqmbuf[pos], len); + pos++; + } + else + { + memcpy(&imagebuf[s], &cqmbuf[pos], len); + pos += len; + } + + s += len; + } + + int ssize; + for(ssize=0; (128 << ssize) < sector_size; ssize++) + ; + + desc_pc_sector sects[256]; + for(int track = 0, pos = 0; track < tracks; track++) + for(int head = 0; head < heads; head++) + { + for(int sector = 0; sector < sector_per_track; sector++) + { + sects[sector].track = track; + sects[sector].head = head; + sects[sector].sector = sector_base + sector; + sects[sector].size = ssize; + sects[sector].deleted = false; + sects[sector].bad_crc = false; + sects[sector].actual_size = sector_size; + sects[sector].data = &imagebuf[pos]; + pos += sector_size; + } + + build_pc_track_mfm(track, head, image, base_cell_count*2, sector_per_track, sects, calc_default_pc_gap3_size(form_factor, sector_size)); + } + + return true; +} + +bool cqm_format::save(io_generic *io, floppy_image *image) +{ + return false; +} + +bool cqm_format::supports_save() const +{ + return false; +} + +const floppy_format_type FLOPPY_CQM_FORMAT = &floppy_image_format_creator; diff --git a/src/lib/formats/cqm_dsk.h b/src/lib/formats/cqm_dsk.h new file mode 100644 index 00000000000..9cb436a3bc3 --- /dev/null +++ b/src/lib/formats/cqm_dsk.h @@ -0,0 +1,31 @@ +/********************************************************************* + + formats/cqm_dsk.h + + CopyQM disk images + +*********************************************************************/ + +#ifndef CQM_DSK_H_ +#define CQM_DSK_H_ + +#include "flopimg.h" + +class cqm_format : public floppy_image_format_t +{ +public: + cqm_format(); + + virtual int identify(io_generic *io, UINT32 form_factor); + virtual bool load(io_generic *io, UINT32 form_factor, floppy_image *image); + virtual bool save(io_generic *io, floppy_image *image); + + virtual const char *name() const; + virtual const char *description() const; + virtual const char *extensions() const; + virtual bool supports_save() const; +}; + +extern const floppy_format_type FLOPPY_CQM_FORMAT; + +#endif /* CQM_DSK_H_ */ diff --git a/src/mess/drivers/dmv.c b/src/mess/drivers/dmv.c index 791b14a9690..fcbae630dcf 100644 --- a/src/mess/drivers/dmv.c +++ b/src/mess/drivers/dmv.c @@ -714,6 +714,8 @@ static MACHINE_CONFIG_START( dmv, dmv_state ) MCFG_DMVCART_SLOT_OUT_THOLD_CB(WRITELINE(dmv_state, thold7_w)) MCFG_DMVCART_SLOT_OUT_IRQ_CB(WRITELINE(dmv_state, busint_w)) + MCFG_SOFTWARE_LIST_ADD("flop_list", "dmv") + MACHINE_CONFIG_END /* ROM definition */ diff --git a/src/mess/tools/floptool/main.c b/src/mess/tools/floptool/main.c index 93716dcdc67..211f54edb8f 100644 --- a/src/mess/tools/floptool/main.c +++ b/src/mess/tools/floptool/main.c @@ -35,6 +35,7 @@ #include "formats/d88_dsk.h" #include "formats/imd_dsk.h" #include "formats/td0_dsk.h" +#include "formats/cqm_dsk.h" #include "formats/pc_dsk.h" #include "formats/naslite_dsk.h" @@ -62,6 +63,7 @@ static floppy_format_type floppy_formats[] = { FLOPPY_D88_FORMAT, FLOPPY_IMD_FORMAT, FLOPPY_TD0_FORMAT, + FLOPPY_CQM_FORMAT, FLOPPY_PC_FORMAT, FLOPPY_NASLITE_FORMAT,