『第 62 楼』:
下面新增的功能已经实现了!
使用 LLM 解释/回答一下
下面的功能已经实现了!
1
支持古董级硬盘(不支持扩展INT13)的压缩分卷
尽管不支持扩展INT13,把硬盘的扇区压缩成文件,还不成问题..
但是,把在某个硬盘的某个位置压缩成的镜象文件再恢复到另一个硬盘的不同位置,结果就不对。
要解决这个问题,就要费一翻脑筋啦!
因为之前的压缩了的文件中结构是不得不根据硬盘扇区的几何结构而来,
但是,以后,要把这个文件再解压到不同硬盘的不同位置时,就会不一致.解压后不能直接写到硬盘..
所以,要重新分析硬盘物理结构,然后,要先设几个缓冲,对解压出的数据进行调整到被允许的数据大小,还有剩余数据的处理等等,处理起来还是挺复杂的...
但是,被我拿下啦! 而且,只用了很少的代码!
测试的结果正确!
2
无论支持不支持扩展INT13,都能进行硬盘,分区(仅限于主分区)和任意扇区之间的复制.
这也涉及到对硬盘物理结构的解读,以及和支持扩展INT13的硬盘的协同工作..
***********************
************************
(小补充: 原先支持扩展INT13硬盘的读写,缓冲设为100扇区, 现发现可能能增大为125扇区(64000字节)!)
到此,想要加入的功能,都已完成了,很满足..而且,尽量力求代码的精简高效,和考虑使用者的常见习惯.
现在,正在归整代码,很快就全线完工啦!
(明天,再去买几块硬盘,以便全面,大规模的测试啦! 也看看 有没有不支持扩展INT13的古董硬盘?
前段时间买的老硬盘2GB左右,居然还是支持扩展INT13! 晕死!! 极度失望!
注:由于现在没有不支持扩展INT13的硬盘,之前对基本INT13(CHS模式)的读写的测试,是通过有意改反代码(即把支持扩展和不支持扩展有意弄反,这样,支持就是不支持,才能测试CHS模式代码的结果。。。还有就是拿软盘做测试)
)
Last edited by GOTOmsdos on 2006-8-11 at 18:50 ]
The following functions have been implemented!
1
Support for compressed multi-volume disks for antique hard drives (does not support extended INT13)
Although extended INT13 is not supported, it is not a problem to compress the sectors of the hard drive into files..
But when restoring the image file compressed at a certain position on a hard drive to a different position on another hard drive, the result is incorrect.
To solve this problem, one has to rack one's brains!
Because the structure in the previously compressed file has to be based on the geometric structure of the hard drive sectors,
However, when this file is to be decompressed to a different position on a different hard drive in the future, there will be inconsistencies. The decompressed data cannot be directly written to the hard drive..
So, we need to re-analyze the physical structure of the hard drive, and then set up several buffers, adjust the decompressed data to the allowable data size, and handle the remaining data, etc. It is quite complicated to handle...
But I've cracked it! And it only took very little code!
The test results are correct!
2
Regardless of whether extended INT13 is supported or not, copying between hard drives, partitions (limited to primary partitions) and any sectors can be carried out.
This also involves interpreting the physical structure of the hard drive and working in coordination with hard drives that support extended INT13..
***********************
************************
(Small supplement: Originally, the buffer for reading and writing hard drives that support extended INT13 was set to 100 sectors, and now it is found that it may be increased to 125 sectors (64,000 bytes)!)
So far, all the functions that I wanted to add have been completed, and I am very satisfied.. And I have tried my best to make the code concise and efficient, and consider the common habits of users.
Now, I am organizing the code, and it will be fully completed soon!
(Tomorrow, I will go buy a few more hard drives to carry out comprehensive and large-scale testing! Also, see if there are antique hard drives that do not support extended INT13!
The old hard drive of about 2GB that I bought some time ago actually still supports extended INT13! Oh my god!! Extremely disappointed!
Note: Since there are no hard drives that do not support extended INT13 now, the previous tests on the reading and writing of basic INT13 (CHS mode) were carried out by intentionally reversing the code (that is, intentionally reversing the support for extended and non-support, so that support becomes non-support, so as to test the results of the CHS mode code... Also, using floppy disks for testing)
)
Last edited by GOTOmsdos on 2006-8-11 at 18:50 ]
|