Consolidate all the IBM formats together.

This commit is contained in:
dg
2023-05-05 21:37:49 +00:00
parent c36662205b
commit 510b530551
11 changed files with 277 additions and 358 deletions

View File

@@ -196,14 +196,14 @@ $(call do-encodedecodetest,cmd_fd2000)
$(call do-encodedecodetest,hplif,,--264)
$(call do-encodedecodetest,hplif,,--616)
$(call do-encodedecodetest,hplif,,--770)
$(call do-encodedecodetest,ibm1200)
$(call do-encodedecodetest,ibm1232)
$(call do-encodedecodetest,ibm1440)
$(call do-encodedecodetest,ibm180)
$(call do-encodedecodetest,ibm160)
$(call do-encodedecodetest,ibm320)
$(call do-encodedecodetest,ibm360)
$(call do-encodedecodetest,ibm720)
$(call do-encodedecodetest,ibm,,--1200)
$(call do-encodedecodetest,ibm,,--1232)
$(call do-encodedecodetest,ibm,,--1440)
$(call do-encodedecodetest,ibm,,--180)
$(call do-encodedecodetest,ibm,,--160)
$(call do-encodedecodetest,ibm,,--320)
$(call do-encodedecodetest,ibm,,--360)
$(call do-encodedecodetest,ibm,,--720)
$(call do-encodedecodetest,mac400,scripts/mac400_test.textpb)
$(call do-encodedecodetest,mac800,scripts/mac800_test.textpb)
$(call do-encodedecodetest,n88basic)

View File

@@ -38,15 +38,16 @@ Reading disks
Just do:
fluxengine read `<format>`
fluxengine read ibm `<format>`
...and you'll end up with a `<format>.img` file. This should work on most PC
disks (including FM 360kB disks, 3.5" 1440kB disks, 5.25" 1200kB disks, etc.)
The size of the disk image will vary depending on the format.
...and you'll end up with an `ibm.img` file. You'll need to specify which
format to use; this can be one of `--160`, `--180`, `--320`, `--360`, `--720`,
`--1200`, `--1232` or `--1400` depending. The size of the disk image will vary
depending on the format.
The common PC formats are `ibm720` and `ibm1440`, but there are _many_ others,
The common PC formats are `--720` and `--1440`, but there are _many_ others,
and there's too many configuration options to usefully list. Use `fluxengine
write` to list all formats, and try `fluxengine write ibm1440 --config` to see
write` to list all formats, and try `fluxengine write ibm --1440 --config` to see
a sample configuration.
Configuration options you'll want include:
@@ -84,16 +85,13 @@ makes things slightly awkward. Preconfigured profiles are available.
The syntax is:
fluxengine write <format> -i input.img <options>
fluxengine write ibm <format> -i input.img <options>
The common PC formats are `ibm720` and `ibm1440`, but there are _many_ others,
and there's too many configuration options to usefully list. Use `fluxengine
write` to list all formats, and try `fluxengine write ibm1440 --config` to see
a sample configuration.
See above for the formats.
Some image formats, such as DIM, specify the image format, For these you can
specify the `ibm` format and FluxEngine will automatically determine the
correct format to use.
specify the `--auto` format (which is the default) and FluxEngine will
automatically determine the correct format to use.
Mixed-format disks
------------------
@@ -131,11 +129,7 @@ drives, feature "tri-mode" support which in addition to normal 300rpm modes,
can change their speed to read and write 360rpm DD and HD disks.
Neither the FluxEngine or Greaseweazle hardware can currently command a
tri-mode drive to spin at 360rpm, however an older 360rpm-only drive will work
to read these formats.
tri-mode drive to spin at 360rpm. However on both devices the FluxEngine
software is capable of both reading and writing 300rpm disks at 360rpm and vice
versa, so it shouldn't matter.
Alternately, the FluxEngine software can rescale the flux pulses to enable
reading and writing these formats with a plain 300rpm drive. To do this,
specify the following two additional options:
--flux_source.rescale=1.2 --flux_sink.rescale=1.2

View File

@@ -22,14 +22,6 @@ FORMATS = \
fb100 \
hplif \
ibm \
ibm1200 \
ibm1232 \
ibm1440 \
ibm180 \
ibm160 \
ibm360 \
ibm320 \
ibm720 \
icl30 \
mac400 \
mac800 \

View File

@@ -1,4 +1,9 @@
comment: 'PC 3.5"/5.25" autodetect double sided format'
comment: 'Generic PC 3.5"/5.25" family'
image_reader {
filename: "ibm.img"
type: IMG
}
image_writer {
filename: "ibm.img"
@@ -9,9 +14,255 @@ decoder {
ibm {}
}
heads {
start: 0
end: 1
filesystem {
type: FATFS
}
tpi: 96
option_group {
comment: "Format variant"
option {
name: "auto"
comment: 'try to autodetect the format (unreliable)'
set_by_default: true
config {}
}
option {
name: "160"
comment: '160kB 5.25" 40-track 8-sector SSDD'
config {
layout {
tracks: 40
sides: 1
layoutdata {
sector_size: 512
physical {
start_sector: 1
count: 8
}
}
}
encoder {
ibm {
trackdata {
target_rotational_period_ms: 167
target_clock_period_us: 3.333
}
}
}
tpi: 48
}
}
option {
name: "180"
comment: '180kB 5.25" 40-track 9-sector SSDD'
config {
layout {
tracks: 40
sides: 1
layoutdata {
sector_size: 512
physical {
start_sector: 1
count: 9
}
}
}
encoder {
ibm {
trackdata {
target_rotational_period_ms: 167
target_clock_period_us: 3.333
}
}
}
tpi: 48
}
}
option {
name: "320"
comment: '320kB 5.25" 40-track 8-sector DSDD'
config {
layout {
tracks: 40
sides: 2
layoutdata {
sector_size: 512
physical {
start_sector: 1
count: 8
}
}
}
encoder {
ibm {
trackdata {
target_rotational_period_ms: 167
target_clock_period_us: 3.333
}
}
}
tpi: 48
}
}
option {
name: "360"
comment: '360kB 5.25" 40-track 9-sector DSDD'
config {
layout {
tracks: 40
sides: 2
layoutdata {
sector_size: 512
physical {
start_sector: 1
count: 9
}
}
}
encoder {
ibm {
trackdata {
target_rotational_period_ms: 167
target_clock_period_us: 3.333
}
}
}
tpi: 48
}
}
option {
name: "720"
comment: '720kB 5.25"/3.5" 80-track 9-sector DSDD'
config {
layout {
tracks: 80
sides: 2
layoutdata {
sector_size: 512
physical {
start_sector: 1
count: 9
}
}
}
encoder {
ibm {
trackdata {
# This also works on 166ms drives (producing a physical clock of
# 3.33us).
target_rotational_period_ms: 200
target_clock_period_us: 4
}
}
}
}
}
option {
name: "1200"
comment: '1200kB 5.25" 80-track 15-sector DSHD'
config {
layout {
tracks: 80
sides: 2
layoutdata {
sector_size: 512
physical {
start_sector: 1
count: 15
}
}
}
encoder {
ibm {
trackdata {
target_rotational_period_ms: 167
target_clock_period_us: 2
}
}
}
}
}
option {
name: "1232"
comment: '1232kB 5.25"/3.5" 77-track 8-sector DSHD'
config {
layout {
tracks: 77
sides: 2
layoutdata {
sector_size: 1024
physical {
start_sector: 1
count: 8
}
}
}
encoder {
ibm {
trackdata {
target_rotational_period_ms: 167
target_clock_period_us: 2
}
}
}
}
}
option {
name: "1440"
comment: '1440kB 3.5" 80-track 18-sector DSHD'
config {
layout {
tracks: 80
sides: 2
layoutdata {
sector_size: 512
physical {
start_sector: 1
count: 18
}
}
}
encoder {
ibm {
trackdata {
target_rotational_period_ms: 200
target_clock_period_us: 2
}
}
}
}
}
}

View File

@@ -1,46 +0,0 @@
comment: 'PC 1200kB 5.25" 80-track 15-sector DSHD'
image_reader {
filename: "ibm1200.img"
type: IMG
}
image_writer {
filename: "ibm1200.img"
type: IMG
}
layout {
tracks: 80
sides: 2
layoutdata {
sector_size: 512
physical {
start_sector: 1
count: 15
}
}
}
encoder {
ibm {
trackdata {
target_rotational_period_ms: 167
target_clock_period_us: 2
}
}
}
decoder {
ibm {}
}
drive {
high_density: true
}
filesystem {
type: FATFS
}

View File

@@ -1,41 +0,0 @@
comment: 'PC 1440kB 3.5" 80-track 18-sector DSHD'
image_reader {
filename: "ibm1440.img"
type: IMG
}
image_writer {
filename: "ibm1440.img"
type: IMG
}
layout {
tracks: 80
sides: 2
layoutdata {
sector_size: 512
physical {
start_sector: 1
count: 18
}
}
}
encoder {
ibm {
trackdata {
target_rotational_period_ms: 200
target_clock_period_us: 2
}
}
}
decoder {
ibm {}
}
filesystem {
type: FATFS
}

View File

@@ -1,48 +0,0 @@
comment: 'PC 160kB 5.25" 40-track 8-sector SSDD'
image_reader {
filename: "ibm160.img"
type: IMG
}
image_writer {
filename: "ibm160.img"
type: IMG
}
layout {
tracks: 40
sides: 1
layoutdata {
sector_size: 512
physical {
start_sector: 1
count: 8
}
}
}
encoder {
ibm {
trackdata {
target_rotational_period_ms: 167
target_clock_period_us: 3.333
}
}
}
decoder {
ibm {}
}
drive {
high_density: false
}
tpi: 48
filesystem {
type: FATFS
}

View File

@@ -1,48 +0,0 @@
comment: 'PC 180kB 5.25" 40-track 9-sector SSDD'
image_reader {
filename: "ibm180.img"
type: IMG
}
image_writer {
filename: "ibm180.img"
type: IMG
}
layout {
tracks: 40
sides: 1
layoutdata {
sector_size: 512
physical {
start_sector: 1
count: 9
}
}
}
encoder {
ibm {
trackdata {
target_rotational_period_ms: 167
target_clock_period_us: 3.333
}
}
}
decoder {
ibm {}
}
drive {
high_density: false
}
tpi: 48
filesystem {
type: FATFS
}

View File

@@ -1,44 +0,0 @@
comment: 'PC 320kB 5.25" 40-track 8-sector DSDD'
image_reader {
filename: "ibm320.img"
type: IMG
}
image_writer {
filename: "ibm320.img"
type: IMG
}
layout {
tracks: 40
sides: 2
layoutdata {
sector_size: 512
physical {
start_sector: 1
count: 8
}
}
}
encoder {
ibm {
trackdata {
target_rotational_period_ms: 167
target_clock_period_us: 3.333
}
}
}
decoder {
ibm {}
}
tpi: 48
filesystem {
type: FATFS
}

View File

@@ -1,44 +0,0 @@
comment: 'PC 360kB 5.25" 40-track 9-sector DSDD'
image_reader {
filename: "ibm360.img"
type: IMG
}
image_writer {
filename: "ibm360.img"
type: IMG
}
layout {
tracks: 40
sides: 2
layoutdata {
sector_size: 512
physical {
start_sector: 1
count: 9
}
}
}
encoder {
ibm {
trackdata {
target_rotational_period_ms: 167
target_clock_period_us: 3.333
}
}
}
decoder {
ibm {}
}
tpi: 48
filesystem {
type: FATFS
}

View File

@@ -1,47 +0,0 @@
comment: 'PC 720kB 5.25"/3.5" 80-track 9-sector DSDD'
image_reader {
filename: "ibm720.img"
type: IMG
}
image_writer {
filename: "ibm720.img"
type: IMG
}
layout {
tracks: 80
sides: 2
layoutdata {
sector_size: 512
physical {
start_sector: 1
count: 9
}
}
}
encoder {
ibm {
trackdata {
# This also works on 166ms drives (producing a physical clock of
# 3.33us).
target_rotational_period_ms: 200
target_clock_period_us: 4
}
}
}
decoder {
ibm {}
}
drive {
high_density: false
}
filesystem {
type: FATFS
}