We make a generator from a CD drive. How to make a CD-ROM on a flash drive What can be made from a DVD drive motor

Before you throw away your old drive that runs an electric motor or laser, you might want to think about how you can still use it. In fact, there is a use for it, although not as a player or reading device.

To regulate the rotation speed, power is supplied to the electric motor through a rheostat to slow down the rotation speed. A neat round stand is installed on the rotating part, and the device is ready.

A Chinese pointer can serve as a housing for the device, and a laser diode is removed from a DVD or CD-RW drive (a weaker version is a CD-R drive). Visually, it resembles a schematic image of a hat. You will need the top and middle contacts of the diode, as plus and minus, respectively. Power is supplied from two AA batteries. Attention! It is strictly forbidden to shine a pointer into the eyes of people and animals!

The idea is simple, like everything ingenious - all the contents are removed from the case of a faulty CD drive, without removing the front panel, and make sure that the buttons do not fall out of it. The cache turns out to be quite impressive, and a metal detector will not reveal it.

Grinder

A device with a working electric motor can easily serve as a small sharpening machine for sharpening drills or small knives. To do this, you need to remove the top cover of the drive, stick the abrasive on the CD and slightly improve it, as shown in the video:

To create a fan, you will need a 6-volt electric motor, an impeller, a motor holder, and a DC source, such as a power supply or AA batteries.

More ideas...

How else to use your outdated device? The driving mechanism of the laser is used to make engravers, cutters, and plotters. Use the lens in a homemade microscope. The use of the housing, laser and engine was discussed above. If the device is still working, you can connect speakers and a power supply to it, you will get a player. As a last resort, you can donate it or sell it for spare parts.

CD-ROM on a flash drive is a very convenient thing. This is 100% compatible with ISO images and guaranteed to work from the computer's BIOS. This will allow you to boot from a flash drive like a regular CD-ROM. That is, the computer will never know that it is being “deceived.”

The era of optical drives is ending. In modern computers, a CD-ROM drive (DVD, DVD-ROM, DVD-RW, CD-RW) is becoming a rarity. Therefore, users have to “get out” in every possible way when they need to install the operating system. In order not to look for an external USB optical drive, it has long been possible to boot from a flash drive. And all modern computers have such support in the BIOS. But no, no, yes, a situation arises like in Viktor Tsoi’s song “everything is in place, but something is wrong.” Many times I came across a situation where the computer booted from only one flash drive out of five. And the only way out of this situation is to create (emulate) a CD-ROM on a USB flash drive. That is, when the computer sees the USB flash drive as a real optical drive.
There are many solutions on the Internet regarding this matter. They all present a bit of a puzzle. In which you first need to find out the type of controller on the flash drive, the organization and model (brand) of memory. Then, for this hardware, you need to find a special program to reprogram the controller and upload an ISO image. At the same time, not all controllers used in flash drives have the ability to emulate CD-ROMs. That is, it’s not a fact that your flash drive can do this at all. And the saddest thing is that even if you follow all the instructions exactly, there is a high chance of ruining the flash drive.
The ideal option in such a situation is to purchase a flash drive for which the manufacturer itself has provided the possibility of creating a CD-ROM. One day I came across a Transcend JetFlash 620 8Gb flash drive.

A distinctive feature of which is the presence of a built-in virtual CD-ROM. This means that the controller supports the creation of CD-ROMs and we are halfway to success.

How to create a CD-ROM on a Transcend JetFlash 620 8Gb flash drive

To create a CD-ROM on a Transcend JetFlash 620 8Gb flash drive, you need to download the diagnostic and recovery utility for this USB drive model JetFlash Online Recovery from the official website. At the time of writing, the current version of the program for Windows is v9.0.0.8 (JetFlash 620) for the Transcend JetFlash 620 8Gb flash drive. The program size is 5.7 MB.
After downloading the archive, you will need to unpack the EXE file contained in it. For me it is OnLineRecovery_JF620_v9.0.0.8.exe. This is a self-extracting archive, inside of which there is the OnLineRecovery_620.exe utility and the CD-ROM image file security_f.iso.
So, here is the main secret of this article. In order to create a virtual CD-ROM on a Transcend JetFlash 620 flash drive, you need to rename the ISO image file you need, for example, the operating system installation distribution, to security_f.iso and place it next to the OnLineRecovery_620.exe recovery utility. After that, run the utility and it will create two partitions on the flash drive, one of which will record your ISO image, which will be recognized by computers as a USB-CD-ROM, and the remaining space will be a regular flash drive. It's that simple.
I hope there is no need to warn you that as a result of the JetFlash Online Recovery recovery utility, all data from the flash drive will disappear.

CD-partitions on a flash drive allow you to boot without problems on a PC, where loading from a regular flash drive (With Public- flash drive section) impossible. Download from CD-Areas of a flash drive usually work everywhere.

But you should understand that using a flash drive as a boot device from BIOS, is not the intended purpose of this controller function.

And the main function CDROM- the area is that a specific flash drive manufacturer can place there the necessary software for encryption, virus protection, or simply some advertising information.

Therefore, the successful outcome of loading any component as from a normal CD-drive, mainly depends on the compatibility of the specific controller with a specific motherboard, on which you boot.

WHICH CONTROLLERS ARE MOST SUITABLE

I personally, for use as LiveUSB and reinstallation Windows, I recommend only controllers SMI And Phison, because they are most compatible with older motherboards.

U SMI-chips, the highest loadability from under BIOS showed models SM3257AA and those older (For example SM3257ENAA And SM3257ENLT) .

WITH Phison, problems of a slightly different order, which are only indirectly related to loading efficiency. All controllers can be divided into two groups, in the first there are the so-called PS2XXX (For example PS2232 And PS2239) , and in the second PS2251-XX(For example PS2251-38 And PS2251-03). So, chips from the first group cannot be converted into MODE30, but only in MODE21, which contains an additional flash-section that negatively affects the level of compatibility.

If you don’t have an old computer, then other models will be suitable, but still not all. For example, controllers Alcor, have never been known for their good downloadability and in general this is not their topic.

And here are the chips Innostor who became famous for their USB3.0 models, although they are crooked to load, can simultaneously carry up to 6 ISO-disk images!

Below, utilities for manufacturers will be considered USB-controllers capable of working with CD-section. There you can also find a complete list of hardware flash drives suitable for this purpose.

SEVERAL CDROM PARTITIONS ON ONE FLASH DRIVE

Speaking specifically about simultaneously working CD-ROM areas on a flash drive, then I was able to curb only a few controller manufacturers. These are my favorites SMI controllers, some flash drives Phison and chips used in Chinese counterfeits Chipsbank.

On the USBDev portal, you can find detailed instructions for creating up to 7 simultaneously working SDROMs. At the same time, disk images can be changed in a couple of clicks, bypassing the flashing procedure, which minimizes subsequent risks to the limit!

Also included in the article are two videos that I specially recorded for you, in case the letters are too tough for you.

With chips from Phison, although everything is done much simpler, only under MODE32 Not all flash drives are suitable. Of those that I tried, a little more than half turned out to be suitable for working in this specific mode. Yes and MODE32 limited to only two simultaneously working SDROM ami.

Controllers Chipsbank, I liked least of all in this regard. And the creation process is longer and more tedious. And the likelihood of finding a flash drive of suitable size on it is extremely low. Yes, and the ability to flash two CDROM-section, there are only the latest chips, line CBM2098 And CBM2099.

SMI chips, controllers from Innostor, already mentioned above. They, of course, will never compare in functionality and flexibility with SMI-shki, but they at least have something in terms of multi-booting.

U Innostor, at least one section under CD-Rom, but you can write there up to 6 ISO images and through a special Windows program entitled Innostor AI-Burn, choose the necessary one at a given time.

The operation itself to change the flash drive is a little risky, so it is better not to perform it with flash drives in non-standard buildings ( monoliths, flash drives the size of a coin, ...). That is, so that in case of incorrect completion of the controller firmware, it would be possible to disassemble the case and transfer the flash drive to test mode.

In principle, provided that you do everything correctly, the utility will fit your flash drive and create only a CD-ROM area on the flash drive, then the chance that the flash drive will freeze is very small. It’s not for nothing that I highlighted in bold that it is advisable not to create areas other than CD-ROM. Although some write that it is better to create in addition CDROM-partition is also a flash area into which you can upload files. But I am extremely skeptical about this.

What problems can there be when you create two or more areas on a flash drive:

It is very likely that when you try to return the flash drive to its original state or overwrite ISO-file, the flasher will end with an error and your flash drive will have to be flashed again or it will freeze. In this case, it will have to be converted to test mode and flash it from there. Those. if you have monolithic flash drive, you are taking quite a risk and I think the gamble is not worth the candle.

Not available on all computers. Windows flash section, although the likelihood of this is very, very small.

From under BIOS, with a decent probability, it will not be possible to load via a bootloader (such as GRUB4DOS), elements with flush- areas of the flash drive. Those. V Windows You have everything in good order, but here it’s a bummer, for example, on my computer there is such a battle.

It is possible that even with CDROM-the area does not load at all, which occurs on a very large percentage of old computers. This problem is especially acute for company controllers Innostor.

The flash drive takes noticeably longer to initialize by the computer.

I may be dramatizing the situation a little, but I just want to give you some thoughts in case you run into problems.

HOW TO FLASH TO CDROM

For creating CD-areas on USB-flash drive, you need to select a utility for a specific controller installed in a specific flash drive. Sometimes when selecting, you need to consider the memory chip as the main parameter, but this is already off-topic for this article. Then configure the utilities to work with a specific combination (controller + memory), activate the settings associated with the CDROM area and then specify the path to the disk image itself (for the features of specific utilities, see below in the comments next to the exclamation mark [!]). After such an operation, the flash drive in BIOS will be determined (depending on the settings of the production utility and controller capabilities) either as CDROM-device, or as two devices ( CDROM + regular section).

Also, the quality of the result, oddly enough, depends on the utility used. For example, Alcor did not create utilities with older versions CDROM-area more 4GB or at Skymedi Bootability in LUN2 mode may depend on the version.

Let me clarify the situation with the kind of limitation in 4GB per size ISO-disk image - yes There is no 4GB limit and never was. It all depends on the capabilities of the available software versions for a particular hardware (controller + memory). So for some very old controllers, and also for some not very advanced ones, I'm not familiar with those at all. And the nonsense (about 4GB and others) that often circulates on the Internet is associated only with the mental retardation of those who write it. Often such people have never had more than 1-2 flash drives and at the same time try to teach others. Also a distinctive feature of these idiots are recommendations for searching for software using VID-PID, which are also complete nonsense.

Detailed manuals with pictures for the main controllers will be written and posted in separate articles. So you need to be patient, and I need to scrape together the desire and the deal is in the bag.

WHAT SPECIFIC UTILITIES CAN CREATE A CD-ROM SECTION

List of utilities that allow you to create a CDROM area and their features for the main controllers:

Alcor: AlcorMP_UFD, ALCOR Recovery Tool, FC MpTool, Transcend AlcorMP JF620 Online Recovery, Transcend AlcorMP V15 Online Recovery.
!: To create a Generic Autorun Disk using 'Transcend AlcorMP JF620 Online Recovery', just rename the required image to create a CD partition to security_f.iso, place it next to OnLineRecovery_620.exe and perform the flash drive recovery procedure by running OnLineRecovery_620.exe. After executing OnLineRecovery_620.exe, two partitions are always created: a CD partition with the contents of security_f.iso and a regular partition, defined in Windows as a removable disk in FAT32 format.
!: To create a Generic Autorun Disk using 'Transcend AlcorMP V15 Online Recovery', just rename the required image to create a CD partition to TMUS.iso, place it next to OnLineRecovery_TMUS.exe and perform the flash drive recovery procedure by running OnLineRecovery_TMUS.exe. After executing OnLineRecovery_TMUS.exe, two partitions are always created: a CD partition with the contents of TMUS.iso and a regular partition, defined in Windows as a removable disk in FAT32 format labeled Trend Micro.
!: On flash drives with Alcor controllers up to and including the AU6982 model, it has not yet been possible to create the ‘Autorun’ partition.

ChipsBank: Chipsbank APTool, Chipsbank CBM2093 UMPTool, Chipsbank UMPTool, Chipsbank V88 UMPTool, FlashDiskManager.

Innostor: Innostor MP Tool, AI-Burn, AI Partition.
!: AI-Burn – only overwrites the CD area created using the Innostor MP Tool or AI Partition.
!: AI Partition – only creates a CD area, onto which you can then burn a disk image using AI-Burn.

iTE Tech. Inc. : MPTool, DtMPTool, UFDUtility, CDROM Tool.

Phison: Phison ModeConverter, Phison MPALL, Phison USB MPTool.
!: Phison ModeConverter v1.0.1.5 is the easiest and safest way to create for modern controllers from Phison.
!: Mode = 30 (CDROM Only); Mode = 21 (CDROM + Public).
!: There may be some problems with the subsequent identification of the flash drive in utilities when creating ‘CDROM\Public + Fixed Disk‘.

Skymedi: Skymedi PDT, Skymedi SK6213 ISO Update Tool.
!: The ‘Autorun Counter’ parameter means the number of times the CDROM partition will appear in the system. In order for the section to work endlessly, enter the value 255 (==unlimited) into this field.

SMI: SMI MPTool, DYNA MPTool, uDiskToolBar, MySDKTest, UFDisk Utilities.

SSS: 3S USB MP Utility, 3S USB OnCardSorting.
!: In the utility windows there are no settings responsible for the CD area of ​​the flash drive, so you need to edit the configuration file used (for example - 6691_CM_T32D2 TSOP 32Gb x 2.INI) as follows: approximately after the section add section where to add the line CDROM_ISO=j:\LIVECD\_2K10\MultiBoot_2k10_2.6.1_conty9.iso(where MultiBoot_2k10_2.6.1_conty9.iso is the file that you want to burn to the CD area).

Not all controllers have the ability to overwrite a CDROM area without re-creating other sections of the flash drive. For example, I know for sure only about two controller companies with which this operation can be carried out, namely:
Innostor: using the AI-Burn utility.

SMI: using the program MySDKTest. Despite the fact that this software fully supports only controllers up to the SM3255AB model inclusive. It can perform the procedure of replacing a disk image with any, even the most modern SMI chip.

You can usually return the flash drive to its original state using the same utilities, as well as some other utilities that you can find on my website.

Users who lived through the early 2000s probably remember the times when films, computer games, programs and music were delivered to our computers only using CD/DVD discs, which were common at that time. Nobody knew about free downloading of data on the Internet, torrents and YouTube. The situation was saved by optical drives, with the help of which information was transferred to the computer’s hard drive.

The rapid development of Internet technologies has called into question the need to have such a component as a “disk drive”. In today's desktop systems and laptops you rarely see a drive. All because of virtual disks, which replaced “blanks” and became commonplace. However, not everyone was able to make a comfortable transition to the new technology. In this article we will try to correct this situation and explain in detail the essence of the creation process, the nuances of use and other questions that have repeatedly arisen for everyone who does not know how to use a virtual CD ROM.

When you might need it

Many may doubt the idea of ​​using an innovation that has caught on with some people and simply continue to use the optical drive, using it to rewrite images and information onto physical media. However, the archaic version loses in some cases, the most common of which are:

  • Missing or faulty disk drive. Any part does not have an eternal service life. Sooner or later, a problem may arise, and it’s good if it does not happen at the most necessary moment (which, according to the “law of meanness,” happens often). In addition, the “system specialist” receiving the disk with information from you may simply not have an optical drive. But a virtual CD-ROM is available on any modern PC (if you devote some time to creating it).
  • Multichannel. I have rarely come across computers that had multiple disk drives at once. Users who often work with recording and reading discs had to constantly rearrange CD/DVDs. There are no such problems with virtual disks, which means you can work with several at once.
  • Convenient data transfer. To exchange information recorded on a disc, you need to personally hand over the media to the receiving party. In the case of virtually recorded images, the transfer is carried out online, over the Internet.

Creating a virtual CD-ROM

To read virtual images (iso files; mdf, bwi, mds and others), you need to create a virtual CD-ROM, which, like an optical drive, reproduces (emulates) data from the drive. You can create a virtual disk using special software, such as Daemon Tools, Virtual Drive. Their operating principle is identical, and the functionality is largely similar. For example, we took the last one listed, since its capabilities and tools are very easy to cope with even for a user who is far from such processes.

  1. First, download the Alcohol 120% program installer using a link from the Yandex disk, or on the developer’s official website. Install it on your computer.
  2. Let's launch the program. First of all, we need to create a virtual CD drive. To do this, in the “Settings” section, select the option "Virtual disk".
  1. In the menu that opens, manually select the number of virtual disks to be created. Confirm the result by clicking on the OK button.

The drive has been successfully created, which we can see in the “Device” panel or in the “My Computer” folder.

  1. Now let's open the finished image. To do this, select the “File” tab, and in the menu that opens, click on “Open…” (or simply use the key combination Ctrl + O).
  1. We find the image file we need, select it with LMB and click on the “Open” button.

The image has been added to the library for processing.

  1. Now you need to read the previously added file. To do this, select the RMB image, and in the drop-down menu select the option "Mount to device".

Work is done. We can see the result in the “Computer” folder, where the installer located in the virtual drive will be listed among the reading devices.

After performing operations with the image, you need to remove it from the virtual drive. To do this, using the Alcohol 120% program, in the menu of available drives, select our BD-ROM with the right mouse button and select the function from the list "Dismantle image". The disk will be empty again.

If you want to remove the virtual drive altogether, you need to repeat similar steps as when creating it:

  1. In the available devices, click on the DVD/CD drive RMB. In the list that appears, click “Properties”.
  1. Set the value back to “0” in the section for selecting the number of virtual disks and click “OK”.

Adding a virtual hard disk

The above opportunities have been available to many for a decade now. The popularity of using a virtual data reader has led to the emergence of a similar phenomenon called a virtual hard disk. This technology allows you to create a file (with a VHD extension) that is displayed in Explorer as a standard partition on your hard drive. Everyone decides for themselves the rationality of using a virtual drive: some reorganize free space on volumes in this way, others even install an OS. Don't forget about the ability to create a secure file container, thus limiting information from attacks by other users.

We will create a virtual hard disk using standard Windows tools (this function is available on Windows 7, 8.1, 10). However, with the help of special software you can achieve a similar result. Daemon Tools Ultra, as well as Disk2vhd, cope with this task most effectively. These programs have separate sections dedicated to creating virtual disks (both drives and drives like HDDs).

  1. Open the “Run” service by simultaneously pressing the Win + R keys. Enter the command diskmgmt.msc into the empty line and click OK.
  1. The service will open "Disk Management". In the control menu, activate the "Action" tab, and in it select "Create a virtual hard disk".
  1. In the window that appears, you need to specify the location of the file to be created, select the format (VHD/VHDX), and also determine the possibility of extending the file.
  1. The file has been created, but the disk has not yet been initialized. By right-clicking on the disk, select the option "Initialize disk".
  1. In the next window, you need to specify the partition style (we recommend GUID if you intend to limit yourself to standard capabilities for working with the allocated space).

Connecting the drive after rebooting the PC

Unfortunately, working with a virtual hard disk requires remounting the VHD/VHDX file after each session is completed. Fortunately, we don’t have to create a new disk, initialize a partition, or create a volume. To return the virtual disk to work (emulate data), you must perform the following steps:


We hope that with the help of our article you learned how to create a virtual disk, and also determined the benefits of using it.

We also watch the video

Despite the fact that many large companies are creating their own options for replacing 3.5" floppy disks, a regular floppy drive still finds its place in the vast majority of PCs, despite the low speed and small volume (Windows 98 boot files alone take up 25% of the floppy disk!). Today, In the era of networks and the Internet, floppy disks are used less and less as a carrier of information. One of their main uses remains loading a PC OS in the case of installing a new disk, testing and configuring specific equipment, checking for viruses, and restoring information from a damaged hard drive.

Unfortunately, even for the simplest of these tasks, the floppy disk space is sorely insufficient (for example, antivirus databases have long exceeded the 1.44 MB mark). The volume of test programs and distributions also does not want to decrease. Of course, you can use drives like IOmega ZIP, LS-120, but a much more common device is CD-ROM. And fortunately, for three years now there has been a standard by which you can boot a PC from this device.

Application options: boot disk for diagnostics, checking for viruses, installing a system from scratch; backup system partition for quick system recovery; CDs with demo versions of software, presentations, videos, slide shows. In the latter version, the PC may not even have a hard drive!

As it turns out, most of the information on the topic of bootable CDs on the Internet is not complete and rigorous. Therefore, I decided to understand the standards myself and try to make some interesting disc. Moreover, with CD-RW it is quite safe :).

Quick Start

What we need:

  • CD-R/RW device. It is highly advisable to use CD-RW at the initial stage, this will make it easy to correct possible errors. However, CDRs are preferred for final creation as they are readable on a larger number of drives
  • blank disk for him
  • Adaptec Easy CD Creator program (CDRWIN, WinOnCD, Nero, etc)
  • boot floppy disk of your OS (preferably with a driver for the CD-ROM device used)
  • PC that can boot from CD-ROM for testing :)

So, everything will work like this:

For an ATAPI device, set the BIOS boot order to start with CD-ROM. If you need to boot from a SCSI CD-ROM, then set the “Boot from CD-ROM” option to “Enable” in the SCSI BIOS (and in the BIOS SETUP, “A” must be in the first place, for example “A,C”). When the PC boots, one of the mentioned BIOSes will display a message on the screen stating that it has detected a bootable CD in the device and it is installed as drive A:. After this, the boot process from this device will begin. If a disk drive is installed on the machine, it will be hidden behind the letter B:, the other disks will not change their names.

When writing to a CD-ROM some other files besides the floppy disk image, access to them is possible only after loading the correct driver and MSCDEX.EXE. This way, when booting from a CD, you can access the entire 640MB of disk capacity.

To achieve this effect:

  1. open Adaptec Easy CD Creator (ECDC)
  2. create a regular disk with the necessary files (leave at least 1.44MB of space for the floppy image)
  3. parameters in CD Layout Properties - ISO9660, Mode 1: CDROM, check "Bootable"
  4. after clicking Ok, the program will ask you to insert a previously prepared system floppy disk into the drive in order to read the image from it
  5. After reading, we see that two more files have appeared in the list of recorded files - BOOTCAT.BIN and BOOTIMG.BIN. The first is the so-called boot image directory, and the second is a byte-by-byte copy of our floppy disk, with which drive A will be emulated at boot time:
  6. The final touch is recording on CD. In TAO mode, the disk can not be closed

Some notes on the plan. Point 3 - in fact, you can create a boot disk with Joilet, it’s just that ECDC does not allow you to check the “Bootable” box in this case. But the choice of "Mode 1" is most likely required. Point 4 - before using the floppy disk, it is advisable to make sure that it is working: try to protect it from writing and boot from it. It is very important to remember that to access regular files on a CD-ROM (not files from a floppy disk), you must run the CDROM driver and MSCDEX. Naturally, they must be on the floppy disk being used and everything must be specified in CONFIG.SYS/AUTOEXEC.BAT. One good example of such a floppy disk is the Startup Disk from Windows 98. It has CD-ROM drivers for many controllers, which makes it possible to use the CD-ROM on both ATAPI devices and many SCSI. You can tweak this floppy disk a little to suit your specific needs. I did this:

List of files:

AUTOEXEC.BAT DRVSPACE.BIN COMMAND.COM FORMAT.COM KEYB.COM MODE.COM SYS.COM VC.COM EGA3.CPI EMM386.EXE FDISK.EXE MSCDEX.EXE VC.INI ASPI2DOS.SYS ASPI4DOS.SYS ASPI8DOS.SYS ASPI8U2. SYS ASPICD.SYS BTCDROM.SYS BTDOSM.SYS CONFIG.SYS COUNTRY.SYS DISPLAY.SYS FLASHPT.SYS HIMEM.SYS IO.SYS KEYBRD3.SYS MSDOS.SYS OAKCDROM.SYS

Files=10 buffers=10 dos=high,umb stacks=9,256 lastdrive=z device=himem.sys /testmem:off device=emm386.exe ram device=display.sys con=(ega,1) country=007,866,country. sys device=oakcdrom.sys /D:MSCD001 device=btdosm.sys device=flashpt.sys device=btcdrom.sys /D:MSCD001 device=aspi2dos.sys device=aspi8dos.sys device=aspi4dos.sys device=aspi8u2.sys device =aspicd.sys /D:MSCD001 install=mscdex.exe /D:MSCD001 /L:R

@echo off set temp=c:\ set tmp=c:\ mode.com con cp prepare=((866) ega3.cpi) mode.com con cp select=866 keyb.com ru,keybrd3.sys path=a: \;r:\

Despite its simplicity, even this option has pitfalls: it is designed for the PC to have only one CD-ROM device (from which it boots). Otherwise, it is possible that after booting from the floppy disk you will not be able to access the rest of the contents of the CD due to a driver conflict.

To check all the subtleties, be sure to check before recording that the PC can boot from the prepared floppy disk and that the CD-ROM driver is connected correctly. In general, it is better to leave a single driver with CONFIG.SYS (which of course reduces versatility) or make a menu to select it at boot. As a last resort, you can press F8 and enable step-by-step boot mode, then select only the necessary driver.

So, if after this the PC was able to boot from the disk made, the first stage has been completed. Next, we will look at the essence of the boot process from a CD-ROM and describe a way to solve the problem of accessing the entire volume of the disk without drivers.

How it really works

Thanks to the efforts of Phoenix and IBM, the “El Torito” Bootable CD-ROM Format Specification was born, version 1.0 of which is dated January 25, 1995. Although the specification allows for multiple boot images (and selecting them from the boot menu) on a single disk, we will consider the single image option for simplicity.

This standard defines whether a CD-ROM can emulate drive A: or C: when the PC boots. The following options are possible:

  • The CD-ROM emulates drive A:. Drive A: installed on the PC becomes B:, the other drives do not change their names. Access to the entire (up to 640MB) contents of the CD-ROM is possible through booting from an emulated A: CD-ROM driver (which may differ on different PCs!) and MSCDEX.EXE.
  • The CD-ROM emulates the C: drive. In this case, the numbering of disks installed on the PC is shifted. This option allows you to access 640MB of information regardless of the CD-ROM device, because loading its (possibly specific) driver is optional.
  • No emulation. This means that when loading, the program is simply read at the specified address of the specified length and control is transferred to it. What happens next with the PC is her own business. For example, a Microsoft Windows NT installation disk looks like this.

A CD-ROM is a sequentially addressable device with sectors 0 to (usually) 335249, which are 2048 bytes in size (in Mode 1). The part of the logical structure that is interesting to us includes:

Sector
0-15
16 Primary Volume Descriptor
17 Boot Record Volume
...
B.C. Booting Catalog
...
BI_1-BI_m Bootable Disk Image
...

In this case, the emulation also includes the translation of 4 512 byte sectors into 2048 byte sectors on the CD.

The loading technology uses the ability to have multiple volume descriptions on one disk. For example, when recording in the Joilet format, simply two descriptors are used - for ISO9660 and for Joilet, which increases disc compatibility at a very small cost in volume. Compare with long names in Windows 95 - there are two entries in each directory entry - the standard MS-DOS 8.3 and the long name Windows 95. On the CD it is a little different, there are two different directories, one ISO9660 with short names, and the second Joilet - with long ones in unicode. And the files themselves take up the same space. They just have links from both directories. And if the system (its cdfs driver) can read Joilet, then it does this, and if not, then it reads the standard ISO9660.

To study the structure of a CD-ROM, we use its ISO image - a sector-by-sector copy of the disk (for the programs used to obtain it, see the end of the article).

Sector 16 is PVD, we don’t need to change it. Its beginning looks like this (look at the disk image with diskedit):

Note that offset 0x8000 corresponds to 16*2048.

Sector 17 - Boot Volume Descriptor should look like this:

Its structure in detail:

The next sector contains an indicator for the end of the descriptor table. I don’t know for sure whether it is needed or not, but everything definitely works with it and the disks that write ECDC have it.

The next interesting sector is the Booting Catalog itself. In my example, it is located in sector 0x1D (0x1D * 2048 = 0xE800):

It consists of two records of 32 bytes each. The first is Validation Entry:

In principle, you can use the one shown in the picture in any case (for 80x86). But if you want to change the ID string, then do not forget to correct the checksum so that the sum of all words in this 32-byte record is equal to 0.

The next entry is called Initial/Default Entry:

In the case of several boot images, this entry may be followed by others, but we will not consider this option.

Boot Media Type

This byte determines which media will be emulated. For this, bits 0-3 are used (the rest must be 0): 0 - no emulation, 1 - 1.2MB floppy disk, 2 - 1.44MB floppy disk, 3 - 2.88MB floppy disk, 4 - hard disk.

Load Segment

This word contains the address of the segment into which the MBR/Boot Sector of the image will be loaded. For IBM PC this is 0x7C0. (If this field is 0, then the traditional 0x7C0 is also used).

System Type

This byte must match the system type byte in the boot image's partition table. For example, DOS-12 - 0x01, DOS-16 - 0x04, BIGDOS - 0x06 (>32MB). For a floppy disk, ECDC sets it to 0, most likely he is right.

Sector Count

This field specifies the number of sectors (emulated - based on 512 bytes per sector) that are counted into the above segment when loading. In our case, one sector is enough.

Load RBA

Address of the first sector of the disk image on the CD.

Floppy disk image

Well, there is nothing complicated with this. Any program (the same diskedit for example) reads all sectors of the floppy disk into a file. It sequentially contains Boot Record, FAT1, FAT2, the root directory, and the actual files. The floppy disk format (1.2, 1.44...) is mentioned both in the Booting Catalog and in the image itself in the Boot Record.

Hard disk image

But I had to tinker a lot with this. I was very confused by the mentions of ISO, ghost, diskedit when preparing this image. Of course, most likely, if you take a disk no more than 640MB, create one partition on it, install the system, etc., then you could probably use diskedit to prepare an image of such a disk, but where can you get such a small disk today and where to connect it ?

The structure of such a simple hard drive looks like this:

  • First sector - MBR = boot code + partition table
  • First sector of the second side - BootRecord of the first partition
  • Then, as in a floppy disk, there are two copies of FAT, the root directory, and data.

Thus, it can be seen that the only difference from a floppy disk is the use of a partition table. However, it hides a much deeper problem - how to determine the geometry of the disk from the data on it? After all, without this, any work with the disk becomes problematic. Moreover, the CD-ROM itself uses conventional linear addressing and there is no place for such information anywhere in the considered structures of the boot CD-ROM.

In fact, you can tell this by looking at the partition table. If we assume that the end of the section necessarily falls on the last sector of the last side of some cylinder, then the data from the MBR will help us find out the number of sectors in the track and sides in the cylinder! For example (using diskedit again):

From this table it can be seen that the last sector of each section is sector number 63, which, taking into account the sector numbering from 1, gives us 63 sectors per track. Similarly, for the number of sides, the figure is 255 (numbering from 0!).

By the way, you can immediately see how the problem of the 8GB limit is solved - instead of the beginning/end of the section, the fields of the relative number of sectors and the number of sectors in the section, which have the size of a double word, are used.

Let me remind you that in LBA mode addressing via CHS occurs like this:
LBA 0 = Cylinder 0, Head 0, Sector 1
LBA X = ((Cylinder * Maximum Heads + Head) * Sector per Track) + Sector -1

As you know, SCSI always operates in LBA mode - with direct addressing of sectors. It just has to emulate CHS for standard MBR appearance and compatibility. Often, in SCSI BIOS you can select the translation mode from CHS for disks up to 1GB and larger than 1GB. (By the way, the non-function of a SCSI disk formatted on one controller when installed on another may be associated with different translations for different controllers).

So, several experiments were carried out (the number of cylinders in our case is not important; a 270 disk really works in LBA):

IDE (Award 4.51)

MB capacity Heads Sectors Cylinders
270 32 63 262
540 32 63 524
1200 64 63 847
3500 128 63 621
13400 255 63 1650

SCSI (Tekram DC-390)

Volume Heads Sectors
<1G 64 32
>1G 255 63

As you can see, all these tricks are aimed at not reaching the number of cylinders of 1024. This is due to the fact that MBR, BIOS and many others are designed to store the cylinder number in 10 bits. And the 8GB limit just comes from 1024*255*63 sectors. Or you can calculate this limit differently - only 3 bytes per sector number in LBA mode.

Formally, the BIOS should figure everything out for itself to boot, but it seems that this does not always happen. Many testers noted that there is some pattern in which disk - IDE or SCSI to create an image from, and on which CD-ROM it can boot.

However, the only requirement mentioned in the standard is to use only one and only the first entry in the Partition Table. Luckily this is easy to achieve.

Based on all this, the following method of obtaining a hard disk image was invented and tested:

  1. Create a partition of the required size on your hard drive.
  2. We format it (FAT12/16), make it system (you can immediately format /s, or you can do sys later).
  3. We use a specially written program (getimg.zip), which, based on the information in the BootRecord of the specified disk, recreates the MBR and reads all the information into one file.

Just remember to prepare the necessary space on another disk or partition.

Of course, this method has a drawback - to further create a CD-ROM, you will need the same amount of space for the ISO CD image, but let's hope that today it is quite easy to find 3 * 640 MB on a disk, especially if you have a CDR in your PC :).

As for the geometry of the hard drive, here are the results of experiments carried out on booting a PC from various images:

test SCSI ATAPI
H 32 S 63, DOS-16 Yes (1) Yes (2)
H 255 S 63, Windows 98 Yes (1) Yes
H 64 S 32, Windows 98 (Zip drive) Yes (1) Yes

(1) in this test, after booting, only the D: partition of the hard drive is correctly visible (it was C:). Most likely this is due to the implementation of the SCSI BIOS, because it hooks Int 13 and uses it in a less than transparent manner.

(2) naturally, the partition of the PC hard drive with FAT32 is not visible, because DOS 6.22 system

Thus, no problems with incompatibility of the emulated disk geometry were noted and we can say that AWARD 4.51 BIOS and slightly worse Adaptec 7880 SCSI BIOS 1.32 cope with disk image identification.

Booting with hard drive emulation

Now we will describe how all this can be done for the hard drive option.

The general principle is this: we use the ECDC program to prepare an ISO disk image. Then we edit it a little with diskedit and burn it to CD.

The only thing is that I haven’t quite decided how to add the necessary Boot Volume Descriptor to the structure of volume descriptions. The problem is that it should be located in sector 17. And in the prepared image there may be something else there. I did this (at the cost of Joilet, although it doesn’t work without a GUI): for the image I specified the Joilet file system type, this led to the Joilet volume descriptor being in sector 17, then I simply replaced it with Boot Volume Descriptor. And in the 18th sector - as it should be, the final Volume Descriptor.

The Booting Catalog and the boot disk image can be located anywhere, so we simply add them as files (preferably first, so as not to search for a long time later). For the first, we simply take a file of length 2048 with memorable content (for example, filled with the line “BC**”). The second one is the disk image. Let's call it image.bin.

After creating the image (File -> Create CD image, write it as .ISO), we determine in which sectors ECDC wrote our bootcat.bin and image.bin. To do this, open the file in diskedit and search for “BC**”. This will be bootcat.bin. Most likely it is located in sector 0x1D, file offset 0xE800, next to it (0xF000) we see the MBR of our hard disk image. Another option for finding the location of these files, based on the ISO directory, is to look up their names in the ISO image and take the double word 31 bytes before the name:

In sector 17 (offset 0x8800) we write the Boot Volume Descriptor, as indicated above, and check that the correct link to the Booting Catalog is in bytes 0x47-0x4A (we have 0x0000001D):

0008800: 00 43 44 30 30 31 01 45 - 4C 20 54 4F 52 49 54 4F 0008810: 20 53 50 45 43 49 46 49 - 43 41 54 49 4F 4E 00 00 0008820 : 00 00 00 00 00 00 00 00 - 00 00 00 00 00 00 00 00 0008830: 00 00 00 00 00 00 00 00 - 00 00 00 00 00 00 00 00 0008840: 00 00 00 00 00 00 00 1D - 00 00 00 0 0 00 00 00 00

The rest are zeros. This file can be downloaded here - bootvd.bin. Addresses 47-4A are written as 0x12345678 for clarity.

Now we create the Booting Catalog (sector 0x1D):

000E800: 01 00 00 00 00 00 00 00 - 00 00 00 00 00 00 00 00 000E810: 00 00 00 00 00 00 00 00 - 00 00 00 00 AA 55 55 AA 000E820: 88 04 C0 07 04 00 01 00 - 1E 00 00 00 00 00 00 00 000E830: 00 00 00 00 00 00 00 00 - 00 00 00 00 00 00 00 00

The following parameters are indicated here: boot image (88), hard disk emulation (04), address 0x7C0, DOS-16 partition, load one sector, start of the disk image - sector 0x0000001E. This file is bootcat.bin.

Having checked everything again, we burn the corrected image to CD: open ECDC, File -> Create CD from Disk image.

That's actually all that we managed to find and check on this issue.

Used:

Programs:

  1. Adaptec Easy CD Creator
  2. Symantec DISKEDIT
  3. Golden Hawk CDRWIN
  4. Gilles Vollant WinImage

Equipment:

  1. MB Chaintech 6BTS (with AHA7880), AWARD BIOS 4.51
  2. ASUS SD-S400 (ATAPI CD-ROM)
  3. Yamaha CRW6416S (SCSI CD-ROM/CD-RW)
  1. Phoenix PC Industry Specifications http://www.ptltd.com/products/specs.html
  2. Andy McFadden CDR FAQ www.fadden.com
  3. Creating a boot CD with Aurora
mob_info