New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
TI99 support reads but does not write #593
Comments
IMG.CFG setup for TI99 images is quite complex. I attach what I think is correct for 180k and 360k images. Note the images must be exactly that size: some are 3 sectors longer containing a bad-sector map, and will not match the given IMG.CFG stanzas. Is this an Artery or STM32 Gotek do you know? |
This is an Artery. I need to find away to get the gap(1-3) information and see if changing those corrects the issue. Since this is an emulated drive and the file is sequential sectors, what does the interleave and cskew do? Are they just for timing? Thanks for your help. |
Interleave rearranges sectors on each track so that logically sequential sectors are spaced at the interleave factor. It gives the host more time to process one sector before needing to read the next. Skew rotates the sectors on successive tracks so that sector 1 isn't always the first on a track. It means that after allowing for stepping from one track to next, you don't miss the first sector and have to wait a full revolution. Reason to believe Artery is less reliable for writes than STM32 due to having half as much ram so less buffering available. It may depend on the host that's connected. It may depend on the usb stick (try another if you can) |
I have tried four different USB sticks of different sizes and all different brands. No USB3 sticks, all 2.0 of 8 gig or smaller. Mark |
Maybe compare real drive versus Gotek via dumping hardware such as Greaseweazle? |
You could also try alpha release FlashFloppy v4.3a which buffers writes in a very different and more efficient manner. |
I don't mind buying the Greaseweazle but I am not sure how that will help. I can select the dsk file and read it fine and the writes act as if they are working (the write led "-" flashes and reads occur as it tries to find space on the drive) but the data is never altered on the disk (in the dsk file). The dsk file remains unchanged. So I am not sure how reading the data off the Gotek will help when the data is not altered and the reads work. Thoughts? |
Confirmed v4.3a has the same issue. Are there any new CFG knobs that can be tweaked? |
By doing raw dumps from real disk vs Gotek you could possibly load the dumps into a track visualiser such as HxC tools, and then inspect for differences in gaps, etc. |
I have ordered a Greaseweazle but it may take until the of January to arrive. |
I received the Greaseweazle and made two dumps, raw and hfe formats of the same disk. I loaded the dumped disk in to the HxCFloppyEmulator (image attached). I am not sure where in the HxC I can find the gap and other relevant information. Any pointers or guidance you can give would be helpful. Thanks, |
Okay this is a different higher-density format, at 36 sectors per track. Would be a 720kB capacity disk. Either double density eight inch, or high density 5.25 inch (microdiskette). Probably the latter since the dump is at 300rpm. Not a typical TI99 disk? |
This is from the Myarc HFDC (Hard Floppy Disk Controller) and can handle formats up to 1.44MB on floppies (3.5"/80 track). I tried extracting a DSDD 40 track 5.25" but when I try and read I get a failure of "No Index" on three different drives, with and without termination. I will try more options and different formats (DSSD, SSDD, SSSD). The ability to write fails for all formats including the 1.44 HD with the TI setting or with IMG.CFG settings that match the DSDD and many other GAP values I have played with. When I experimented, taking shots in the dark, I made sure reads continued to work before trying the writes. Once I understand how to read the output I can make adjustments to the IMG.CFG file to see if that helps resolve the inability to write. Any suggestions to try and overcome the "No Index" issue? I saw a Greaseweazle option for faking index, that is the first thing I will try. |
Sorry yes above visualisation is 1.44MB indeed, not 720kB. No Index may be mis-addressed drive. Does the motor spin up? Is it a straight ribbon cable, and have you tried other drive identifiers (eg |
I think your drive is jumpered DS0. Try |
--drive=0 worked (LED=on, motor=on, data dumped successfully). See the attached screenshot. Thanks for the suggestion. |
Okay yes zip and attach the hfe and I can take a look and get the gap3. You could also do this dump from your Gotek, to get an equivalent emulated dump. And we could compare interleave and gap3. You could zip up both and attach. EDIT: To be fair, we should know the Gotek gap3 and interleave. So that's optional! |
Attached is a zip file containing:
Let me know if you need anything else. Thanks! |
Was there an IMG.CFG on the USB drive? The parameters for the emulated image are weird: interleave=10, and there's an hskew. Doesn't correspond to a built-in TI99 format, nor what I gave you in IMG.CFG attached earlier. So either there's a bogus IMG.CFG floating about on the USB drive, or perhaps there's a bug or I'm misunderstanding the code. In which case I'll investigate using a debug build of FlashFloppy. |
I didn't find an IMG.CFG on the USB drive, so I reformatted the USB drive, reset the GoTek CFG (press the two buttons for 5 seconds with no USB), and loaded new FF.CFG and .dsk files on the USB. I verified the files could be read by the computer and all was successful. I used the Greaseweazle to dump the verified 360k file. The zip contents changed a little, below is the new contents:
Let me know if this works for you. Thanks, |
Okay the new emulated image looks as expected. I assume yous till can't write to it? Differences I see in the real dump:
|
Here is a new IMG.CFG to try. It should fix the emulation to closer match real: |
Thanks for the follow-up. Unfortunately the behavior does not change, the writes do not occur but reads are fine. I remove the FF.CFG, reset the drives config, tried to read the drive and it failed as expected. I then added the new IMG.CFG to the USB drive and tried the read again, now successful as expected. I then tried to write a file which failed. I tried to format the drive and the format and verify complete without complaint but the contents of the disk are unchanged, the format did not write any data. In all cases the write indicator flashes when writes occur. Let me know if there is something else I can try. Thanks, |
Run the logfile firmware and gather FFLOG.TXT after write and format attempts. Something should be logged on write attempts. |
I loaded FF log update v3.29 into the GoTek drive (the original test were 3.29). Attached are two files in the zip. The following sequence was followed for the actions and log captures:
Let me know if you need anything else. Thank you! [Edit] During the copy and the format the LCD screen displays the "W" for the write operations and no "W" when the read operations are executing. |
Hi Keirf, Thanks! |
Hi Keirf, Thanks! |
Here's a test firmware which delays handling of WGATE deassertion, by 10 microseconds. I can adjust this if 10us isn't appropriate. You need to be logged into GitHub for the download link to work. |
Any update? |
My apologies for the delay in my response. I have had a couple of family items that needed immediate attention. Mark |
Do you wish to pursue this ticket further? I looked again at the FF.CFG supplied previously. There was no sign of sector writes. I wonder if your Gotek has a bad write or write-gate pin connection. |
Hi,
Thanks for supporting the Gotek drive and theTI99!
I am using FlashFloppy with a Geneve (a TI99 compatible with some differences). This setup uses a Myarc floppy/HD controller. When setting up the FF.CFG with host = ti99 the 180k and 360k dsk files read correctly but cannot write. If the file exists and you copy it again the drive appears to read/write and completes without error (and the file is good). If you copy a new file the drive again appears to read and write but the errors trying to update the FAT. If you re-format the dsk the format and verification succeed but the old file are still intact and good (the write never occurred).
If I install a real TI FDC instead of the HDFC the read/writes work on the 180k and the 360k is not supported on that FDC.
Should I be able to remove the host = ti99 and make this work with an equivalent IMG.CFG file and entries? I have tried but have not been successful with the IMG.CFG. I am hoping this is a gap setting issue that could be solved in the IMG.CFG.
BTW, both the TI FDC and Myarc HDFC work on real drives.
Any help is diagnosing this would be appreciated!
Thanks
Mark
The text was updated successfully, but these errors were encountered: