-
Hi all, I'm trying to convert a floppy/ scp to img using gw tools 1.16.2. The floppy format is basically ibm.1440 with all sector ids starting with id=1. Only sector 1/18 of track 36.0 starts with id=0 instead of id=1. The next sector again is id=2. So in track36.0 sector id=1 is missing. It's a copy protection. Besides that this sector is a perfectly fine MFM sector. I'm trying to come up with a disk definition for this format, but it seems that non-consecutive sector ids are not supported in the diskdefs. Would it be an interesting feature? Do you have any suggestion what the best way forward could be? |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 2 replies
-
It's not particularly obvious that IMG is a good container for non-uniform disk definitions like this. I suppose this one is a simple swap of id=1 to id=0 at least, but you can imagine much more twisted arrangements. Anyway, here's a trick for you:
Or, a better format which includes metadata about sector numbering and so on:
Though of course it's not better if your other tools/emulators don't understand IMD. :) Another format, somewhat CPC-specific but used on other systems these days too, is EDSK (file suffix |
Beta Was this translation helpful? Give feedback.
-
I probably will support non-uniform sector numbering, though I'll have to think about how this ought to interact with interleave and skew settings. |
Beta Was this translation helpful? Give feedback.
-
Mh, indeeed in this case the goal/ result would be an img. In this particular case I just need the raw data content, all the info related to the medium can/ should be stripped. It might be a nice feature for diskdefs. I was thinking maybe "id" could also allow an array? Or an option to just ignore the original sector numbers alltogether and let gw count the sectors in the order it encounters them? But I agree that it is probably a very rare use case and not worth adding the complexity. For future reference: My current approach works, but is a bit cumbersome. One can easily modify diskdefs to make track 36.0 contain 19 sectors starting at id=0. This enables one in a first step to get all the data off the disk. The resulting img then contains an additional sector 36.0#1 which is marked corrupted (because it does not exist). This can be fixed with dd. disk ibm.1440.mod
cyls = 80
heads = 2
tracks 36.0 ibm.mfm
id = 0
secs = 19
bps = 512
gap3 = 84
rate = 500
end
tracks * ibm.mfm
secs = 18
bps = 512
gap3 = 84
rate = 500
end
end
|
Beta Was this translation helpful? Give feedback.
It's not particularly obvious that IMG is a good container for non-uniform disk definitions like this. I suppose this one is a simple swap of id=1 to id=0 at least, but you can imagine much more twisted arrangements.
Anyway, here's a trick for you:
Or, a better format which includes metadata about sector numbering and so on:
Though of course it's not better if your other tools/emulators don't understand IMD. :)
Another format, somewhat CPC-specific but used on other systems these days too, is EDSK (file suffix
.edsk
)