-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathChangeLog
801 lines (595 loc) · 35.1 KB
/
ChangeLog
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
4.10.1 -- Sat May 4 19:04:22 UTC 2024 -- Tim Mann, Quentin Barnes
* Fix indefinite looping while guessing head stepping rate when
encountering unusually formatted disks, often from copy protection.
* Fix bug with wraparound detection when the duplicate ID block gets
cut off by the DMK buffer filling up. The fix is to stop decoding
when the buffer fills up, so that we don't detect such a header in
the first place.
4.10.0 -- Mon Mar 11 19:30:33 UTC 2024 -- Tim Mann, Quentin Barnes
* Add -S option. This option allows the user to specify a minimum
number of sectors per track and side. If that minimum is not
reached during a read, it'll trigger a retry. See the man page
for more details.
* Extend the -x and -X option argument syntax when specifying a track
range to also allow giving sides.
* Add partial support for RX02 in dmk2jv3.
4.9.3 -- Sun Nov 27 20:04:04 UTC 2022 -- Tim Mann
* Add QUIRK_MFM_CLOCK. This quirk was needed to read some older UDOS
disks with clock bits set in certain places that violate the MFM
clocking rules. The most frequent violation seen on a sample disk
was that in a sequence of bytes with data value ff ff ff..., the
clocking pattern could be 00 88 88... instead of 00 00 00... This
results in flux transitions in adjacent bit cells, which is normally
illegal in MFM. The disks were probably from UDOS 1526 V.3, or
possibly V.2.
4.9.2 -- Sun Sep 18 23:11:36 UTC 2022 -- Tim Mann
* Make the -v2 and -v3 output of dmk2cw more readable.
* Check that numeric option arguments are valid numbers.
* Make dmk2cw warn if not all sector data fits on the physical track.
To help support the feature (and because it generally seems useful),
cw2dmk now records the quirk flags in the previously unused/reserved
byte 5 of the DMK file header.
4.9.1 -- Mon May 23 15:56:42 UTC 2022 -- Tim Mann
* Add -T step_time,settling_time feature to both cw2dmk and dmk2cw.
* Log all Catweasel samples when at verbosity level 7, instead of
stopping when the DMK buffer is full. (This change was actually
made in 4.9.0, but it had a bug that is now fixed.)
4.9.0 -- Sat Apr 30 17:07:57 UTC 2022 -- Tim Mann, Quentin Barnes
* Catch errors when writing to files. Report and exit when errors
are seen.
* Add -X min_retry feature to cw2dmk, accepting the same syntax for
min_retry as for -x max_retry.
* Add QUIRK_IAM to -q option in cw2dmk.
* Various minor cleanup of code and the cw2dmk usage message.
* Add -R (replay) feature to cw2dmk.
* Add QUIRK_EXTRA_DATA to -q option in cw2dmk.
4.8.1 -- Sat Dec 11 01:12:14 UTC 2021 -- Quentin Barnes
* Correct a substantial performance regression when doing high
level writes to the log file.
4.8.0 -- Tue Dec 7 20:52:50 UTC 2021 -- Quentin Barnes
* This release is virtually all of Tim Mann's work, and most of
those changes are for adding UDOS support.
* Add -q (quirk) option for extending cw2dmk to better support of
reading UDOS formatted disks. UDOS disks may have a modified
ID premark and after each data sector may include an extra 4 data
bytes and a possible 2 bytes of CRC. For details, see the cw2dmk
man page's description of the -q option.
The new -q option hasn't been tested with the -j option. Bugs
may show up. If found, please report them.
* Add -a rate_adj and -e dither options to dmk2cw.
4.7.1 -- Wed Oct 20 20:00:21 UTC 2021 -- Quentin Barnes
* Add feature to "-x" option to allow per-track retry counts.
(E.g. "-x 40,0:4-12" sets retries for all tracks to 40 except
disable retries for tracks 4 through 12.) See cw2dmk man
page for further information.
* Correct off-by-one problem with retry counts.
4.7.0 -- Mon Apr 12 23:25:25 UTC 2021 -- Quentin Barnes
* Deprecate cw2dmk's -b option introduced in 4.6.0. It had too
many shortcomings with CP/M disks. Replaced with -C.
* Add -C option to cw2dmk for controlling detection of incompatibly
formatted sides of a floppy disk. If side 1 is formatted with
512-byte sectors and side 0 is formatted with any other sector
size, it'll assume side 1 was factory-formatted and skip it.
Detection of other incompatible combinations may be added in a
future release. Use "-C 0" to disable the detection.
* Add new interactive menu. When enabled with -Mi and the interrupt
key is pressed (typically ^C), cw2dmk will enter a menu with
options. Also, -Me will enable dropping into the menu when the
error limit for a track exceeds the number set by -x.
4.6.0 -- Thu Dec 17 17:24:34 UTC 2020 -- Quentin Barnes
* Skipping over 4.5.x versions since George Phillips had used that
point release line for his work.
* Git repo "cw2dmk" of Tim Mann's work was created by ezrec
(Jason S. McMullan). Transferred to qbarnes.
* Switched Linux release binaries to be for 64-bit OSes.
* Added change from George Phillips for his "join" (-j) feature
that will join different rereads of the same track and merge
good sectors.
* Fixed problem of missing data between index hole detect and read
started. This should noticably reduce disk read errors and even
occasionally dropping of entire sectors.
* Added change to allow cw2dmk tools to function on newer Linux
releases by enabling PCI I/O space access if disabled.
* Added change to recognize and skip factory-formatted sides of a
disk. Controlled with -b option.
* The subdirectory "cwsdpmi" is now a git sub-module for picking up
the "cwsdpmi.exe" binary for MS-DOS.
* Cleaned up and merged multiple makefiles for different environments
into one. Makes it easier to maintain, build, and cross-build. By
default, the Makefile will now only build for the native OS. See
the new file BUILDING.md for further information.
* Created subdirectory "firmware" for holding firmware related files
including a LICENSE file. I also received some additional
documentation from Jens Schoenfeld on programming the MK3 and MK4
and a file with firmware revision history saved here as
firmware/Changelog.
* To be less generic, renamed "testhist" binary to "cwtsthst", still
keeping to MS-DOS's 8.3 file naming convention.
* Update code base to be 64-bit clean. Fixed all known problems but
some may remain.
* Changed to using semantic versioning for version ID.
4.4 -- Sat Nov 28 11:45:01 PST 2009 -- Tim Mann
* The Linux binaries included in this distribution are compiled on a
32-bit Ubuntu 8.04.3 LTS system. The MS-DOS binaries are still
compiled with a version of djgpp from the year 2000, under djgpp.
The MS-DOS binaries are untested at the time of this release.
* Updated to the current Catweasel MK4 firmware from Individual
Computers, moving from pre29.cw4 to rel2f2.cw4. Changed catweasl.c
slightly to work with the new firmware -- the write pulse width now
must be set.
* Fixed cw2dmk bug where the total sectors read in each encoding
counted all retries, not just the last one.
* Added -r option to cw2dmk and dmk2cw to reverse the sides. This is
mostly to help split/join disks that have a separate one-sided image
on each side but were written with a double-sided drive (that is,
they are not flippy) to/from two separate DMK images.
* Fixed an incompatibility with newer versions of libpci that had
prevented recompiled Linux binaries from recognizing a PCI
Catweasel.
* Added a dmk2cw option to use only a prefix of the track in the DMK
file.
* Changed the way dmk2cw generates fill data when the DMK track is
shorter than needed to fill the disk. Added an option to select
some alternative fill methods.
* Some small fixes and cleanups, mostly in documentation and messages.
4.3 -- Sat Jun 25 00:21:23 PDT 2005 -- Tim Mann
* By popular demand, print more stuff at the default verbosity levels.
cw2dmk -v2 now prints its version number, and it prints a count of
good sectors and errors when a track read with errors is about to be
retried. dmk2cw -v1 now prints its version number too. Both can be
suppressed by going to the next lower -v level.
* Fixed a cw2dmk problem where the RX02 flag would get turned on in
the header if we ever saw what looked like an RX02 DAM, even if it
was just noise. Now we turn on the flag only if there was a good
RX02 sector (valid ID, ID CRC, and data CRC), or the user specified
-e3. Also added a count of good sectors in each encoding to the
summary.
4.2 -- Sun May 15 21:00:44 PDT 2005 -- Tim Mann
* Fixed a couple of places where we could fail to stop the drive when
quitting with an error.
* Added support to dmk2cw for switching the Catweasel's HD output on
or off for tracks greater than 43. This may be useful with 8"
drives that want a "track greater than 43" or "write current switch"
signal. When building an adapter cable, note that HD is pin 2 on
the 34-pin bus and TG43/WCS is pin 2 on the 50-pin bus.
* Fixed error checking and message in cw2dmk's side detection. We
can't detect whether side 1 is formatted unless we can get a
histogram, which requires an index hole. Formerly we'd just
incorrectly detect that it wasn't formatted in that case. Also,
only detect_kind checks if side 0 is formatted; detect_sides
doesn't, so the message "Detected 1 side formatted" was
misleading. Changed it to "Detected side 1 not formatted".
* Improved write precompensation in dmk2cw. The -o flag now takes two
values, so you can make precompensation steadily increase when going
from outer (lower-numbered) to inner tracks. The default is still a
constant 140ns, but that may change.
4.1 -- Tue Apr 19 22:14:21 PDT 2005 -- Tim Mann
* Made cw2dmk print the histogram gathered by detect_kind with -v7.
* Tweaked drive/media autodetection to work whenever the disk has an
index hole, even if we're not using it for reading because -h0 was
given. If there really is no index hole, autodetection will fail
and -k will still have to be given explicitly.
* Changed testhist (and cw2dmk's detect_kind) to recognize peaks up to
24 samples wide instead of 16. I noticed peaks slightly wider than
16 on some good disks. It would be nice to find a good peak
detection algorithm in the literature to replace this one, which I
pulled out of the air.
* Changed the total "good tracks" count to omit tracks with 0 good
sectors even if they also have 0 errors.
* Fixed backward address mark detection to work on RX02 disks too.
* Changed dmk2cw to fill any tail of the Catweasel's sample memory
beyond the end of the DMK buffer with a run-out pattern of
alternating 0's and 1's, which looks like 0xff in FM or 0x00 or 0xff
in MFM. Formerly we'd leave this tail untouched, which could result
in data left in the sample buffer from a previous track being
written to the end of the current track, a bad thing.
* Switched to using the Catweasel's 2x (14.161 MHz) clock for all disk
kinds. Formerly I was using the 1x clock on disks with lower data
rates in hopes of being more compatible with early MK1's that need
their MACH chip reprogrammed.
* Disabled the check for the old CW MK1 memory error. It fires
spuriously too often when reading a bulk-erased disk or other such
garbage. Hopefully people with early CW MK1's have gotten their
MACH chips reprogrammed by now.
* Since a long timed read can completely fill catweasel memory (in
particular, this is likely on a HD or 8" DD disk read with -h0), I
shortened the end mark that catweasel_read puts in the data buffer
to two bytes. On MK4, I avoid putting in the mark if memory is
already full. On MK1 and MK3 there's no way to tell whether memory
is full, so I always put in the mark, but then I skip the first two
samples in case the write wrapped and the end mark wound up in the
first two bytes of the buffer -- ugh.
* catweasel_put_byte and catweasel_get_byte now keep track of how much
catweasel memory has been used. Callers now check properly for
hitting the end of memory on both reads and writes.
* Bugfix: MK1 was not using index-to-index read with index storage as
intended. (It was using index-to-index read without index storage.)
* Small tweak to dmk2cw: don't recognize 0xfc in the area where a DAM
is expected as a possible DAM. This fixed a problem writing my dmk
image of l2-631a.dmk back to a real disk. It looks like this image
was made with an old version of cw2dmk that left more crud in this
region than it should have, so I plan to redo it.
* Write 0x22 to iobase+3 to make MK4 give drives back to the onboard
controller instead of 0x21. Per a thread on the developer mailing
list, this may be needed to ensure the PCI bridge chip doesn't
misbehave and cause the card to show an incorrect PCI ID after
reboot on systems that do only a soft reset of the PCI bus upon
reboot. This command also clears the FPGA.
* Changed -v3 to print the sector numbers too.
* Changed the default postcomp (-o flag) to 0.5. This seems to help
the new decoder deal with FM better, as well as being good for MFM
disks written with too little precomp.
* The new decoder may not be quite as good at reading FM disks as the
old one, because its data separator is always looking for MFM
medium-length samples (corresponding to MFM 100 sequences), which
can't occur in FM data. Using -e1 will force the data separator to
classify all samples as either long (MFM 1000; FM 10) or short (MFM
10; FM 1), never medium. So try -e1 if you have difficulty reading
an all-FM disk.
* Rewrote cw2dmk's FM/MFM/RX02 decoder, the core of the program.
Formerly there were three separate decoders with some flaky
heuristics to switch between them. There is now just one decoder
that handles all three types of encoding. See decoder.txt for
internal documentation. The new decoder is much better than the old
one at switching between FM and MFM on tracks with some sectors of
each. It's also much smaller and cleaner than the old code.
4.0 -- Tue Apr 5 22:08:59 PDT 2005 -- Tim Mann
* Added Catweasel MK4 support. For now, I load the firmware and then
pretty much treat it like a MK3.
* Added code to take advantage of one new MK4 feature: the ability to
multiplex the same set of drives between the Catweasel and the
onboard floppy controller. catweasel_init_controller takes over the
drives, and catweasel_free_controller gives them back. If cw2dmk or
dmk2cw dies uncleanly and fails to give the drives back, simply run
it again. Unfortunately, I haven't had good luck with this myself;
the onboard controller gets lots of errors reading/writing the
drives. Maybe I'm doing something wrong.
* I ran into a problem with one disk where the FM autodetector would
fire spuriously in an MFM region (deterministically, or almost so)
just at the very end of gap2 (the gap between the ID field and the
sector data) on certain sectors. I tweaked one of the constants in
detect_encoding() to make FM a bit slower to fire, which fixed this
case. However, testing another hard case (a HyperZap disk read with
-h0), it's clear that there are also times when the FM detector is
too *slow* to fire, even with the constant at its old value. The
detector is really a rather bad kludge and I'm thinking about
rewriting it; see the ToDo file.
3.5a -- Sat Apr 2 17:04:12 PST 2005 -- Tim Mann
I forgot to update the version number in version.h when releasing 3.5,
so it still read 3.4. This release is identical except that I've
updated the version number and have added a dependency on version.h to
common.mak.
3.5 -- Mon Mar 28 22:16:00 PST 2005 -- Tim Mann
A few simple changes that I've been sitting on for a while. I haven't
started work on Catweasel MK4 support yet.
* Fixed a bug in autodetecting a Catweasel MK1 that I introduced in
cw2dmk 3.3 when moving code around so that all messages could be
written to the log file. The bug caused cw2dmk to error out with a
spurious "No access to I/O ports" message instead of looking for a
MK1 at the default address of 0x320. Giving an explicit -p option
still worked, so I didn't notice the bug.
* Changed catweasel_detect_drive to turn on the motor while detecting.
Chuck Guzis reports that this is needed for some 8" drives. (At
least if you happen to drive the 8" DRIVE_SELECT wtih the PC
MOTOR_ON signal and the 8" HEAD_LOAD with the PC DRIVE_SELECT. This
seems a bit backward to me, but Chuck says it's "usual".) At any
rate, turning on the motor ought to do no harm, so it's worthwhile
if it helps some users.
* There was a fatal bug in dmk2jv3's handling of disks containing more
than 2901 total sectors, which necessitates adding a second block of
JV3 sector headers. Instead of putting the write protect flag into
the last byte of the first block of headers, dmk2jv3 was putting
what should have been the first byte of the second block there.
Worse, it was leaving this byte out of the second block, ending up
shifting the whole block back by 1 byte. Probably no one has hit
this bug but me, since 5.25" 80-track disks can't have that many
sectors, and most emulators don't support the second block of
headers in a JV3 image anyway. I noticed it when working with some
8" disks.
* I ran into a disk where some of the FM write splices looked like
address marks and caused bogus errors. Added a heuristic that
suppresses the FM address mark detection for 32 bit times after each
data CRC computation.
* There was a bug in cw2dmk's wrapround detection that could
erroneously delete the final good sector on a track. If we wrapped
around and saw the IDAM of the first sector again just as the track
was filling up, dmk_idam() would not put a pointer to this IDAM
into the DMK track header, but its caller would still set ibyte=0 to
indicate it was decoding a sector ID block. This made us think we
had a partially decoded ID block at the end of the track whose IDAM
pointer needed to be erased, causing us to erase the IDAM pointer to
the final good sector on the track. I fixed this by moving the
setting of ibyte=0 up into dmk_idam() so that it happens if and only
if an IDAM pointer is placed into the DMK header.
3.4 -- Fri Jun 4 22:47:03 PDT 2004 -- Tim Mann
* Bugfix: the -e option to cw2dmk was broken; using it would prevent
disks from being read at all. I think this was first broken in 3.2.
* Log the version number in cw2dmk and dmk2cw if the verbosity level
is set any higher than the default value.
3.3 -- Sun May 30 01:52:37 PDT 2004 -- Tim Mann
* jv2dmk and dmk2jv3 now default the output filename to be the same as
the input filename but with the extension changed to dmk or dsk as
appropriate.
* Changed the -v flag to optionally take a two-digit value, with the
first digit giving the verbosity level to write to a logfile and the
second digit giving the level to go to the screen. Added the -u
option to allow specifying the logfile name.
* Deleted the -r flag because reading time is always determined
automatically now, and it's not useful to let the user mess with it.
* Changed the -h1 reading strategy so that we always have hole edges
marked in the data stream. On CW MK1, the hardware hole-to-hole
read will do this for us, but on MK3 it won't, so instead we
manually wait for the index hole and then do a timed read for 110%
of the nominal time for a revolution. This should get rid of the
wraparound problems on MK3 for good (e.g., reading a 10-sector disk
and getting "10 good sectors, 1 error" due to seeing the start of
the next sector again). Both kinds of wraparound detection (3rd
index edge and 95% of DMK track length) are still active for -h1
even though we should need the latter only for -h0 now.
* Added a heuristic where if we are guessing the number of tracks, and
we get to track 80 or beyond, and we see a logical track number that
is half the physical track number, we stop. This helps if you have
a disk that was formatted for 40+ tracks in a 40-track drive, then
reformatted for 80 tracks in an 80-track drive. Without the
heuristic, you may see a copy of the data from the old tracks beyond
40 on the new tracks beyond 80.
* catweasel_seek had code in it to prevent seeking past track #79, so
we could never have read disks with more than 80 tracks! I upped
the maximum to track #85, allowing for 86 tracks. The normal case
will now be (as I had intended) to try to seek to track #80, notice
there is no data there, and give up without going farther, so we
should not be damaging any drives by trying to go way too far.
* Changed cw2dmk's default for -d to try drive 0 first, then drive 1
if drive 0 is not detected. Also, if -d is used to specify a
particular drive, only that drive is tried, and failing to detect it
gives a warning, not a fatal error. The latter change allows a
drive without a working track 0 sensor to be used with cw2dmk.
* Changed the "approx()" in dmk2cw to recognize lengths within 4% of
nominal instead of 2%, to make sure that the new longer default DMK
track lengths are recognized.
* Created a ToDo file to hold ideas for future improvements.
* Changed catweasel_detect_drive so that even if the drive has no
working track 0 sensor, it will always attempt to step out to track
0. I've lost track of who suggested this change.
* Bug fix: dmk2jv3 was not checking for false track numbers, which the
JV3 format can't handle. Instead, it was silently putting the
sectors on the JV3 logical/physical track that matches their
*logical* track number. I've now changed it to print a message and
put the sectors on the JV3 track that matches their *physical* track
number, which should produce a somewhat less useless JV3.
* Made the default DMK track lengths in cw2dmk about 2% longer, so
that we don't cut off the end of a track that was written in a drive
that was running a little too slow.
* We now check that the user doesn't set a DMK track length greater
than the hard maximum (0x4000) in cw2dmk and jv2dmk.
* Restructured cw2dmk message printing to use a common msg() function,
in preparation for making it more capable.
3.2 -- Tue Jun 17 22:43:51 PDT 2003 -- Tim Mann
Thanks to David Sutherland for trying the new features in version 3.1
and reporting problems reading various strange disks. Many of the
changes in 3.2 are inspired by his experiences.
* Removed the heuristic added in 3.1 that tries to deal with track
wraparound by cutting off sectors that begin beyond the nominal
track length for the kind of disk being read. This was bad because
the nominal length was hardwired, making it impossible to read disks
that have a lot more than the nominal track length -- for example,
as Atari 800 disks, which are written in drives that rotate at 288
RPM instead of 300 RPM. It also failed to cut off enough data on
disks with a little less than the nominal track length.
* Added new heuristics to deal better with wraparound. We base these
on the DMK track length, which is settable with the -l flag, so
disks written at slow speeds can be read. The new heuristics are:
(1) After we've read 95% of the DMK track length, if we see a new
sector ID that is the same as the first sector ID on the track,
ignore it and cut off. (2) If there is an incomplete sector ID at
the end of a track, ignore it instead of counting it as an error.
(3) In -h0 -i mode, if we see a second IAM after having read 95% of
the track and having seen at least one IDAM, ignore the second IAM
and cut off. Heuristic (3) is similar to one that was in 3.1; the
others are new.
* Made the -r and -h options independent instead of mutually
exclusive. Specificially: (1) Removed the feature that a negative
-r value starts reading without waiting for the index hole; the -h0
option does this in a more useful way now. (2) If -r is used
together with -h0, this now overrides the default readtime of 2
revolutions instead of being forbidden as before.
* Added the -r1 and -r2 options to specify 1 or 2 revolutions. Larger
values still give a time in ms.
* Fixed a possible bug in drive detection. We would have failed to
detect a drive that was initially stepped out to track 82 or so and
was capable of going to 85.
* One more try at taming the RX02 detector. Now it fires only if we
see a 0xfd DAM following a sector ID *with a good CRC*. Hopefully
this will stop it firing on garbage. If not, the next step is to
kill it and require people reading RX02 disks to specify -e3
explicitly. That wouldn't be so bad, really.
* Taking a histogram to autodetect whether side 1 is formatted now
works in -h0 mode too.
* Added a heuristic to detect reading a flippy disk on the wrong side.
It works by recognizing what MFM ID address marks and FM data
address marks look like when read backward. Some care was needed to
prevent it from firing on garbage.
* At the start of each track, the FM/MFM encoding detector now uses
the encoding of the first good sector from the previous track as its
initial guess. Formerly it used the encoding of the end of the
previous track. The new heuristic works better on disks where every
track has an FM part followed by an MFM part (or vice versa). It
should work just as well for the case the old heuristic was meant to
handle, where every track except track 0 is MFM but the tracks start
so close to the index hole that if the detector is initialized to
guess FM, it doesn't correct itself in time.
3.1 -- Sat Jun 7 19:36:15 PDT 2003 -- Tim Mann
* Added the -h0 flag to cw2dmk. This will read a disk without using
the index hole to decide where to start. It is useful for reading
the back side of a disk that was made in a flippy drive, provided
that either you have a drive that will deliver data to the
controller even if it doesn't see any index pulses, or you cut an
extra jacket hole in the disk. Original TRS-80 drives should work,
but modern drives won't. Some modern drives may possibly be
jumperable to work, but definitely not all. Another use for the -h0
flag would be if you have a strange format where a sector crosses
over the index hole location and is cut in half by cw2dmk's normal
reading method.
* Modified the -i flag of cw2dmk so that it works no matter where the
IAM is on the track. Formerly it worked only if the IAM appeared
before the first IDAM. Now sectors that come before the IAM will be
ignored. The flag is still useful for its old purpose, and it now
is also useful in conjuction with the -h0 flag -- if your disks have
an IAM at the start of every track, you can align the tracks in the
DMK output to start at the right place by using -i. To make gap0
large enough to be in spec, -i96 is recommended, but you can use a
smaller value if -i96 cuts off the end of the last sector on the
track. Note that using -i will cut off a track prematurely if the
IAM appears somewhere in the middle of the track and you haven't
arranged to read the track for two revolutions by setting -r or -h0,
and it will prevent the track from being read at all if it has no IAM.
* Changed cw2dmk to end a track that's longer than the nominal length
as soon as we are in a gap. This fixes a problem when reading disks
with the Catweasel MK3, where you could get an extra partial copy of
the first sector header repeated at the end of the track. This
happened because of a change to the way index-hole-to-index-hole
reading works between the MK1 and the MK3.
* Made the Catweasel MK1 memory error test more reluctant to fire and
less verbose. It now fires only on the 16th apparent error. This
was needed because the test can detect false errors when reading an
unformatted track.
* Added error checking to detect confused people misusing the -p flag
to cw2dmk and dmk2cw.
* Improved some man pages and error messages.
3.0 -- Sat Dec 7 21:46:19 PST 2002 -- Tim Mann
* Rewrote catweasl.c to support Catweasel MK3 PCI as well as MK1 ISA.
* Added cwpci.c, containing routines to query the PCI bus and detect
the MK3, one set for Linux, one for Windows 95 and MS-DOS.
* Generalized and altered the -p and -c options of cw2dmk and dmk2cw
and clock argument of testhist to mesh well with both cards.
* Reversed drive 0 vs. drive 1 numbering with Catweasel MK1 from the
way I had it previous releases. It now matches the numbering used
by the bundled Catweasel tools.
* Made cw2dmk quicker to give up on finding more tracks when it is
guessing the number of tracks. The old algorithm had a bug if you
tried to read a disk in a 40-track drive; it wouldn't consider
stopping at track 40 unless you were double-stepping.
* Included the MS-DOS DPMI host cwsdpmi.exe by Charles W. Sandmann
in the package instead of requiring users to download it separately.
* General code cleanup and reorganization.
2.8 -- Unreleased: checkpoint before adding Catweasel MK3 support.
* Added an option to cw2dmk to start reading without waiting for an
index hole. This needs more work; see the man page.
* Added checking for read error to testhist.
* Deleted some unused structures left over from the Linux driver.
2.7b -- Mon Aug 19 21:37:40 PDT 2002 -- Tim Mann
* Added some checking to help detect when input supplied to dmk2cw or
dmk2jv3 is not a DMK file.
* Removed !'s from error messages. Some had them, some didn't, and
having them is a very outdated style.
2.7a -- Sun Jun 30 00:15:10 PDT 2002 -- Tim Mann
* Fixed some documentation wording errors and did some minor cleanup.
2.7 -- Sat Jun 29 00:03:05 PDT 2002 -- Tim Mann
* Wrote jv2dmk and added it to the package. Like dmk2jv3, it is
independent of the other tools and does not require Catweasel
hardware; it simply converts between two different emulator formats.
* Minor tweaks to documentation and messages for the other tools.
2.6 -- Sat Jan 19 13:36:53 PST 2002 -- Tim Mann
* Wrote dmk2jv3 and added it to the package. This program is
independent of the others and does not require Catweasel hardware;
it simply converts between two different emulator formats.
* Added -s flag to dmk2cw for safety in dealing with 1-sided drives.
2.5 -- Wed Jan 9 20:12:54 PST 2002 -- Tim Mann
The following changes were motivated by a problem reading certain
TRS-80 DOSPLUS disks, where track 0 side 0 is FM, track 0 side 1 is
unformatted, and the remaining tracs are MFM. The only way to read
such a disk with cw2dmk is to specify -s2 and let encoding be
autodetected, but the RX02 detector was (still) overeager and would
sometimes fire on the garbage read from unformatted track 0 side 1.
* Disabled RX02 autodetection on side 1. In order to autodetect RX02,
we now have to see an RX02-MFM sector on side 0, track 0 or 1, This
seems likely to work perfectly, and if it should fail, you can always
use -e3 to force RX02 anyway.
* Previously, the RX02 detector was willing to fire if it saw a 0xfd
DAM following an ID block with a bad CRC. This made it too prone to
fire on unformatted tracks. It now requires a good CRC on the ID
block preceding the 0xfd DAM. This change also fixes another bug:
when counting good sectors, we had erroneously been including sectors
with bad ID CRC but good data CRC.
2.4 -- Wed Aug 29 23:39:52 PDT 2001 -- Tim Mann
* Changed my email address. I have left Compaq.
* In encoding autodetect mode, the detector now starts each track
(including retries) guessing the previously detected encoding.
Formerly it always reverted to guessing FM at the start. This will
help in reading disks that have an extremely short gap between the
first sector header, such as some Newdos disks.
2.3 -- Sat Jul 14 18:01:38 PDT 2001 -- Tim Mann
* Disabled looking for drive ready entirely. Evidently some older
drives do not provide this signal.
2.2 -- Fri Jul 13 23:23:24 PDT 2001 -- Tim Mann
* All catweasel read/write/await-index routines that look for drive
ready (=no disk change) now wait 5 seconds for the signal to appear
instead of erroring out immediately if it is not present.
* Added a 5-second timeout to all catweasel routines that look for the
index hole.
* Fixed the RX02 autodetector; it would sometime fire when it shouldn't.
Also, detecting RX02 sets the current stepping guess to single.
2.1 -- Sat Jun 30 21:31:26 PDT 2001 -- Tim Mann
* Added autodetection of RX02 double density to cw2dmk.
* Changed cw2dmk to pre-detect address marks so that it can byte-align
the data stream earlier. Before this change, the byte written to the
DMK file before an FM address mark would often be garbage, as would
the byte before and the first byte of a 3-byte MFM premark sequence.
Also added a heuristic to byte-align on 4e4e and 0000 sequences in MFM
gaps. These changes make the contents of the DMK file cleaner-looking
and a bit more amenable to changing with a hex editor. They also
remove the need for some cleanup that is done in dmk2cw, but I am
leaving the cleanup in so that DMK files made with older versions of
cw2dmk can still be written back to disk.
2.0 -- Sat Jun 23 00:48:14 PDT 2001 -- Tim Mann
* Initial release of dmk2cw.
* Added peak detection to testhist instead of using fixed windows.
* Minor tweaks to cw2dmk.
1.6 -- Tue Jun 12 00:17:12 PDT 2001 -- Tim Mann
* Changed DMK_MARK_IAM to 0 (see changes for 1.5 below), but left the
code in for possible future use. The extra pointer does cause a minor
problem with both David Keil's emulator and xtrs -- both of them see
it as a bad ID on Read Address commands, though they manage to ignore
it otherwise.
1.5 -- Mon Jun 11 11:08:32 PDT 2001 -- Tim Mann
* Added -a flag.
* Use catweasel_memtest (formerly debugging code) to detect whether a
Catweasel is present at the specified address; error out if not there.
* Error out if catweasel_init_controller did not detect the specified drive.
* If an index address mark is found, we now put a pointer to it in the
DMK track header, just as with ID address marks. David Keil told me
that this won't confuse his emulator; since the pointer points to an
0xfc instead of an 0xfe, he won't think it's an ID block. You can
turn off this behavior by #defining DMK_MARK_IAM to 0 instead of 1 and
recompiling.
* Added -e3 flag to support DEC RX02 floppies, which use a strange
encoding when in double density.
* Added missing documentation of -v7 flag.
* Added -w flag.
1.4 -- Sun Mar 11 21:45:34 PST 2001 -- Tim Mann
* The .txt version of the man page was truncated in 1.3. This was
caused by an obnoxious feature in the current Linux nroff -man macros
of using '\255' as a hyphen at line breaks, combined with a bug in
colcrt (and col) that makes them consider this (or presumably any
character with bit 8 set) as EOF.
1.3 -- Wed Oct 11 00:59:14 PDT 2000 -- Tim Mann
* Fixed a garble in the Diagnostics section of the man page.
* Changed open mode on .dmk from "w" to "wb", which is required for the
MS-DOS version. That's why the MS-DOS version produced bad disks before.
Thanks to Amardeep S. Chana.
1.2 -- Sat Aug 12 16:08:18 PDT 2000 -- Tim Mann
* Corrected read-postcompensation to work even if user selects a
non-default Catweasel clock rate.
* Tweaked some autodetection constants.
* Added "Diagnostics" section to man page.
* Added memory error detection.
1.1 -- Tue Jul 4 21:05:58 PDT 2000 -- Tim Mann
* Added read-postcompensation (-o flag).
* Added verbosity level 7.
* Added bit resynchronization heuristic for MFM clock violations,
previously only implemented for FM.
* Fixed some minor errors in what verbosity level things were printed at.
* Moved usage message to stdout so that it can be easily piped into more.
* Corrected some minor errors in man page.
1.0 -- Thu Jun 22 02:32:00 PDT 2000 -- Tim Mann
* Initial public release.