(MESS) Added sector image format for the Commodore 8280 8" floppy drive. [Curt Coder]

This commit is contained in:
Curt Coder 2015-04-20 22:34:31 +03:00
parent 126fcf2e93
commit 643d5fafe7
6 changed files with 133 additions and 33 deletions

View File

@ -157,6 +157,8 @@ project "formats"
MAME_DIR .. "src/lib/formats/bw2_dsk.h",
MAME_DIR .. "src/lib/formats/bw12_dsk.c",
MAME_DIR .. "src/lib/formats/bw12_dsk.h",
MAME_DIR .. "src/lib/formats/c8280_dsk.c",
MAME_DIR .. "src/lib/formats/c8280_dsk.h",
MAME_DIR .. "src/lib/formats/cbm_crt.c",
MAME_DIR .. "src/lib/formats/cbm_crt.h",
MAME_DIR .. "src/lib/formats/cbm_tap.c",

View File

@ -9,16 +9,6 @@
**********************************************************************/
/*
TODO:
- format
wd1772: track description 80x4e 12x00 3xf6 fc 50x4e 12x00 3xf5 fe 2x00 2x01 f7 22x4e 12x00 3xf5 fb 256xaa f7 54x4e
*/
#include "c8280.h"
@ -159,6 +149,7 @@ WRITE8_MEMBER( c8280_device::dio_w )
m_bus->dio_w(this, data);
}
//-------------------------------------------------
// riot6532 1
//-------------------------------------------------
@ -291,6 +282,10 @@ static SLOT_INTERFACE_START( c8280_floppies )
SLOT_INTERFACE( "8dsdd", FLOPPY_8_DSDD )
SLOT_INTERFACE_END
FLOPPY_FORMATS_MEMBER( c8280_device::floppy_formats )
FLOPPY_C8280_FORMAT
FLOPPY_FORMATS_END
//-------------------------------------------------
// MACHINE_CONFIG_FRAGMENT( c8280 )
@ -314,11 +309,11 @@ static MACHINE_CONFIG_FRAGMENT( c8280 )
MCFG_CPU_ADD(M6502_FDC_TAG, M6502, XTAL_12MHz/8)
MCFG_CPU_PROGRAM_MAP(c8280_fdc_mem)
MCFG_FD1797x_ADD(WD1797_TAG, XTAL_12MHz/6) // clock?
MCFG_FD1797x_ADD(WD1797_TAG, XTAL_12MHz/6)
MCFG_WD_FDC_INTRQ_CALLBACK(INPUTLINE(M6502_FDC_TAG, M6502_IRQ_LINE))
MCFG_WD_FDC_DRQ_CALLBACK(INPUTLINE(M6502_FDC_TAG, M6502_SET_OVERFLOW))
MCFG_FLOPPY_DRIVE_ADD(WD1797_TAG":0", c8280_floppies, "8dsdd", floppy_image_device::default_floppy_formats)
MCFG_FLOPPY_DRIVE_ADD(WD1797_TAG":1", c8280_floppies, "8dsdd", floppy_image_device::default_floppy_formats)
MCFG_FLOPPY_DRIVE_ADD(WD1797_TAG ":0", c8280_floppies, "8dsdd", c8280_device::floppy_formats)
MCFG_FLOPPY_DRIVE_ADD(WD1797_TAG ":1", c8280_floppies, "8dsdd", c8280_device::floppy_formats)
MACHINE_CONFIG_END
@ -390,20 +385,20 @@ inline void c8280_device::update_ieee_signals()
// c8280_device - constructor
//-------------------------------------------------
c8280_device::c8280_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock)
: device_t(mconfig, C8280, "C8280", tag, owner, clock, "c8280", __FILE__),
device_ieee488_interface(mconfig, *this),
m_maincpu(*this, M6502_DOS_TAG),
m_fdccpu(*this, M6502_FDC_TAG),
m_riot0(*this, M6532_0_TAG),
m_riot1(*this, M6532_1_TAG),
m_fdc(*this, WD1797_TAG),
m_floppy0(*this, WD1797_TAG":0"),
m_floppy1(*this, WD1797_TAG":1"),
m_address(*this, "ADDRESS"),
m_rfdo(1),
m_daco(1),
m_atna(1)
c8280_device::c8280_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock) :
device_t(mconfig, C8280, "C8280", tag, owner, clock, "c8280", __FILE__),
device_ieee488_interface(mconfig, *this),
m_maincpu(*this, M6502_DOS_TAG),
m_fdccpu(*this, M6502_FDC_TAG),
m_riot0(*this, M6532_0_TAG),
m_riot1(*this, M6532_1_TAG),
m_fdc(*this, WD1797_TAG),
m_floppy0(*this, WD1797_TAG ":0"),
m_floppy1(*this, WD1797_TAG ":1"),
m_address(*this, "ADDRESS"),
m_rfdo(1),
m_daco(1),
m_atna(1)
{
}
@ -418,6 +413,7 @@ void c8280_device::device_start()
save_item(NAME(m_rfdo));
save_item(NAME(m_daco));
save_item(NAME(m_atna));
save_item(NAME(m_ifc));
save_item(NAME(m_fk5));
}
@ -481,12 +477,12 @@ READ8_MEMBER( c8280_device::fk5_r )
bit description
0 DS1
1 DS2
2 _DDEN
0
1
2
3 DCHG
4 TSID
5 MOTOR ENABLE
5
6 0
7 0

View File

@ -14,10 +14,10 @@
#ifndef __C8280__
#define __C8280__
#include "emu.h"
#include "ieee488.h"
#include "cpu/m6502/m6502.h"
#include "formats/c8280_dsk.h"
#include "machine/6532riot.h"
#include "machine/wd_fdc.h"
@ -30,7 +30,7 @@
// ======================> c8280_device
class c8280_device : public device_t,
public device_ieee488_interface
public device_ieee488_interface
{
public:
// construction/destruction
@ -51,6 +51,8 @@ public:
DECLARE_READ8_MEMBER( fk5_r );
DECLARE_WRITE8_MEMBER( fk5_w );
DECLARE_FLOPPY_FORMATS( floppy_formats );
protected:
// device-level overrides
virtual void device_start();

View File

@ -0,0 +1,69 @@
// license:BSD-3-Clause
// copyright-holders:Curt Coder
/*********************************************************************
formats/c8280_dsk.c
Commodore 8280 disk image format
*********************************************************************/
#include "formats/c8280_dsk.h"
c8280_format::c8280_format() : wd177x_format(formats)
{
}
const char *c8280_format::name() const
{
return "c8280";
}
const char *c8280_format::description() const
{
return "Commodore 8280 disk image";
}
const char *c8280_format::extensions() const
{
return "dsk";
}
const c8280_format::format c8280_format::formats[] = {
// 80x4e 12x00 3xf6 fc
// 50x4e 12x00 3xf5 fe 2x00 01 01 f7 22x4e 12x00 3xf5 fb 256xaa f7
// 54x4e 12x00 3xf5 fe 2x00 02 01 f7 22x4e 12x00 3xf5 fb 256xaa f7
// 54x4e 12x00 3xf5 fe 2x00 03 01 f7 22x4e 12x00 3xf5 fb 256xaa f7
// 54x4e 12x00 3xf5 fe 2x00 04 01 f7 22x4e 12x00 3xf5 fb 256xaa f7
// 54x4e 12x00 3xf5 fe 2x00 05 01 f7 22x4e 12x00 3xf5 fb 256xaa f7
// 54x4e 12x00 3xf5 fe 2x00 06 01 f7 22x4e 12x00 3xf5 fb 256xaa f7
// 54x4e 12x00 3xf5 fe 2x00 07 01 f7 22x4e 12x00 3xf5 fb 256xaa f7
// 54x4e 12x00 3xf5 fe 2x00 08 01 f7 22x4e 12x00 3xf5 fb 256xaa f7
// 54x4e 12x00 3xf5 fe 2x00 09 01 f7 22x4e 12x00 3xf5 fb 256xaa f7
// 54x4e 12x00 3xf5 fe 2x00 0a 01 f7 22x4e 12x00 3xf5 fb 256xaa f7
// 54x4e 12x00 3xf5 fe 2x00 0b 01 f7 22x4e 12x00 3xf5 fb 256xaa f7
// 54x4e 12x00 3xf5 fe 2x00 0c 01 f7 22x4e 12x00 3xf5 fb 256xaa f7
// 54x4e 12x00 3xf5 fe 2x00 0d 01 f7 22x4e 12x00 3xf5 fb 256xaa f7
// 54x4e 12x00 3xf5 fe 2x00 0e 01 f7 22x4e 12x00 3xf5 fb 256xaa f7
// 54x4e 12x00 3xf5 fe 2x00 0f 01 f7 22x4e 12x00 3xf5 fb 256xaa f7
// 54x4e 12x00 3xf5 fe 2x00 10 01 f7 22x4e 12x00 3xf5 fb 256xaa f7
// 54x4e 12x00 3xf5 fe 2x00 11 01 f7 22x4e 12x00 3xf5 fb 256xaa f7
// 54x4e 12x00 3xf5 fe 2x00 12 01 f7 22x4e 12x00 3xf5 fb 256xaa f7
// 54x4e 12x00 3xf5 fe 2x00 13 01 f7 22x4e 12x00 3xf5 fb 256xaa f7
// 54x4e 12x00 3xf5 fe 2x00 14 01 f7 22x4e 12x00 3xf5 fb 256xaa f7
// 54x4e 12x00 3xf5 fe 2x00 15 01 f7 22x4e 12x00 3xf5 fb 256xaa f7
// 54x4e 12x00 3xf5 fe 2x00 16 01 f7 22x4e 12x00 3xf5 fb 256xaa f7
// 54x4e 12x00 3xf5 fe 2x00 17 01 f7 22x4e 12x00 3xf5 fb 256xaa f7
// 54x4e 12x00 3xf5 fe 2x00 18 01 f7 22x4e 12x00 3xf5 fb 256xaa f7
// 54x4e 12x00 3xf5 fe 2x00 19 01 f7 22x4e 12x00 3xf5 fb 256xaa f7
// 54x4e 12x00 3xf5 fe 2x00 1a 01 f7 22x4e 12x00 3xf5 fb 256xaa f7
// 653x4e
{
floppy_image::FF_8, floppy_image::DSDD, floppy_image::MFM,
1200, 26, 77, 2, 256, {}, 1, {}, 50, 22, 54
},
{}
};
const floppy_format_type FLOPPY_C8280_FORMAT = &floppy_image_format_creator<c8280_format>;

View File

@ -0,0 +1,30 @@
// license:BSD-3-Clause
// copyright-holders:Curt Coder
/*********************************************************************
formats/c8280_dsk.h
Commodore 8280 disk image format
*********************************************************************/
#ifndef C8280_DSK_H_
#define C8280_DSK_H_
#include "wd177x_dsk.h"
class c8280_format : public wd177x_format {
public:
c8280_format();
virtual const char *name() const;
virtual const char *description() const;
virtual const char *extensions() const;
private:
static const format formats[];
};
extern const floppy_format_type FLOPPY_C8280_FORMAT;
#endif

View File

@ -471,6 +471,7 @@ protected:
C1541 tr 18-24 3.50 300 3500
C1541 tr 25-30 3.75 300 3750
C1541 tr 31+ 4.00 300 4000
8" DD 1 360 1200
5.25" SD 4 300 4000
5.25" DD 2 300 2000
5.25" HD 1 360 1200