VOGONS


First post, by mkarcher

User metadata
Rank l33t
Rank
l33t

I intended to deep dive into MCGA hardware level reverse engineering on a PS/2 model 30 - but as it turned out, not only the 10MB hard drive on the hard card is dead (it was already dead when the machine was put into storage), but also both floppy drives in that system failed to boot the IBM system disk (which is known good). I also have a second PS/2 model 30, but the floppy drive on that one died 23 years ago emitting some burnt smell. So two computers with no working storage, which is not good. The Novell Personal Netware infrastructure that I used to remote-boot the storageless PS/2 is long gone, so the only thing directly at hand is IBM ROM Basic.

The broken floppy drives from the computer I expected to have working drives seem to seek properly, but can't read any data. In contrast to many other vintage floppy drives, these drives also don't have a belt. Yet, I decided to program a RPM measurement tool using IBM ROM Basic. Please be aware that this BASIC program is specific to the (early?) PS/2 models of IBM, as it uses a diagnostic input port that is not available on standard PC floppy controllers, but only in the PS/2 I/O Gate Array. Let's go

10 DEF SEG=0
20 OUT &H3F2, &H1C
30 PRINT "Wait for stabilization"
40 FOR I = 1 TO 10 : GOSUB 1010 : NEXT I
50 GOSUB 2010 : START=TMR
60 PRINT "Measuring 100 revolutions"
70 FOR I = 1 TO 100 : GOSUB 1010 : PRINT I; : NEXT I
80 GOSUB 2010 : DURATION = TMR-START
90 PRINT 60*18.2/DURATION*100; "RPM"
100 END
1000 'Wait for one index event
1010 POKE &H440,&H80
1020 WAIT &H3F0,4
1030 WAIT &H3F0,4,4
1040 RETURN
2000 'Read BIOS time tick counter
2010 X=PEEK(&H46C)
2020 Y=PEEK(&H46D)
2030 TMR=X + 256*Y
2040 RETURN

And, surprisingly, this program really indicated a problem:

Ok
RUN
Wait for stabilization
Measuring 100 revolutions
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
616.9491 RPM

Huh, maybe I am just to stupid to get the formula to convert ticks per 100 revolutions into revolutions per minute wrong? Floppy drives are supposed to run at 300rpm, which is 5 revolutions per second. So 100 revolutions should take 20 seconds. I timed the 100 revolutions manually, and obtained 9.8 seconds, so the calculation that resulted in the drive being twice is fast as it should be is obviously not totally wrong, and the drive spins way too fast. Maybe the regulation is gone? I tried a different floppy disk, and indeed, this disk spun at 530 RPM. Now that's funny: Instead of a working floppy drive, I now have a friction measurement device. That's not helpful for data transfer, though... Obviously, the drive just seems to go as fast as possible, with no regulation kicking in.

It turns out you can disassemble the PS/2 floppy drives quite nicely without being afraid of loosing adjustment: You can unscrew the top cover, remove the top PCB and the shielding plate below. Try to not break the plastic clips that hold the shielding plate in place. You can also remove the mounting plate on the bottom, and unscrew 4 screws to take the machanism out. On the bottom side on the mechanism is a second PCB - this is the direct drive motor controller/motor PCB. Parts of the direct drive motor (like the coil for the index sensor magnet, the speed measuring "inductor", and most likely also the three drive coils) are directly mounted on this PCB. There are just 5 wires connecting the motor controller PCB to the main PCB, three of them are power, the last one "/MOTOR ON" and "IDX", so the fault must be located on the motor PCB. And it indeed is. I reverse engineered the complete motor PCB:
floppy.png
DrivePCB.JPG

The KiCad source code for the schematic as well as a Gimp .xcf file containing the board photo and the component designators as individual text layers are available in the associated GitHub repository.

As you see, the schematic cleanly divides into two parts. The left part contains the motor controller (including speed control), using a dedicated floppy motor controller chip, whereas the right part contains the index pulse generator. This is the first very important thing to understand: The presence of index pulses (which I measured with that basic program) only means that the index sensing coil sees the magnet fly past it. The motor controller needs more precise speed feedback: It uses a signal that toggles 60 times per revolution, and is generated by a magent (perhaps the motor magnets?) flying over a zig-zag trace below the disc-shaped flywheel. This drive does not use the "FG out" signal from the motor controller to generate the index pulses (it could divide the FG out signal by 60 to obtain a single pulse per revolution, but it would not know the rotational position of the disk, so a different sensing scheme is needed).

The final outcome of the troubleshooting is: C1, the DC blocking cap in the frequency meter section, was gone. That's an electrolytic cap, and those are prone to fail when they age. This cap is 33 years old. I tried paralleling another 1µF capacitor, and the speed of the drive suddenly drops when you hold the cap so it touches the signals C1 is supposed to be connected to. I re-ran my basic program with the cap held agains the PCB - and the output was "300 RPM". When desoldering the broken capacitor, I shorted some pins on the motor controller with solder, and need some desoldering wick and flux to clean up the mess I made. This has to wait for some days until I got these supplies.

Some final random notes about the motor controller PCB: It regulates to 300 or 360 Hz on the frequency feedback if the reference crystal has the suggested frequency of 610.2kHz. That is not 300 or 360 pulses per minute, but pulses per second. So that's why I wrote that you need 60 pulses per revolution. You might install crystals of different frequency, so the controller regulates to another speed. In the case of the IBM drive, IBM installed a 508.5kHz crystal, and chose the mode intended for 360Hz operation (mainly for 5,25" HD drives), which also results in 300Hz target frequency. When I checked the main oscillator with the ancient 10MHz analog single channel scope at hand, my first idea was that the scope is completely out of adjustment, because the frequency was way off 610kHz. U2E/U2F seem to be used to reverse the polarity of the hall sensor supply to cut down the standby current. This assumes the hall sensors don't conduct current if supplied in reverse. This feature is disabled by having JP1 (some solder points) open.

Reply 1 of 47, by Caluser2000

User metadata
Rank l33t
Rank
l33t

It'would be faster to just put a generic 3.5 ffd with power using a standard molex connector attached to the psu.

There's a glitch in the matrix.
A founding member of the 286 appreciation society.
Apparently 32-bit is dead and nobody likes P4s.
Of course, as always, I'm open to correction...😉

Reply 2 of 47, by mkarcher

User metadata
Rank l33t
Rank
l33t

For the drive that failed with the burned smell, I knew that the motor turns, but seeking fails. So I assumed the stepper motor or the stepper motor driver to have failed. It turned out to be wrong. And that drive turns at 300RPM, so the spindle drive PCB is OK on that drive. You can't swap the spindle drive PCB without realigning the drive, so instead I measured the winding resistance of the stepper motor - both coils measured at 130 Ohms, which seems OK. It's obviously neither burnt nor shorted. Swapping in the main drive PCB into the drive that failed with the burning smell indeed resulted in a fully working drive.

Then I took a closer look at the main drive PCB of the burnt drive. And finally I found a black spot on L2, the interference inductor on the +5V supply. That inductor was no longer conducting any current, so obviously it doubled as fuse. I searched the whole PCB for shorted semiconductors or electrolytics, but didn't find any. Furthermore, as the speed signal works, and that signal is created by an 74HC14 chip connected to the 5V supply, obviously the 5V supply can not be shorted to ground. I measured the 5V rail on the drive, and obtained 3.6V. I guess that's source from data signals through ESD protection diodes (see EEVBlog #831 for details on how stuff like that happens to work sometimes), but this clearly indictates the short is gone. As I don't have a 68µH inductor at hand, I replaced the broken inductor by a FM ferrite bead with 3 turns, which I had in my parts bin, and that PCB now works "fine". I guess a capacitor (possibly the tantalum one) on the PCB shorted out for a moment, but is open now.

So at the moment, I have 1 working drive, but as soon as the 1µF X7R caps and the soldering supplies are in, I most likely have all three drives working fine again.

Reply 3 of 47, by mkarcher

User metadata
Rank l33t
Rank
l33t
Caluser2000 wrote on 2021-01-01, 17:13:

It'would be faster to just put a generic 3.5 ffd with power using a standard molex connector attached to the psu.

The PSU in the PS/2 model 30 has no molex connectors (and no 3,5" floppy connectors). The only connection on that supply is the AT-style (i guess...) mainboard connector. You also need to adapt a standard drive, because if I remember correctly, some signal on the PS/2 floppy drive uses inverted logic compared to PC drives. It might have been only the density select pin, which is not a thing on the 720K drives from the non-286 PS/2 model 30, so maybe that issue wouldn't have applied in my case.

Finally, this thread is about fixing those floppy drives, because "I recently found this old PS/2, but no floppy drive works in that thing" is a recurrent theme on retro YouTube channels recently, not about just any way to get the machine running. Mounting a standard drive instead of the PS/2 specific larger 1.6" ("half height") drives would not fit the front bezel and destroy the nice look of that old computers - and last but not least, I enjoy the challenge of fixing retro hardware.

Reply 5 of 47, by konc

User metadata
Rank l33t
Rank
l33t

Oh man I love thread like this so much. Well done and thank you for the detailed description.
On a side note, I thought that electrolytic capacitors going bad in these PS/2 drives are a common issue and people just go and replace them all first thing after cleaning the heads?

maxtherabbit wrote on 2021-01-01, 18:32:

For future reference the program ImageDisk contains a built in RPM test function. Great work reversing the motor PCB btw!

Yes, provided that you can get it somehow on the machine and run it! There are always ways of course but it's tricky sometimes

Reply 6 of 47, by Caluser2000

User metadata
Rank l33t
Rank
l33t
konc wrote on 2021-01-01, 19:07:

Oh man I love thread like this so much. Well done and thank you for the detailed description.
On a side note, I thought that electrolytic capacitors going bad in these PS/2 drives are a common issue and people just go and replace them all first thing after cleaning the heads?

Yeah It's been a known issue since the late '90s. It's the reason I don't bother collecting PS/2 systems.

There's a glitch in the matrix.
A founding member of the 286 appreciation society.
Apparently 32-bit is dead and nobody likes P4s.
Of course, as always, I'm open to correction...😉

Reply 7 of 47, by mkarcher

User metadata
Rank l33t
Rank
l33t
konc wrote on 2021-01-01, 19:07:

Oh man I love thread like this so much. Well done and thank you for the detailed description.
On a side note, I thought that electrolytic capacitors going bad in these PS/2 drives are a common issue and people just go and replace them all first thing after cleaning the heads?

I didn't google for that problem. I guess I would have found enough forum entries talking about recapping these drives that I knew what to do. If I had my ESR meter at hand (moved out from my parents like 7 years ago, most modern tools at my home, a lot of "now retro" stuff at my parent's home), maybe I would have checked the caps first. Nevertheless, a very interesting endeavour. You could easily see the 620Hz (or so) speed sensor sine wave (which I missed at first, because it is so low amplitude) at one end of the DC blocking cap, but the signal was extremely distorted at the other end of the cap. On my initial check, I measured just "flat line" (0.1V/div, 10x attenutaion at the probe) at the frequency sensor pins and concluded that the frequency sensor section of the motor controller chip is unused in favour of the external index circuitry. Only when getting deeper into it, I noticed that the index meter and the speed for regulation are two completely separate things. The actual signal is around 20 to 30mVpp, thus nicely visible at 0.01V/div, 1x attenuation, which is 100x more sensitive than the scope setting on the first inspection. The 0.1V/div, 10x were good to observe the oscillation of the reference crystal, though.

Reply 8 of 47, by maxtherabbit

User metadata
Rank l33t
Rank
l33t

The OP never specified a drive model, but I compared the motor PCB described here to my Alps DFL413C02B from my IBM 4865 External 3.5" drive and it's an exact match.

My drive apparently has a perfectly working motor PCB, just tested and I'm getting a 5Hz signal from the index wire (blue) but I am not getting an index pulse on the edge connector. Care to take a shot at reversing the logic PCB for me? lololol

Reply 9 of 47, by canthearu

User metadata
Rank Oldbie
Rank
Oldbie

Yep, I've had to replace the electrolytic capacitors on multiple different floppy drives. Some of them are non-polarized, so make sure you get the right ones.

The most notable replacement was for a HP PC-305 XT class machine. It uses a custom 1.44 floppy drive along with a special version of MS-DOS (Version 3.3 or 4.0) to correctly work with this floppy drive.

Using a normal 1.44meg Floppy drive results in only being able to use it as 720KB drive.
Using a normal version of DOS results in difficulty detecting 1.44meg floppy disks in this drive.

Thus, getting the original drive working was quite important, as replacing it properly would be a pain.

Reply 10 of 47, by mkarcher

User metadata
Rank l33t
Rank
l33t
maxtherabbit wrote on 2021-01-02, 18:17:

The OP never specified a drive model, but I compared the motor PCB described here to my Alps DFL413C02B from my IBM 4865 External 3.5" drive and it's an exact match.

My drive apparently has a perfectly working motor PCB, just tested and I'm getting a 5Hz signal from the index wire (blue) but I am not getting an index pulse on the edge connector. Care to take a shot at reversing the logic PCB for me? lololol

I'm sorry I forgot to mention the drive model. It's mentioned in the GitHub repository (actually already in the name of the repository, and thus in the picture URLs). It's a ALPS DFL413C04A.

Are you aware that the edge connector is supposed to have the index signal driven only if the drive is selected? So you need to ground DS1 (Pin 12) on the edge connector, otherwise the drive is passive on the Shugart Bus. If you lost the DS jumper (should be installed in DS1), you obviously can not select the drive at all.

Reply 11 of 47, by maxtherabbit

User metadata
Rank l33t
Rank
l33t
mkarcher wrote on 2021-01-04, 16:28:

Are you aware that the edge connector is supposed to have the index signal driven only if the drive is selected? So you need to ground DS1 (Pin 12) on the edge connector, otherwise the drive is passive on the Shugart Bus. If you lost the DS jumper (should be installed in DS1), you obviously can not select the drive at all.

Yes of course. I ended up grabbing another one of these drives (nonworking) off ebay for relatively cheap. I took its logic board and swapped it over to my original drive and its now working 100%. Ironically the second parts drive I bought has the same symptom as yours - I measure the index pulse off the motor board at about 13.2Hz or 792RPM. I could repair that motor PCB but meh since I would still only have one working drive either way. I'll save it for parts.

Reply 12 of 47, by tony359

User metadata
Rank Member
Rank
Member

I've been pointed here as I also have a PS2 with dead HDD and dead Floppy!

Mine is the same model of the OP. The behaviour is that the motor spins (I will check the speed soon) the head seems to be kind of stuck. Let me explain. The head makes a very small movement when I power up but then nothing. I manually moved the head forward and it correctly moves to track zero when it powers up - but then nothing.

Here a video I made. It's from the moment I turn on to when the PC beeps with some errors (the floppy is not the only issue there but that's for a later moment!). You can's see that but the disk is spinning.

https://www.youtube.com/watch?v=3IKZg-W0lhQ

Is this drive supposed to do a proper "seek" during post? Not just a small wiggle?

I was not aware of capacitors so I guess I'll start checking them all. Thank you a bunch, I'll report back here.

My Youtube channel: https://www.youtube.com/@tony359

Reply 13 of 47, by mkarcher

User metadata
Rank l33t
Rank
l33t
tony359 wrote on 2022-12-16, 09:47:

Is this drive supposed to do a proper "seek" during post? Not just a small wiggle?

If I remember correctly, the IBM PS/2 model 30 BIOS doesn't include the classic boot-up floppy seek procedure. It would be pointless in that machine, as the only point of that procedure is to tell 40-track drives from 80-track drives, which is intended for 5,25" drives. AT 5,25" HD drives have a higher rotational speed (360 rpm) and thus need a different configuration to read 360KB disks than XT 5,25" DD drives at 300 rpm. That's why it's important to detect the drive type for 5,25" drives.

The PS/2 model 30 never supported 40-track drives, so if this procedure were included in the post, that would just be cargo cult (which it also is in all AT-class machines with CMOS setup in ROM). The AT is supposed to read the floppy drive type from CMOS RAM, so no auto-detection is required. The only valid use-case for drive type detection is the case of a system that has the CMOS setup tool on a floppy disk, and you need to be able to boot from a floppy disk with the setup tool even if the CMOS settings are lost or the drive has just be swapped with a drive of a different type.

You observe a single recalibration of the floppy drive (moving the head to track 0), possibly followed by a single wiggle to detect whether the stepper motor actually works, which seems fine for the PS/2 model 30. In the video I linked in your HDD issue thread, you also don't hear the classic seek sound, even with a working floppy drive at https://youtu.be/61UbTmlTWSU?t=469 . You hear some head movement action, but I interpret that sound just as the head not being in home position on power-on. You can compare the head movement sound with your drive, when you moved the head to around 30% to 50% of the distance between track 0 and track 79.

Reply 14 of 47, by tony359

User metadata
Rank Member
Rank
Member

The guy in the video says "the difference is that the floppy drive seeks in this machine" making me assuming that the seeking noise happens every time he boots?

Now, before digging into the floppy, I need to fix a memory issue with this computer. It only sees 128K and shows a memory error. Chances are the floppy is not working because the memory is not working/corrupted etc. I don't want to invest time on the drives before the motherboard is fully up and running.

That said, thanks for the important pointers. I shall come back to this thread when I start working on that drive again!

My Youtube channel: https://www.youtube.com/@tony359

Reply 15 of 47, by mkarcher

User metadata
Rank l33t
Rank
l33t
tony359 wrote on 2022-12-16, 20:12:

The guy in the video says "the difference is that the floppy drive seeks in this machine" making me assuming that the seeking noise happens every time he boots?

He uses the floppy drive for booting, so it is very likely that after booting (or starting applications) from that floppy drive, the head doesn't end up on track zero. In that case, a "return to zero" sound on every boot is expected.

tony359 wrote on 2022-12-16, 20:12:

Now, before digging into the floppy, I need to fix a memory issue with this computer. It only sees 128K and shows a memory error. Chances are the floppy is not working because the memory is not working/corrupted etc. I don't want to invest time on the drives before the motherboard is fully up and running.

DOS 3.3 should be bootable to its prompt with just 128KB. The IBM PS/2 model 30 8086 has 128KB of memory on board, and is upgradable to 640KB using two 256KB SIMMs in the two SIMM slots. You need to pair SIMMs, because the 8086 processor accesses the main memory through a 16-bit data bus. If you remove the SIMMs, the machine should work fine with just the onboard memory. You can't run bigger DOS applications at 128KB, though.

Reply 16 of 47, by tony359

User metadata
Rank Member
Rank
Member

ah, then the SIMMs are not working at all! I will be looking into the PS2 in some time but I guess I will remove the SIMMs and test. If the memory error goes away then I can test the drives. I wasn't aware that 128K lived on the board and thought that only a fraction of the SIMMs were being recognised - and assuming that maybe code was trying to run in bad memory areas.

Thanks again for the extra info!

My Youtube channel: https://www.youtube.com/@tony359

Reply 17 of 47, by tony359

User metadata
Rank Member
Rank
Member

On this subject, while I try to fix the PS/2 drive, I'd like to build an adaptor for a standard 1.44MB unit. The read-made PCBs from TexElec would be great but they charge an arm and a leg in shipping so I found the below

https://github.com/schlae/PS2FloppyAdapter

and I thought I could order some to build myself.

However, I see the PCB does not have the "key" which my PS/2 30 has. The description says it's compatible with models 50 and 60. Can I assume the pinouts are the same between the 30 and other models? I don't mind having to carve a slot in the PCB as long as it works.

Thank you!

Attachments

My Youtube channel: https://www.youtube.com/@tony359

Reply 18 of 47, by eisapc

User metadata
Rank Member
Rank
Member

The PS/2 floppy drives are well known for failing capacitors.
see also IBM PS/2 floppy disk drive restore / repair
Been there, done that. Good job.
Replacement with a standard drive will also spoil the front panel view.
IBM used special drive fillers not compatible with standard drives (apart from the electrical modifications needed).

@tony359
Are the failing memory modules original?
The model 30 uses slightly different memory layout than standard PC. Here is an explanation and a conversion instruction:
http://john.ccac.rwth-aachen.de:8000/misc/ps2cache/

Reply 19 of 47, by tony359

User metadata
Rank Member
Rank
Member

Amazing thanks! I do not know about the RAM, I haven't inspected the MB yet but that document is super-useful thanks!

I'll resume the project soon. The adaptor for a standard drive is mainly to work on issues one at a time: I'd like to sort the memory first and be able to run some diagostics. THEN, move to the floppy. What I don't want it a system which fails to run the diagnostic software and I don't know if it's the floppy or the RAM 😀

Thanks a lot!

My Youtube channel: https://www.youtube.com/@tony359