The first Ukrainian SSD drive or the second life of a Swiss computer
Unfortunately, a huge number of enterprises in Ukraine operate on outdated industrial equipment manufactured a couple of dozen or more years ago. After the collapse of the Union and the sale of locally-developed machine tools to metal, the enterprises that remained afloat began to acquire second-hand numerically controlled machines in the west: plasma cutters, wood, metalworking machines, engraving equipment, etc. But the relatively low cost of such iron has a downside - downtime due to failures, unavailability of spare parts, and a complete lack of support.
This post is about how a simple replacement of a hard drive in a woodworking machine required the creation of our own solid-state drive, and what difficulties we encountered in its development. Who cares how the first Ukrainian "Winchester-SSD" was created, I ask for cat.
At first, a little background. A few years ago, a customer with a faulty Seagate 1.2 GB laptop drive, 1997 release, turned to the information recovery center of a well-known Kiev company.
Winchester was used in the machine, so when he still served his, production stopped. There were no special problems with data recovery, a full copy was made within an hour, and the happy client left for Zhytomyr. But that day he visited Kiev several more times. Several copies on different disks stubbornly did not start on the machine. Fortunately, the same Seagate ST91351AG was found in the donor drive warehouse, the recovered data was written to it and it worked.
About a year later, the situation repeated itself, but the drive was already looking for longer - at that time it was not even on ebay. And again, the customer was saved by the donor warehouse accumulated over many years - on the far shelf they found and probably revived one of the last disks of this model in the world.
Donor Disks at the Information Recovery Center
This time, the client was asked to think about switching to flash, even the IDE Flash module was found, adapters were made to connect it to the machine, and a drive passport was changed. But the customer decided not to bother, and after the first unsuccessful attempt to boot from him, he abandoned this idea.
One of the first adapters.
A few months ago, the disk returned again. This time, it was obvious that constantly looking for disks more than 15 years ago was not an option, and modernization of the machine, its transfer to modern media, was necessary. As a solution, it was proposed to switch to flash. There were several reasons for this choice, but the main one was that SSDs are much more resistant to vibration than hard drives.
This decision marked the beginning of a large series of studies and experiments that culminated in the development and manufacture in two months of a working version of its own solid-state drive based on flash memory. This is not exactly an SSD, but rather a specialized IDE-to-CompactFlash adapter for industrial equipment with a number of unique features.
But first, an attempt was made to solve the problem, as they say, in the forehead. We collected several different IDE Flash modules and CompactFlash cards, copied the recovered data to them, and went on a trip to Zhytomyr.
Our ward - IMA BIMA woodworking machine
But not one of the flash drives was able to boot into the machine. With any BIOS settings and connection modes, boot attempts resulted in a disk read error. An attempt was made to correct the boot sector, as a result, the error disappeared, but the system crashed immediately after the start.
When it became clear that the problem could not be solved by cavalry, we disassembled the machine, dismantled the operator panel and industrial computer and took the equipment to our research.
Research stand
Since it was not possible to stop production for any long period of time, in parallel we assembled our own test bench of the computer on a 486DX2 processor, with 16 MB of RAM. Due to this, as well as the fact that we were able to repair the “last” Seagate ST91351AG, production downtime was avoided during the development of our drive.
The control computer of the NUM 1062W machine, by the way "purebred Swiss", was developed and assembled by NUM in 1998 in the industrial version 486DX2-66 with 24 MB of RAM. According to the service marks on the machine, the last time it was serviced was in 1999, while still in Germany. Then prevention was carried out, and after that he worked smoothly until 2010, when the hard drive first failed.
"System" NUM 1062W
The OS / 2 WARP, now forgotten now, is used as the operating system in this industrial computer; the machine is controlled using special application software.
Much of the research and experimentation has been done using the EPOS ATA Analyzer protocol analyzer.
Protocol analyzer EPOS ATA Analyzer
The analyzer is a compact device that plugs into the gap between the system under study and a drive with a SATA or PATA interface and intercepts all the commands and data that they exchange. The collected information (exchange protocol) is transmitted via USB to a separate tool computer, where it is processed using special software.
The analyzer has repeatedly helped us out in such situations, the greater was our surprise when it turned out that some “garbage” was transmitted via the IDE bus, and not standard ATA commands.
When analyzing such an incorrect behavior of the analyzer with a Swiss computer, I had to remind myself of the architecture of 486 compatible motherboards. The reason was found - the IDE interface controller on the motherboard sent signals with a level of 5V to the bus. Currently, according to the requirements of the ATA standard, they must have a level of 3.3V, so all modern controller microcircuits simply could not correctly interpret the commands that were transmitted through the interface.
The solution in such a situation seemed obvious. We set about developing and manufacturing a level converter. Moreover, according to the results of experiments, we have already managed to launch the operating system from the original Seagate ST91351AG on our test bench. Test copies on CompactFlash and IDE Flash also downloaded OS / 2 WARP on a bench PC.
A couple of weeks later we got printed circuit boards and assembled a level converter. With its help, the first protocols for exchanging data with drives were obtained. And then it turned out that the problem was not at all non-standard levels on the bus. Moreover, as a result of a thorough examination of the motherboard, it turned out that the problem of overvoltage was caused by a malfunctioning IDE buffer chip of the controller (74ACT16245DGGE4). She was replaced and research continued.
Inoperative buffer chip on the motherboard
At that time, the intermediate results were as follows. On our testbed, OS / 2 WARP was loaded from both the original Seagate and virtually any hard drive, IDE Flash and CompactFlash. But only Seagate was still running on the test computer.
The question was definitely not related to a specific drive - this version was dropped by one of the first. The check was done using a disk passport emulator developed on the basis of ATA Analyzer. The essence of the emulator is quite simple - when intercepting the IDENTIFY DEVICE command (it gives all the disk configuration information - model, serial number, supported modes, etc.), it does not translate the command to the connected disk, but returns the passport we need to the host.
To find out why this Seagate is so special, dozens of protocols were removed and carefully analyzed using an analyzer. They were almost identical with a slight correction for different platforms - i.e. the command sets and the transmitted data during the initialization of the disk on the test computer and the test bench coincided. But after a certain moment, something incomprehensible happened, which resulted in the inability to boot from any drives to the NUM 1062W.
A fragment of one of the protocols
We tried more than two dozen disks - peers of the ill-fated seigate, but none of them allowed to boot the system. However, the large amount of data collected made it possible to localize the time of the download failure. This moment was very carefully analyzed at the logical and signal levels.
The problem turned out to be an error in the implementation of the data transfer protocol between the host and the disk. In fact, at a certain point in time, the IDE controller of the NUM 1062W motherboard formed on the bus such a state that is not described in any version of the ATA standard. By standard, such conditions should be discarded by any drive with an error message. All disks reacted correctly to this state, except for the Seigate, which ignored it and proceeded to processing further commands.
Thus, complementary errors in the IDE controller and in the firmware of the disk led to the creation of a unique system of binding the disk to the equipment. It seems to me that at the stage of motherboard development, debugging was carried out with such a sigeyte, and when it turned out that other disks didn’t work very well, it became a feature.
Unfortunately, our requests to the computer developer did not bring tangible benefits. The only thing we were able to achieve from the Swiss was that such equipment has long been discontinued and is not supported, but if we need service documentation, they are ready to provide it, naturally for a fee. However, they reported that the documentation does not contain circuitry and wiring diagrams, and they cannot provide such information due to its absence.
When the problem was clearly identified, we started developing a disk emulator directly for a specific machine. First of all, the layout of the future device was developed. Its basis was the debug board of the device for servicing hard disks, developed earlier for another project, built on the Atmel microcontroller. With this layout, for the first time, we successfully booted onto the NUM 1062W from IDE Flash drives and CompactFlash cards.
Debugging layout
After that, it was decided to conduct testing in "combat conditions" - directly at the factory. We went to Zhytomyr to the customer’s production site, where we connected the model of the future drive developed by us to the machine. Oh miracle - it all worked, and positive results were obtained for both IDE Flash modules and CompactFlash cards.
Tests of the layout in "combat conditions"
After a trial run, several copies of solid-state drives in the 2.5 "form factor with the IDE interface were made. They use an industrial CompactFlash card as the carrier. The first Ukrainian “SSD-drive” was called the Hard Disk Emulator for industrial equipment.
Original disk, debug layout, final version of our disk.
Device of our disk
In addition, during the testing of the layout in production, it turned out that the control programs for the machine are carried on floppy disks. This creates great inconvenience for employees, since floppy disks do not last long in production conditions. According to the customer, one floppy disk is enough for recording 3-5 control programs, after which it needs to be changed. Therefore, we proposed replacing the drives with FDD emulators based on USB flash drives. As a result of this additional upgrade, the IMA BIMA processing center has been completely transferred from magnetic storage technologies to modern solid state media.
Summary:
• The non-trivial problem of replacing obsolete magnetic drives (HDD and FDD) with modern solid-state drives based on Flash memory was solved, which allowed to extend the life and increase the reliability of operation of a CNC woodworking machine.
• The HDD emulator developed by us has a number of special functions, including the ability to replace passports, modify the protocol on the fly, and fix undocumented data exchange errors. Thanks to this, it is possible to upgrade almost any industrial equipment and non-standard specialized equipment that use outdated hard drives with an IDE interface.
PS We are currently working on an analogue for the SCSI interface, which is widely used, for example, in medical technology. If the topic is interesting, in the following posts I will try to describe what we do in this direction.
This post is about how a simple replacement of a hard drive in a woodworking machine required the creation of our own solid-state drive, and what difficulties we encountered in its development. Who cares how the first Ukrainian "Winchester-SSD" was created, I ask for cat.
At first, a little background. A few years ago, a customer with a faulty Seagate 1.2 GB laptop drive, 1997 release, turned to the information recovery center of a well-known Kiev company.
Winchester was used in the machine, so when he still served his, production stopped. There were no special problems with data recovery, a full copy was made within an hour, and the happy client left for Zhytomyr. But that day he visited Kiev several more times. Several copies on different disks stubbornly did not start on the machine. Fortunately, the same Seagate ST91351AG was found in the donor drive warehouse, the recovered data was written to it and it worked.
About a year later, the situation repeated itself, but the drive was already looking for longer - at that time it was not even on ebay. And again, the customer was saved by the donor warehouse accumulated over many years - on the far shelf they found and probably revived one of the last disks of this model in the world.
Donor Disks at the Information Recovery Center
This time, the client was asked to think about switching to flash, even the IDE Flash module was found, adapters were made to connect it to the machine, and a drive passport was changed. But the customer decided not to bother, and after the first unsuccessful attempt to boot from him, he abandoned this idea.
One of the first adapters.
A few months ago, the disk returned again. This time, it was obvious that constantly looking for disks more than 15 years ago was not an option, and modernization of the machine, its transfer to modern media, was necessary. As a solution, it was proposed to switch to flash. There were several reasons for this choice, but the main one was that SSDs are much more resistant to vibration than hard drives.
This decision marked the beginning of a large series of studies and experiments that culminated in the development and manufacture in two months of a working version of its own solid-state drive based on flash memory. This is not exactly an SSD, but rather a specialized IDE-to-CompactFlash adapter for industrial equipment with a number of unique features.
But first, an attempt was made to solve the problem, as they say, in the forehead. We collected several different IDE Flash modules and CompactFlash cards, copied the recovered data to them, and went on a trip to Zhytomyr.
Our ward - IMA BIMA woodworking machine
But not one of the flash drives was able to boot into the machine. With any BIOS settings and connection modes, boot attempts resulted in a disk read error. An attempt was made to correct the boot sector, as a result, the error disappeared, but the system crashed immediately after the start.
When it became clear that the problem could not be solved by cavalry, we disassembled the machine, dismantled the operator panel and industrial computer and took the equipment to our research.
Research stand
Since it was not possible to stop production for any long period of time, in parallel we assembled our own test bench of the computer on a 486DX2 processor, with 16 MB of RAM. Due to this, as well as the fact that we were able to repair the “last” Seagate ST91351AG, production downtime was avoided during the development of our drive.
The control computer of the NUM 1062W machine, by the way "purebred Swiss", was developed and assembled by NUM in 1998 in the industrial version 486DX2-66 with 24 MB of RAM. According to the service marks on the machine, the last time it was serviced was in 1999, while still in Germany. Then prevention was carried out, and after that he worked smoothly until 2010, when the hard drive first failed.
"System" NUM 1062W
The OS / 2 WARP, now forgotten now, is used as the operating system in this industrial computer; the machine is controlled using special application software.
Much of the research and experimentation has been done using the EPOS ATA Analyzer protocol analyzer.
Protocol analyzer EPOS ATA Analyzer
The analyzer is a compact device that plugs into the gap between the system under study and a drive with a SATA or PATA interface and intercepts all the commands and data that they exchange. The collected information (exchange protocol) is transmitted via USB to a separate tool computer, where it is processed using special software.
The analyzer has repeatedly helped us out in such situations, the greater was our surprise when it turned out that some “garbage” was transmitted via the IDE bus, and not standard ATA commands.
When analyzing such an incorrect behavior of the analyzer with a Swiss computer, I had to remind myself of the architecture of 486 compatible motherboards. The reason was found - the IDE interface controller on the motherboard sent signals with a level of 5V to the bus. Currently, according to the requirements of the ATA standard, they must have a level of 3.3V, so all modern controller microcircuits simply could not correctly interpret the commands that were transmitted through the interface.
The solution in such a situation seemed obvious. We set about developing and manufacturing a level converter. Moreover, according to the results of experiments, we have already managed to launch the operating system from the original Seagate ST91351AG on our test bench. Test copies on CompactFlash and IDE Flash also downloaded OS / 2 WARP on a bench PC.
A couple of weeks later we got printed circuit boards and assembled a level converter. With its help, the first protocols for exchanging data with drives were obtained. And then it turned out that the problem was not at all non-standard levels on the bus. Moreover, as a result of a thorough examination of the motherboard, it turned out that the problem of overvoltage was caused by a malfunctioning IDE buffer chip of the controller (74ACT16245DGGE4). She was replaced and research continued.
Inoperative buffer chip on the motherboard
At that time, the intermediate results were as follows. On our testbed, OS / 2 WARP was loaded from both the original Seagate and virtually any hard drive, IDE Flash and CompactFlash. But only Seagate was still running on the test computer.
The question was definitely not related to a specific drive - this version was dropped by one of the first. The check was done using a disk passport emulator developed on the basis of ATA Analyzer. The essence of the emulator is quite simple - when intercepting the IDENTIFY DEVICE command (it gives all the disk configuration information - model, serial number, supported modes, etc.), it does not translate the command to the connected disk, but returns the passport we need to the host.
To find out why this Seagate is so special, dozens of protocols were removed and carefully analyzed using an analyzer. They were almost identical with a slight correction for different platforms - i.e. the command sets and the transmitted data during the initialization of the disk on the test computer and the test bench coincided. But after a certain moment, something incomprehensible happened, which resulted in the inability to boot from any drives to the NUM 1062W.
A fragment of one of the protocols
We tried more than two dozen disks - peers of the ill-fated seigate, but none of them allowed to boot the system. However, the large amount of data collected made it possible to localize the time of the download failure. This moment was very carefully analyzed at the logical and signal levels.
The problem turned out to be an error in the implementation of the data transfer protocol between the host and the disk. In fact, at a certain point in time, the IDE controller of the NUM 1062W motherboard formed on the bus such a state that is not described in any version of the ATA standard. By standard, such conditions should be discarded by any drive with an error message. All disks reacted correctly to this state, except for the Seigate, which ignored it and proceeded to processing further commands.
Thus, complementary errors in the IDE controller and in the firmware of the disk led to the creation of a unique system of binding the disk to the equipment. It seems to me that at the stage of motherboard development, debugging was carried out with such a sigeyte, and when it turned out that other disks didn’t work very well, it became a feature.
Unfortunately, our requests to the computer developer did not bring tangible benefits. The only thing we were able to achieve from the Swiss was that such equipment has long been discontinued and is not supported, but if we need service documentation, they are ready to provide it, naturally for a fee. However, they reported that the documentation does not contain circuitry and wiring diagrams, and they cannot provide such information due to its absence.
When the problem was clearly identified, we started developing a disk emulator directly for a specific machine. First of all, the layout of the future device was developed. Its basis was the debug board of the device for servicing hard disks, developed earlier for another project, built on the Atmel microcontroller. With this layout, for the first time, we successfully booted onto the NUM 1062W from IDE Flash drives and CompactFlash cards.
Debugging layout
After that, it was decided to conduct testing in "combat conditions" - directly at the factory. We went to Zhytomyr to the customer’s production site, where we connected the model of the future drive developed by us to the machine. Oh miracle - it all worked, and positive results were obtained for both IDE Flash modules and CompactFlash cards.
Tests of the layout in "combat conditions"
After a trial run, several copies of solid-state drives in the 2.5 "form factor with the IDE interface were made. They use an industrial CompactFlash card as the carrier. The first Ukrainian “SSD-drive” was called the Hard Disk Emulator for industrial equipment.
Original disk, debug layout, final version of our disk.
Device of our disk
In addition, during the testing of the layout in production, it turned out that the control programs for the machine are carried on floppy disks. This creates great inconvenience for employees, since floppy disks do not last long in production conditions. According to the customer, one floppy disk is enough for recording 3-5 control programs, after which it needs to be changed. Therefore, we proposed replacing the drives with FDD emulators based on USB flash drives. As a result of this additional upgrade, the IMA BIMA processing center has been completely transferred from magnetic storage technologies to modern solid state media.
Summary:
• The non-trivial problem of replacing obsolete magnetic drives (HDD and FDD) with modern solid-state drives based on Flash memory was solved, which allowed to extend the life and increase the reliability of operation of a CNC woodworking machine.
• The HDD emulator developed by us has a number of special functions, including the ability to replace passports, modify the protocol on the fly, and fix undocumented data exchange errors. Thanks to this, it is possible to upgrade almost any industrial equipment and non-standard specialized equipment that use outdated hard drives with an IDE interface.
PS We are currently working on an analogue for the SCSI interface, which is widely used, for example, in medical technology. If the topic is interesting, in the following posts I will try to describe what we do in this direction.