Skip to content

Commit fc04c56

Browse files
tdaedekeirf
authored andcommitted
Add support for the Sharp X1's 2D format.
Almost the same as PC88/98 2D, but 256 byte sectors.
1 parent af2ebeb commit fc04c56

4 files changed

Lines changed: 31 additions & 1 deletion

File tree

src/greaseweazle/data/diskdefs.cfg

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,7 @@ import pc98. "diskdefs_pc98.cfg"
7272
import raw. "diskdefs_raw.cfg"
7373
import sci. "diskdefs_sci.cfg"
7474
import sega. "diskdefs_sega.cfg"
75+
import sharp. "diskdefs_sharp.cfg"
7576
import thomson. "diskdefs_thomson.cfg"
7677
import tsc. "diskdefs_tsc.cfg"
7778
import xerox. "diskdefs_xerox.cfg"
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
# prefix: sharp.
2+
3+
disk 2d
4+
cyls = 40
5+
heads = 2
6+
tracks * ibm.mfm
7+
secs = 16
8+
bps = 256
9+
gap3 = 57
10+
rate = 250
11+
rpm = 300
12+
end
13+
end

src/greaseweazle/image/sharp2d.py

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
# greaseweazle/image/sharp2d.py
2+
#
3+
# Written & released by Keir Fraser <keir.xen@gmail.com>
4+
#
5+
# This is free and unencumbered software released into the public domain.
6+
# See the file COPYING for more details, or visit <http://unlicense.org>.
7+
8+
from greaseweazle.image.img import IMG
9+
10+
class SHARP2D(IMG):
11+
default_format = 'sharp.2d'
12+
13+
# Local variables:
14+
# python-indent: 4
15+
# End:

src/greaseweazle/tools/util.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -270,7 +270,8 @@ def split_opts(seq):
270270

271271

272272
image_types = OrderedDict(
273-
{ '.a2r': 'A2R',
273+
{ '.2d': 'SHARP2D',
274+
'.a2r': 'A2R',
274275
'.adf': 'ADF',
275276
'.ads': ('ADS','acorn'),
276277
'.adm': ('ADM','acorn'),

0 commit comments

Comments
 (0)