0% found this document useful (0 votes)
253 views

Masm Help File

To execute an assembly language program using MASM, you must: 1) Open the MASM editor to create an assembly file with a .asm extension and write the code. 2) Compile the assembly code using MASM to check for errors. 3) Link the compiled code using LINK to generate an executable file. 4) Run the executable file in the AFDEBUG debugger to step through or fully execute the program.
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
253 views

Masm Help File

To execute an assembly language program using MASM, you must: 1) Open the MASM editor to create an assembly file with a .asm extension and write the code. 2) Compile the assembly code using MASM to check for errors. 3) Link the compiled code using LINK to generate an executable file. 4) Run the executable file in the AFDEBUG debugger to step through or fully execute the program.
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
You are on page 1/ 2

MICRO PROCESSOR LAB

SEQUENCE TO EXECUTE AN ASSEMBLY LANGUAGE PROGRAM USING MASM :->

Start --> Run --> command -->

C:\documents and settings\VITS> cd\ -->

C :\> cd masm -->

C :\> MASM\> edit <filename.asm> -->

Edit screen will be opened:


CODE SEGMENT

ASSUME CS: CODE

START:

} PROGRAM

CODE ENDS

END START

ALT + FILE + SAVE

ALT + FILE + EXIT

Edit screen will be closed.


TO COMPILE :--->

C:\MASM\> masm < filename.asm>;

If errors are encountered open the same program and correct it using

C:\MASM\>edit <filenaem.asm> -->

if there are no errors:

C:\MASM\> link <filename>;

C:\MASM\> afdebug <filename.exe> -->

AFDEBUG screen will be displayed in which general purpose registers,

Current program, memory, flags etc.., can be seen.

If the current program is not visible type:

CMD> L <filename.exe> --> (to load the program)

Give the inputs according to the program.

To execute the program press 'F1' for step by step procedure

Or

Press 'G' --> for complete execution at a time

For cursor movement use the key 'F8'.

To exit from AFDEBUG window

Type:

CMD> quit -->

You might also like