مواضيع المحاضرة: debug commands
background image

Microprocessor Lab 

Experiment No. (1) 

DEBUG Commands 

 

Objective:- 

  To learn how to use MS-DOS prompt  and DEBUG commands. 

Equipments:- 

  PC

 

Theoretical Background:- 
List of Debug Commands:- 

 

Function

 

Syntax

 

Example

 

Assemble 

 A [address] 

A 100 

Compare 

 C range address 

C 140 148 340 

Dump  

 D [range] 

D       D  [address] [L length] 

 

D 100 130 
D 200 L 5 
D 138d:10 

Enter  

 E address [list] 

E 100 d2 
E 100 ‘hello’ 

 Fill 

 F range list 

F 100 110 ff 
F 100 110 ‘X’ 

Go  

 G [=address] [addresses] 

G = 104 114 11f 

Hex  

 H value1 value2 

H 333 111 results 
444,222 

Input 

 I port 

I 378 

Load  

 L [address] [drive] [first sector]  
[number] 

L 100 2 0 1 

Move  

 M range address 

M 100 11f 200 
 

Name  

 N [pathname] [arg list] 

N c:\temp\doswinok.com 

Output  

 O port byte 

O 378 ff 

Proceed  

 P [=address] [number] 

P = 205 7 

Quit  

 Q . . . . . . . . . (Learn this 
first!) 

Register    R [register] 

R BX 

Search  

 S range list 

S 200 210 ff 

Trace 

 T [=address] [number] 

T = 205 7  
 

Unassemble   U [range] 

U 100 108  

Write  

 W [address] [drive] [first sector] 
[number] 

W 5 

 
 


background image

Procedure:- 
 

1. 

Open a DOS window by double clicking the DOSBOX icon.

 

 

2. 

Enter the following Command: 

                   Z:\ > MOUNT C C:\8086  <ENTER> 
                   Z:\ > C:  <ENTER> 
 

3. 

Load DEBUG as follows: 
     C:\ > DEBUG <ENTER> 
     - 
     - 

4. 

Run the following commands at the DEBUG  and  write the results

   

-R <ENTER>           

 
 

 

-R ax<ENTER>         
-Type
 1234<ENTER>    
-R ax<ENTER>         
-RF<ENTER>           
-Type ov dn<ENTER>        
-RF<ENTER>           
-D 0200 L 1<ENTER>                
-E 0200 ff <ENTER>         
-D 0200 L 1<ENTER>              
-E 0100 'test'<ENTER> 
-D 0100 <ENTER>                
-F

 

0100 010f

 

ff<ENTER>  

-D

 

0100 010f<ENTER>         

-F 0100 010f ‘microprocessor<ENTER>    
-D 0100 010f<ENTER>      
-C 0200 0210 0400<ENTER>     
-F 0400 0410 D0<ENTER>    
-S 0400 0410 D0<ENTER>    
-S 0400 0410 DF<ENTER>   
-Q <ENTER>  
 
 

5. 

C:\ > Exit <ENTER> 

 
 
 
 
 


background image

Lab work: 

Apply each of the following command, using the suitable Debug command 

then write your answer on a paper. 
1. Display the contents of  SPBP,SI , DI registers. 
2. Change the value of  DS to FFFFCS to AAAA.

 

 

3. Change the value of the Flags to the opposite values. 

4. 

Fill the contents of  the memory A3F0:0000 0010 with  BB

5. Search for the value BB in the memory A3F0:0000 0010 
6. Add and Subtract 222 ,888  

7. Fill the contents of the memory B800:0000 0020 with ‘X’ now look at your 

DOS screen. 




رفعت المحاضرة من قبل: صالح محمود
المشاهدات: لقد قام 11 عضواً و 252 زائراً بقراءة هذه المحاضرة








تسجيل دخول

أو
عبر الحساب الاعتيادي
الرجاء كتابة البريد الالكتروني بشكل صحيح
الرجاء كتابة كلمة المرور
لست عضواً في موقع محاضراتي؟
اضغط هنا للتسجيل