Viewing Issue Advanced Details
ID Category [?] Severity [?] Reproducibility Date Submitted Last Update
08458 Core Critical (emulation) Always Oct 21, 2022, 04:17 Oct 23, 2022, 09:13
Tester pnp2084 View Status Public Platform MAME (Official Binary)
Assigned To pnp2084 Resolution Fixed OS Windows 10/11 (64-bit)
Status [?] Resolved Driver
Version 0.248 Fixed in Version 0.249 Build 64-bit
Fixed in Git Commit f5eeb26 Github Pull Request # #10454
Summary 08458: trs80l2, trs80m4: WD FDC FM sync incorrect in two places
Description When wd_fdc.cpp code finds an FM sync mark, in a couple cases (read track and SEARCH_ADDRESS_MARK_HEADER) the "data_reg" value is examined or returned. But this is incorrect: data_reg is only valid after sync has been achieved. This results in the value C7 being examined instead of the correct FE (or FB, FA, F9, F8).

Also, not reproduced here, the read track was only looking for FB/F8 marks instead of the four possible DAM marks.
Steps To Reproduce The TRSDOS sync problem will occur late in the boot. The DOS READY command prompt will never appear as the emulator endlessly retries a sector on track 17:
mame trs80l2 -flop1 trsdos23b.mfi

The SuperUtility for model 4 will fail to boot as the code which scans the READ TRACK command result will not find an FE in the (early) part of the track, instead there is an incorrect C7 clock byte in place of the FE.
mame trs80m4 -flop1 su4x.mfi
Additional Information
Github Commit
Regression Version
Affected Sets / Systems trs80l2, trs80m4
Attached Files
zip file icon (222,251 bytes) Oct 21, 2022, 04:17 Uploaded by pnp2084
TRSDOS 2.3 and SuperUtility 4 in MFI format
zip file icon (18,695 bytes) Oct 21, 2022, 04:22 Uploaded by pnp2084
FDC fix with corrects the data_reg
There are no relationship linked to this issue.
User avatar
Oct 21, 2022, 04:22
The attached contains an example fix where the correct data_reg value is retrieved when sync is achieved.
User avatar
Oct 21, 2022, 04:37
I've created a pull request to make it easier to review the (sample) changes: