Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

What are the practical Mini Program for DOS DEBUG?

2025-02-24 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >

Share

Shulou(Shulou.com)06/03 Report--

This article will explain in detail about the practical Mini Program of DOS DEBUG, which the editor thinks is quite practical, so I share it with you as a reference. I hope you can get something after reading this article.

1. Repair of non-physical 0 track bad floppy disk

From the surface of the floppy disk, there is no obvious scratch or mildew. It is generally possible to recover its data, but floppy disks are being reused.

The method of treatment is as follows:

Ⅰ. Enter debug

Ⅱ. Take a good disk that is not damaged in the boot area and insert the floppy drive

-L 100 00 1

Ⅲ. Insert a damaged disk into the floppy drive

-W 100 00 1

-Q

Note: the capacity of good disk and bad disk must be the same.

two。 Data reading in physical 0 track bad floppy disk

Generally speaking, disks with track 0 damage should be discarded, and you might as well try the following methods:

Magnetization treatment: use a strong magnet to move repeatedly near the surface of the bad disk, do not touch the disk media, so as not to scratch the surface, and then try formatting.

Floppy disk replacement: carefully open the disk, separate the hard disk from the metal chip, and then stick it together in the original way, reformatting.

Diskfix: everyone must have used diskfix a lot, and the disk repair function in it is very easy to use. Can fix most disk surface errors.

3. Handling of hard disk boot failure

Format a floppy disk on a normal computer with no other data

Enter debug

-L 0 2 0 1

-W 0 0 0 1

-Q

After starting the fault machine with the system disk

Entering debug

-L 0 0 0 1

-w 0 2 0 1

-Q

4. The solution is that the floppy disk cannot be read correctly.

If the following prompt appears when using a floppy disk

General failure error reading drive A

It can be solved in the following ways:

Insert a good disk into the floppy drive

Enter debug

-A 100

*: * 100 MOV AL,0

* *: * MOV CX,1

* *: * MOV DX,0

* *: * MOV BX,1000

* INT 25

* INT 20

Enter

-Gambi0100

Insert bad disk and enter Debug

-A 200

*: * 100 MOV AL,1

* *: * MOV CX,1

* *: * MOV DX,0

* *: * MOV BX,1000

* INT 26

* INT 20

Enter

-Gambi200

Save and restore 5.CMOS data

The address of CMOSRAM 'address port' is 70H 'data port'. When reading, you only need to send the address of the read CMOSRAM to 70H, and then you can get the required data from 71H.

(1) read CMOS data and enter Debug

-A 100

*: * 100 MOV BX,1000

* *: * MOV CX,0040

* *: * MOV AX,0000

* *: 0109 MOV DX,CX

* *: * MOV CX,0005

* *: 010E LOOP 010E

* OUT 70 *

* *: * MOV CX,0005

*: 0115 LOOP 0115

* *: * IN AL,71

*: * MOV [BX], AL

* *: * CMP AH,0E

* *: * JB 0123

* *: * ADD AH,80

* *: 0123 INC AH

* *: * INC BX

* *: * MOV CX,DX

* *: * MOV AL,AH

* *: * LOOP 0109

* *: * MOV AH,3C

* *: * MOV DX,0150

* *: * MOV CX,0020

* INT 21

* *: * MOV BX,AX

* *: * MOV DX,1000

* *: * MOV CX,0040

* *: * MOV AH,40

* INT 21

* *: * MOV AH,4C

* INT 21

-A 150

* *: 0150 DB "CMOS.DAT", 0

* *: 0159

-R CX

CX 0000

: 60

-N SAVE CMOS.COM

-W

-Q

-W 100 2 0 1

-Q

(2) restore CMOS data into Debug

-A 100

*: * 100 MOV CX,0150

* *: * MOV AH,3D

* *: * MOV AL,00

* INT 21

* *: * MOV DX,1000

* *: * MOV BX,AX

* *: * MOV CX,0040

* *: * MOV AH,3F

* INT 21

* *: * MOV AX,0000

* *: * MOV BX,DX

* *: * MOV DX,CX

* *: * MOV CX,0005

* LOOP 011F

* *: * MOV AL,AH

* OUT 70 *

* *: * MOV CX,0005

* *: * LOOP 0128

*: * MOV AL, [BX]

* OUT 71JAL

* *: * JB 0136

* *: * ADD AH,80

* *: * INC AH

* *: * INC BX

* *: * MOV CX,DX

* LOOP 011A

* *: * MOV AX,0040

* *: * MOV DS,AX

* *: * MOV AX,1234

*: * MOV [0072], AX

* *: * JMP FFFF:0000

-A 150

* *: 0150 DB "CMOS.DAT", 0

* *: 0159

-R CX

CX 0000

: 60

-N WRITE CMOS.COM

-W

-Q

Saving and recovery of 6.DOS Boot sector data

The DOS bootstrapper is read into memory and executed at the beginning of 0000:7C00.

Get a normal bootstrap

Enter Debug

-L 100 2 0 1

-N A:DOSBOOT.COM

-R CX

: 200

-W

-Q

Load bootstrapper

Enter Debug

-N A:DOSBOOT.COM

-L

-R CX

: 200

-W 100 2 0 1

-Q

7. Storage and recovery of data from main boot sector of hard disk

Read the main boot sector information when the hard disk is working properly

Note: this data cannot be recovered when the partition is changed.

Save the main boot sector data into Debug

-A 100

MOV AX,0201

MOV BX,0110

MOV CX,0001

MOV DX,0080

INT 13

INT 3

-Gram 100

-E 102 3

-E 10E C3

-R BX

BX 0110

: 0

-R CX

CX 0001

: 210

-N A:RBOOT.COM

-W

-Q

Restore the master boot sector data: just run the RBOOT.COM of disk A

8. Backup and recovery of hard disk non-allocation table

Allocation table backup when the computer is running normally

Enter Debug

-L 100 2 0 1

-N A:DBRUP.DAT

-R CX

: 200

-W

Restore

Enter Debug

-N A:DBRUP.DAT

-L

-W 100 2 0 1

-Q

9. Inside story of hard disk protection card

For people who often get on the computer outside, once the computer maintenance personnel set up the hard disk protection card, they will do something especially troublesome by themselves. whether they want to shield the hard disk protection card or not, you may be able to learn from it in the following ways:

Enter Debug

-A 100

MOV AH,0

MOV DL,0

INT 13

-T

Always press T until you find CS=F000. Write down the value of DS at this time, such as: 1234.

-E E0VR 4C

34 12 00 F0

-Q

10. Using Debuf for low-level formatting of hard disk

Hard disk low-level formatting usually uses DM, but Debug can also low-level format hard disk

Enter Debug

-A 100

MOV AX,500

MOV BX,180

MOV CX,0

MOV DX,80

INT 13

INT 3

-E 180000 0 2

-Q

11. Cold start and hot start

Using Debug to realize system Cold start and Hot start Program

Cold start:

-A 100

JMP FFFF:0

INT 20

-N A:RESET.COM

-R CX

: 0007

-w

-Q

Hot start:

-A 100

MOV AX,0040

MOV DS,AX

MOV AX,1234

MOV SI,0072

MOV (SI), AX

JMP FFFF:0

-N A:RSET.COM

-R CX

: 0014

-W

-Q

12.DOS internal command encryption

Such as encrypting dir

Use pctools or diskedit to find the COMMAND.COM file under C:

Edit the file

PCTOOLS: F-F1 then find all 03 44 49 52 and press F5 to change it to the value you want, such as: foo can only be listed by entering foo.

Diskfix has a good interface and is similar to pctools in operation.

Note: if you cannot modify it, unlock the locked luck of the file.

Other command codes

Type 04 54 59 50 45

Cd 02 43 44

Del 03 44 45 44

Copy 04 43 49 50 59

This is the end of this article on "what DOS DEBUG practical Mini Program has". I hope the above content can be of some help to you, so that you can learn more knowledge. if you think the article is good, please share it out for more people to see.

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Development

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report