with this setup I can control the stepper from the Arduino without the drive's microcontroller interfering. then I can use the Saleae to digitize the data.
Top-level
with this setup I can control the stepper from the Arduino without the drive's microcontroller interfering. then I can use the Saleae to digitize the data. 67 comments
here is a closeup. the raw MFM data shows a square wave of 5MHz for most of it, but there is a short section (4ms long) of 1.8MHz. the one-shot acts as a primitive data separator and the MCU can then detect this index marker and reset the hall effect divider flip flop. now it gets a little strange. there seems to be a secret set of 17 hidden sectors on track -1. @tubetime Dynamic CHS parameters for a programmable hard disk controller like the WDXT-GEN? @tubetime I have a stalled project to RE the WDXT-GEN BIOS, because I got tired of it's shitty/uninformative error messages. If you don't use one of the 4 hardcoded drive types, the BIOS will write your drive type (CHS, Write Precomp, Reduced WC, etc) to somewhere on the drive that's _not_ the data area. It's not actually clear to me where the data is actually written, but IIRC, the "magic" value to provide to the controller is "write to track 0 with an out-of-bounds sector". oops didn't mean to leave you hanging. turns out my track numbering is off by one. this is actually track 0 and it has regular MFM data on it. i wrote a quick-and-dirty routine to convert it and it just has regular WD1010-style headers for 17 sectors. i made a table showing the layout on the platters themselves. only head 0 has the index marker tracks. there are 2 of them, one at track -1 and the other at track 617. to allow your computer's HDD controller to park the heads, it lets you step past the user data area end track of 614 to go all the way in to track 670. theoretically, if you mistype the BIOS # of cyls, you could try to store data here and even overwrite the inner index track! this will confuse the drive when it powers up. it'll eventually go find the index track on the outside edge, but only after an extended search sequence. you can't command the drive to step to track -1, so you can't overwrite that track. @tubetime I have loved this thread. While I've got into bit-level understanding of floppies before, hard disks have always been mysterious black boxes to me, and while at a logical level I understood they'd be something like this, this actual reversing has been a great way to remind myself they're not magic! Thanks. @sgf thanks! yes, it's easier to understand the older drives, but there's a steady, linear progression from then to modern drives. trying to digitize the entire drive using the Saleae. one drawback is exporting as a CSV takes f o r e v e r @tubetime CSV is a horrible interchange format (other than being supported by literally everything). Bulky, slow to parse, slow to generate, difficult to do random access in, etc. But it's not going anywhere. @tubetime This is why the native format for ngscopeclient is just float[] with some attached metadata in a yaml file lol. I haven't looked at the saleae binary format. Is it documented somewhere? I should write an importer for it. the real reason for all this is that there's data on this ST225N (SCSI version of the drive) on the right. I want this data. I already tried a board swap but the SCSI version stores its firmware on track -1 and -2 instead of an index signal. my hacked board should be able to handle it, though. @tubetime If its your "original bitcoin cold wallet with 2500 bitcoin" I'm gonna lose it 🙂 the design of the ST225N is essentially an ST225 but with the data separator and controller built in. they changed the microcontroller to an 8051, and stored a bunch of the firmware on some hidden tracks. boards are swapped. now let's image the whole drive in about 175 seconds to a giant Saleae capture file! @tubetime Real Men™️ backup their data with a logic analyzer! wrote a crappy python program to interpret MFM data, and it seems we have some sectors. they are using a different sector header format and there seems to be a lot of corrupted data. there are a few sectors with the drive firmware (negative cylinders) but then there appears to be real data. "DOS" might be part of some partition table scheme. the sector header might follow the format used by the Adaptec AIC-010 chip (which the ST-225N uses). wow, a 32-bit CRC. i wonder which one... wow there is definitely data on this drive. i'm fudging the MFM decoding to try and skip over errors. @tubetime hopefully the data on that drive will reveal the secret of the Kennedy assassination. You are putting a lot of work in after all. trying to capture more of the drive image to a binary. we'll see how it goes. so even though this disk image is probably irrecoverable, i want to learn as much as a can. this drive was from the Amiga Comspec, and i want to see if i can figure out how to replicate the disk layout. this segment here is from the Kickstart disk. @tubetime Really cool work! And great timing, I was just trying to diagnose a faulty ST-238R earlier this week! I have a feeling that two of the read heads aren’t working right, but I need to confirm that. well now i feel a bit stupid. this thread from a few years ago includes links to disassembled drivers and ROMs, as well as a sample disk image. i decided to try and get a better read of the firmware tracks (-1 and -2 on all the heads). this time i'm capturing analog data from the drive's test points. not all the surfaces have a good amplitude. this could explain some of the issues i was having. (channel 2 has a pulse whenever the head changes.) anyway this analog signal comes off the drive's analog test points (circled). this signal comes after the differentiator (IC 9E1) and the first stage analog filter, but before the second stage filter. i'm trying to correlate the drive's data output (valid on the rising edge, each pulse has a fixed width) with the analog data. it seems to have a delay of about 180ns caused by the analog filter and the propagation through the comparator. @literatesavant i was hanging out with him on Thursday, so it was a weird coincidence. @tubetime @pyksy ahh excellent someone else recognizes it! i'll have to check and see if the book block was preserved. I wrote this to take odd-ball floppy formats apart, maybe you can use some of it: @bsdphk i'll take a look. python has been pretty slow for the file sizes i've been working with, however. @tubetime is that an Android Arduino? No way this runs android (?) @nichtjonas it is a Mega 2560 that was custom made by Android back in 2011. it has a USB host interface that can connect to phones of that era. they were giving them away... |
confirmed that there are two index tracks, one at track -2 (relative to user data starting on track 0) and another on track 616 (user data ending on track 614). the D2 square wave is directly from the hall effect sensor, 2 cycles per revolution. the D1 pulses are this signal divided by 2. MCU read data is the index signal as seen by the MCU after being processed with a one-shot.