Skip to content

Commit

Permalink
CMD FD: Support D1M, D2M, D4M image types
Browse files Browse the repository at this point in the history
  • Loading branch information
keirf committed Aug 20, 2024
1 parent 54832e8 commit f3fa2dc
Show file tree
Hide file tree
Showing 3 changed files with 72 additions and 0 deletions.
57 changes: 57 additions & 0 deletions src/greaseweazle/data/diskdefs.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -475,6 +475,63 @@ disk commodore.1581
end
end

disk commodore.cmd.fd2000.dd
cyls = 81
heads = 2
tracks 0-80.0 ibm.mfm
secs = 10
bps = 512
gap3 = 30
rate = 250
h = 1
end
tracks 0-80.1 ibm.mfm
secs = 10
bps = 512
gap3 = 30
rate = 250
h = 0
end
end

disk commodore.cmd.fd2000.hd
cyls = 81
heads = 2
tracks 0-80.0 ibm.mfm
secs = 10
bps = 1024
gap3 = 116
rate = 500
h = 1
end
tracks 0-80.1 ibm.mfm
secs = 10
bps = 1024
gap3 = 116
rate = 500
h = 0
end
end

disk commodore.cmd.fd4000.ed
cyls = 81
heads = 2
tracks 0-80.0 ibm.mfm
secs = 20
bps = 1024
gap3 = 116
rate = 1000
h = 1
end
tracks 0-80.1 ibm.mfm
secs = 20
bps = 1024
gap3 = 116
rate = 1000
h = 0
end
end

disk dec.rx01
cyls = 77
heads = 1
Expand Down
12 changes: 12 additions & 0 deletions src/greaseweazle/image/d81.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,18 @@ class D81(IMG):
default_format = 'commodore.1581'
sides_swapped = True

class D1M(IMG):
default_format = 'commodore.cmd.fd2000.dd'
sides_swapped = True

class D2M(IMG):
default_format = 'commodore.cmd.fd2000.hd'
sides_swapped = True

class D4M(IMG):
default_format = 'commodore.cmd.fd4000.ed'
sides_swapped = True

# Local variables:
# python-indent: 4
# End:
3 changes: 3 additions & 0 deletions src/greaseweazle/tools/util.py
Original file line number Diff line number Diff line change
Expand Up @@ -268,6 +268,9 @@ def split_opts(seq):
'.adm': ('ADM','acorn'),
'.adl': ('ADL','acorn'),
'.ctr': ('CTRaw','caps'),
'.d1m': ('D1M','d81'),
'.d2m': ('D2M','d81'),
'.d4m': ('D4M','d81'),
'.d64': 'D64',
'.d71': ('D71','d64'),
'.d81': 'D81',
Expand Down

0 comments on commit f3fa2dc

Please sign in to comment.