I put the drive into a cheap Linux laptop (a converted Chromebook) where I was fairly confident that nothing bad would happen if there was malware on the drive. No go: nothing worked. Closer examination and comparison with PCB photos online (and some help from showed that the very helpful person who put up those photos) showed that the crystal was destroyed. The part number (T240) suggested a likely clock rate of 24 MHz. I only had 8 MHz crystals in my parts collection.
So, I ran this little bit of code (modified from a post on these forums) on a black pill (libmaple core) underclocked to 48 MHz, which produced a 24 MHz output (I hesitate to call it a square wave, because at this speed there is a lot of analog smoothing):
Code: Select all
HardwareTimer pwmtimer(3);
// 48mhz
void setup() {
pinMode(PA6,PWM );
pwmtimer.pause();
pwmtimer.setPrescaleFactor(1);
pwmtimer.setOverflow(2-1); // 48MHZ / 2 = 24MHz
pwmtimer.setCompare(TIMER_CH1, 1); // 50% duty cycle
pwmtimer.refresh();
pwmtimer.resume();
}
I attached a 4.7K resistor to the A6 pin, plugged the black pill into the laptop, and while carefully hand-holding the free resistor lead to one of the flash drive oscillator pins, I pushed the flash drive into USB. I didn't bother with ground connections, counting on the fact that the laptop's USB circuitry connected the grounds of the flash drive and the black pill. (I know that this is probably not something one should do, but I have had good luck in the past when interfacing devices both of which were powered from the same computer and not bothering with ground connections.)
Amazingly, the LED came on, the flash drive was recognized, and eventually I was able to recover all the data from it, and contact the grateful owner.
Notes:
1. When I soldered the resistor to the flash drive oscillator pin, it wouldn't work. Maybe stray capacitance from my hand-holding helped.
2. It didn't matter which of the two oscillator pins I used. Ideally, I should probably have removed the oscillator circuit capacitors, but I didn't bother.