Free Essay

Masm

In:

Submitted By lundlesh
Words 496
Pages 2
CMLab

Graphics

A Tutorial of Writing MASM with VC++ 2005 Express
Presented by Ken-Yi Lee Assembly Language 2007

CMLab

Graphics

Assembly Language 2007

MASM
Microsoft Macro Assembler

- MASM 8.0 included with Visual C++ 2005 - You can download MASM 8.0 and install it with Visual C++ 2005 Express by yourself

2

CMLab

Graphics

Assembly Language 2007

What do you need ? helloworld.asm helloworld.obj Editor Assembler (ml.exe) Linker (link.exe) helloworld.exe Debugger
3

Include Files
Where Which

Object File Libraries
Where Which

CMLab

Graphics

Assembly Language 2007

Visual C++ 2005 Express with MASM 8.0
Visual C++ 2005 Express

- Editor, Linker, and Debugger

• Custom build rules needed] • Set library paths and library dependencies [if • Select “console” as your subsystem
MASM 8.0

- Assembler

• Set include paths [if needed]
4

CMLab

Graphics

Assembly Language 2007

Visual C++ 2005 Express with MASM 8.0 (contd.)
Download and Install Visual C++ 2005 Express

- http://0rz.tw/253mH
Download and Install MASM 8.0

- http://0rz.tw/8d1Xn

• You should install VC 2005 Express first
5

CMLab

Graphics

Hello MASM !
A simple example to set up the environment

CMLab

Graphics

Assembly Language 2007

HelloMASM
- My Settings:

• Project Name: HelloMASM • Solution Name: HelloMASM • Source code filename: hellomasm.asm • Additional library dependencies: Irvine32.lib user32.lib • Used headers: Irvine32.inc • Additional library Paths: C:\irvine\ • Additional Include Paths: C:\irvine\

7

CMLab

Graphics

Assembly Language 2007

Create a new project
[ File > New > Project ], [ Visual C++ > emptyproj ]

- Enter a name for your project

8

CMLab

Graphics

Assembly Language 2007

9

CMLab

Graphics

Assembly Language 2007

Custom Build Rules
Right click on the project name in the solution explorer window and select “Custom Build Rules”

- Turn on “Microsoft Macro Assembler”

10

CMLab

Graphics

Assembly Language 2007

11

CMLab

Graphics

Assembly Language 2007

Select “Console” as subsystem
Right click on the project name in the solution explorer window and select “Properties”

- [ Configuration Properties > Linker >
System > Subsystem ]

•Select “Console”
12

CMLab

Graphics

Assembly Language 2007

13

CMLab

Graphics

Assembly Language 2007

To work with other libraries
In the same window,

- [ Configuration Properties > Linker >

General > Additional Library Directories ]

• Enter the paths to library files
- [ Configuration Properties > Linker > Input
> Additional Dependency ]

• Enter library filenames
14

CMLab

Graphics

Assembly Language 2007

15

CMLab

Graphics

Assembly Language 2007

To work with other libraries (contd.)
- [ Configuration Properties > Microsoft
Macro Assembler > General > Include Paths ]

• Enter the paths to your header files

16

CMLab

Graphics

Assembly Language 2007

17

CMLab

Graphics

Assembly Language 2007

Add a new file
Right click on “Source file” in the solution explorer window and select “Add > New Item” [ Visual C++ > Code > C++ File (.cpp) ]

- Enter a filename with “asm” extension
Write your codes in the editor window

18

CMLab

Graphics

Assembly Language 2007

19

CMLab

Graphics

Assembly Language 2007

Build and Run
[ Build > Build solution ] or [ Build > Compile ] [ Start Debugging ] or [ Start without Debugging ] Build, Run ... and Debug

20

CMLab

Graphics

Assembly Language 2007

21

CMLab

Graphics

Assembly Language 2007

The End

22

Similar Documents

Free Essay

Spm - Software Project Managment

...Microsoft Support Services ========================== If you have a question about Microsoft Macro Assembler (MASM), first look in the printed documentation, the online text files, or consult Help. If you cannot find the answer, contact the Microsoft Support Network. Outside the United States, contact Microsoft Product Support Services at the Microsoft subsidiary office that serves your area. For information about Microsoft subsidiary offices, see "Product Support Worldwide" later in this section. The Microsoft Support Network ============================= The Microsoft Support Network offers you a wide range of choices and access to high-quality, responsive technical support. Microsoft recognizes that support needs vary from user to user; the Microsoft Support Network allows you to choose the type of support that best meets your needs, with options ranging from electronic bulletin boards to annual support programs. If you have a question about MASM, first look in the product documentation or consult online Help. You can also find late-breaking updates and technical information in the README.TXT file and other text files that came with your MASM disks. Services vary outside the United States and Canada. In other locations, contact a local Microsoft subsidiary for information. The Microsoft ...

Words: 836 - Pages: 4

Free Essay

Information on 8086

...INFORMATION OF 8086 WORKING WITH MS-DOS AND BIOS.... The Processing Environment The processing environment for MASM includes the processor on which your programs run, the operating system your programs use, and the aspects of the segmented architecture that influence the choice of programming models. 8086-Based Processors The 8086 “family” of processors uses segments to control data and code. The later 8086-based processors have larger instruction sets and more memory capacity, but they still support the same segmented architecture. Knowing the differences between the various 8086-based processors can help you select the appropriate target processor for your programs. The instruction set of the 8086 processor is upwardly compatible with its successors. To write code that runs on the widest number of machines, select the 8086 instruction set. By using the instruction set of a more advanced processor, you increase the capabilities and efficiency of your program, but you also reduce the number of systems on which the program can run. Processor Modes Real mode allows only one process to run at a time. The mode gets its name from the fact that addresses in real mode always correspond to real locations in memory. The MS-DOS operating system runs in real mode. Windows 3.1 operates only in protected mode, but runs MS-DOS programs in real mode or in a simulation of real mode called virtual-86 mode. In protected mode, more than one process can be active at any one time...

Words: 6814 - Pages: 28

Free Essay

Student

...Adusumilli Maneesha Plot158/A, flat-103, Surya Enclave, Addagutta Society, Opp. JNTU, kukatpally, Hyderabad-500072 Tel no: +91-8801398773 Email id: maneesha.gorantla@gmail.com ACADEMIC QUALIFICATION: * Bachelor of Technology in Electronics and Communications Engineering, TRR Engineering College, Jawaharlal Nehru Technological University (JNTU), Hyderabad, India; May 2013, Final Grade: 76%. PROFESSIONAL EXPERIENCE: Software Engineer, AVL IT Services Pvt Ltd, Hyderabad September 2013-December 2014 * Wrote Java code for the software maintenance project. * Conducted Unit Testing of the code. * Wrote code to create applets. * Worked on Object Oriented Design ACADEMIC PROJECTS Title: Improvement of Wallace multipliers using parallel prefix adders Period: November 2012-March 2013 Team Size: 3 Arithmetic and logic unit (ALU) of a processor, when used for scientific computations, will spend more time in multiplications. Wallace multipliers perform in parallel, resulting in high speed. It uses full adders and half adders in their reduction phase. Reduced complexities Wallace multiplier will have fewer adders than normal Wallace multipliers. In both multipliers, at the final stage, carry propagating adder in used, which contributes to delay. This thesis proposes, employing parallel prefix adders (fast adders) at the final stage of Wallace multipliers to reduce the delay. Title: Passive Infra-Red Based Theft Alert System...

Words: 578 - Pages: 3

Premium Essay

Computer Science

...A REPORT ON INTELLIGENT HUMIDISTAT BY Rohan Mehta 2011B5A3376P Aditya Pillai 2011B3A3530P Shantanu Maharwal 2011B2A3700P Gaurav Dadhich 2011B3A8513P AT BIRLA INSTITUTE OF TECHNOLOGY & SCIENCE, PILANI A REPORT ON INTELLIGENT HUMIDISTAT BY Rohan Mehta 2011B5A3376P Aditya Pillai 2011B3A3530P Shantanu Maharwal 2011B2A3700P Gaurav Dadhich 2011B3A8513P Prepared in Partial fulfilment of the requirements of the course “Microprocessors and Interfacing” Course Number: EEE F241 AT BIRLA INSTITUTE OF TECHNOLOGY & SCIENCE, PILANI (April 2014) ACKNOWLEDGEMENT We would like to express our gratitude to all those who have helped us directly or indirectly to complete this report. Firstly, we would like to express our gratitude towards the Instructor-in-Charge (IC) of this course, Dr. K. R. Anupama (from Goa Campus) and Dr. Pawan Sharma (from Pilani Campus) for giving us this opportunity to work on such an interesting assignment. Their teachings and support during the program were greatly valuable to all of us. We would also like to thank our tutorial professors, viz., Dr. Rajiv Ranjan Singh, Mr. Tulsi Ram Sharma, for their excellent personal guidance, help and teachings throughout the project, and further. Last, but not the least, we would like to thank our Lab Instruction Mr. V. Balaji and his team of assistants for all the help and knowledge imparted to us related to the assembly language programming in the...

Words: 2608 - Pages: 11

Free Essay

S.Comp

...8.0 PROGRAMMING 8.1.1 Definition Program : Programming Language: 8.1 Introduction to Programming Prepared by : Pn. Marzita Ismail (SC Unit) a series of instructions that directs a computer to perform tasks. A set of words, abbreviations, and symbol that enables a programmer to communicate instructions to a computer Eg: Java, C++, Fortran, Cobol, C 8.1.2 Types of Programming Language: 1) Low Level Programming Language • • Why Low Level? : Because it is designed closer to the hardware Machine Language (1st Generation) Assembly Language (2nd Generation) Made up of instructions written in binary code (0 and 1). • Written in mnemonics, more English-like code; codes shorter than The only language that is directly understood by the machine languages computer. Does not need any translator program. • Need to be translated by assembler into machine language before it can be executed by the computer. Machine dependent (written for particular • Machine dependent (written for particular computer and has computer and has to be changed for using on a Describe/what is/ explain/characteristic • different computer). Example of coding to be changed for using on a different computer). Advantages • • Execution speed is very fast. (It does not require any translation because machine language is directly understood by CPU) Translation free (Computer understands only the machine language) Program written in machine language are very lengthy Machine dependent (program...

Words: 1038 - Pages: 5

Premium Essay

Asas

...Computer Organization and Architecture CHAPTER 01: Basic Concepts of Architecture and Assembly Language CONTENTS: CHAPTER 1.1: Basic Concepts of Computer Architecture Computer Organization and Architecture CHAPTER 1.2: Basic Hardware Components of a Computer System John Vee MI P. Martinez, CSIT Instructor College of Information and Computing Sciences KING’S COLLEGE OF THE PHILIPPINES CHAPTER 1.3: Assembly Language CHAPTER 1.4: Programmer's View of a Computer System Computer Organization and Architecture CHAPTER 1.1: Basic Concepts of Computer Architecture Instructor: John Vee MI P. Martinez CHAPTER 1.1: Basic Concepts of Computer Architecture ASSIGNMENT #01: LEARNING OUTCOME #01: Next Learning Outcome: After engaging in each topic, students should have: 1) Differentiate Computer Organization and Computer Architecture?  ¼ Yellow Paper, to be submitted next meeting. LO-01: Distinguished the difference between Computer Architecture and Computer Organization, and discussed the different types of architecture. 1) 2) Computer Organization and Architecture Instructor: John Vee MI P. Martinez Computer Architecture vs. Computer Organization Types of Architecture Computer Organization and Architecture Instructor: John Vee MI P. Martinez LO 1.1 – Computer Architecture vs. Computer Organization LO 1.1 – Computer Architecture vs. Computer Organization COMPUTER ARCHITECTURE: COMPUTER ARCHITECTURE: ...

Words: 4567 - Pages: 19

Premium Essay

Computer T

...Overview of Computer Organization Chapter 1 S. Dandamudi Outline • Introduction ∗ Basic Terminology and Notation • Processor ∗ Execution cycle ∗ Pipelining ∗ RSIC and CISC Views of computer systems • User’s view • Programmer’s view ∗ Advantages of high-level languages ∗ Why program in assembly language? • Memory ∗ Basic memory operations ∗ Design issues • Architect’s view • Implementer’s view 2003 • • • • Input/Output Interconnection: The glue Historical Perspective Technological Advances Chapter 1: Page 2 © S. Dandamudi To be used with S. Dandamudi, “Fundamentals of Computer Organization and Design,” Springer-Verlag, 2003. Introduction • Some basic terms ∗ ∗ ∗ ∗ ∗ ∗ ∗ ∗ 2003 Computer architecture Computer organization Computer design Computer programming User’s view Programmer’s view Architect’s view Implementer’s view © S. Dandamudi Chapter 1: Page 3 • Various views of computer systems To be used with S. Dandamudi, “Fundamentals of Computer Organization and Design,” Springer-Verlag, 2003. Introduction (cont’d) Term K (kilo) M (mega) G (giga) T (tera) P (peta) 2003 Decimal 103 106 109 1012 1015 © S. Dandamudi Binary 210 220 230 240 250 Chapter 1: Page 4 To be used with S. Dandamudi, “Fundamentals of Computer Organization and Design,” Springer-Verlag, 2003. A User’s View of Computer Systems 2003 © S. Dandamudi Chapter 1: Page 5 To be used with S. Dandamudi, “Fundamentals of Computer Organization...

Words: 2516 - Pages: 11

Free Essay

Mr. Cesar Garcia Gomez

...ISO 26000 visión general del proyecto ISO - Organización Internacional de Normalización ISO cuenta con una membresía de 163* organismos nacionales de normalización de países grandes y pequeños, industrializados, en desarrollo y en transición, en todas las regiones del mundo. ISO cuenta con un portafolio de más de 18.400 normas*, que proveen a las empresas, el gobierno y la sociedad de herramientas prácticas en las tres dimensiones del desarrollo sostenible: económica, ambiental y social. Las normas ISO hacen una contribución positiva al mundo en que vivimos. Ellas facilitan el comercio, la difusión del conocimiento, la difusión de los avances innovadores en tecnología y comparten prácticas de buena gestión y evaluación de conformidades. Las normas ISO aportan soluciones y logran beneficios para casi todos los sectores de actividad, incluyendo agricultura, construcción, ingeniería mecánica, manufactura, distribución, transporte, dispositivos médicos, tecnologías de información y comunicación, medio ambiente, energía, gestión de la calidad, evaluación de conformidades y servicios. ISO sólo desarrolla normas para las que exista un claro requerimiento de mercado. El trabajo se lleva a cabo por expertos en el tema, que vienen directamente de los sectores industrial, técnico y de negocios que han identificado la necesidad de la norma y que posteriormente la pondrán en uso. Estos expertos pueden trabajar conjuntamente con otros con conocimientos relevantes, como representantes...

Words: 2346 - Pages: 10

Free Essay

Reverse Engineering

...About the Tutorial Assembly language is a low-level programming language for a computer or other programmable device specific to a particular computer architecture in contrast to most high-level programming languages, which are generally portable across multiple systems. Assembly language is converted into executable machine code by a utility program referred to as an assembler like NASM, MASM, etc. Audience This tutorial has been designed for those who want to learn the basics of assembly programming from scratch. This tutorial will give you enough understanding on assembly programming from where you can take yourself to higher levels of expertise. Prerequisites Before proceeding with this tutorial, you should have a basic understanding of Computer Programming terminologies. A basic understanding of any of the programming languages will help you in understanding the Assembly programming concepts and move fast on the learning track. Copyright & Disclaimer  Copyright 2014 by Tutorials Point (I) Pvt. Ltd. All the content and graphics published in this e-book are the property of Tutorials Point (I) Pvt. Ltd. The user of this e-book is prohibited to reuse, retain, copy, distribute or republish any contents or a part of contents of this e-book in any manner without written consent of the publisher. We strive to update the contents of our website and tutorials as timely and as precisely as possible, however, the contents may contain inaccuracies or errors. Tutorials Point (I) Pvt...

Words: 16458 - Pages: 66

Free Essay

Ensamblador

...Las instrucciones del ensamblador Instrucciones de transferencia Son utilizadas para mover los contenidos de los operandos. Cada instrucción se puede usar con diferentes modos de direccionamiento. MOV MOVS (MOVSB) (MOVSW) Instrucciones de carga Son instrucciones específicas de los registros. Son usadas para cargar en algœn registro bytes o cadenas de bytes. LODS (LODSB) (LODSW) LAHF LDS LEA LES Instrucciones de la pila Estas instrucciones permiten el uso de la pila para almacenar y extraer datos. POP POPF PUSH PUSHF Instrucción MOV Propósito: Transferencia de datos entre celdas de memoria, registros y acumulador. Sintaxis: MOV Destino,Fuente Donde Destino es el lugar a donde se moverán los datos y fuente es el lugar donde se encuentran dichos datos. Los diferentes movimientos de datos permitidos para esta instrucción son: Destino: memoria. Fuente: acumulador Destino: acumulador. Fuente: memoria Destino: registro de segmento. Fuente: memoria/registro Destino: memoria/registro. Fuente: registro de segmento Destino: registro. Fuente: registro Destino: registro. Fuente: memoria Destino: memoria. Fuente: registro Destino: registro. Fuente: dato inmediato Destino: memoria. Fuente: dato inmediato Ejemplo: MOV AX,0006h MOV BX,AX MOV AX,4C00h INT 21H Este pequeño programa mueve el valor 0006H al registro AX, luego mueve el contenido de AX (0006h) al registro BX, por último mueve...

Words: 7389 - Pages: 30

Premium Essay

Hai, How Are U

...UNIVERSITY OF KERALA B. TECH. DEGREE COURSE 2008 ADMISSION REGULATIONS and I  VIII SEMESTERS SCHEME AND SYLLABUS of COMPUTER SCIENCE AND ENGINEERING B.Tech Comp. Sc. & Engg., University of Kerala 2 UNIVERSITY OF KERALA B.Tech Degree Course – 2008 Scheme REGULATIONS 1. Conditions for Admission Candidates for admission to the B.Tech degree course shall be required to have passed the Higher Secondary Examination, Kerala or 12th Standard V.H.S.E., C.B.S.E., I.S.C. or any examination accepted by the university as equivalent thereto obtaining not less than 50% in Mathematics and 50% in Mathematics, Physics and Chemistry/ Bio- technology/ Computer Science/ Biology put together, or a diploma in Engineering awarded by the Board of Technical Education, Kerala or an examination recognized as equivalent thereto after undergoing an institutional course of at least three years securing a minimum of 50 % marks in the final diploma examination subject to the usual concessions allowed for backward classes and other communities as specified from time to time. 2. Duration of the course i) The course for the B.Tech Degree shall extend over a period of four academic years comprising of eight semesters. The first and second semester shall be combined and each semester from third semester onwards shall cover the groups of subjects as given in the curriculum and scheme of examination ii) Each semester shall ordinarily comprise of not less than 400 working periods each of 60 minutes duration...

Words: 34195 - Pages: 137

Free Essay

Idrivesa

...2007-2008 JAWAHARLAL NEHRU TECHNOLOGICAL UNIVERSITY, HYDERABAD B.TECH. ELECTRONICS AND COMMUNICATION ENGINEERING I YEAR COURSE STRUCTURE |Code |Subject |T |P/D |C | | |English |2+1 |- |4 | | |Mathematics - I |3+1 |- |6 | | |Mathematical Methods |3+1 |- |6 | | |Applied Physics |2+1 |- |4 | | |C Programming and Data Structures |3+1 |- |6 | | |Network Analysis |2+1 |- |4 | | |Electronic Devices and Circuits |3+1 |- |6 | | |Engineering Drawing |- |3 |4 | | |Computer Programming Lab. |- |3 |4 | | |IT Workshop |- |3 |4 | | |Electronic Devices and Circuits Lab |- |3...

Words: 26947 - Pages: 108

Free Essay

Bored

...a&TOa'gif; pHkaxmuf armifpH&Sm; a&TOa'gif; rmwdum 1/ wpfuRef;jyefwpfa,muftrIü armifpH&Sm; pHkaxmufyHk 2/ armifpH&Sm;onf tb,faMumifh vlysdKMuD;vkyfí aeygoenf; 3/ ESpfxyfausmh 4/ tqdyfaomufaoonfqdkaom trI 5/ xl;qef;aom vlowfrIMuD; 6/ ola|;uawmfwpfOD;trI 7/ udk,fhudk,fudkowfjcif;avm olwpfyg;owfjcif;avm 8/ ajrydkif&Sif vifr,m;trI 9/ xl;qef;aom ajrbkwfbDvl;trIIü armifpH&Sm; pHkaxmufyHk 10/ OD;atmif'Gef;udk b,folowfovJ 11/ w&kwfujym;rav; rusifjrdKiftrI 12/ rif;wdkifyiftrwfwpfOD;\trIIü armifpH&Sm;pHkaxmufyHk 13/ ,pfrsdK;pHkaxmufwpfa,muf aoqHk;rI 14/ pdefvk,ufrIü pHkaxmufyHk 15/ xl;qef;aomtarGrIMuD;ü armifpH&Sm;pHkaxmufyHk 16/ touftmrcH ukrÜPDtrI 17/ eef;pOfywÅjrm;trIIü armifpH&Sm;pHkaxmufyHk 18/ rdk;ukwftarGtrIü armifpH&Sm; pHkaxmufyHk 19/ tdEd´,jynf? rdkufpdk;e,f r[m&mZmapmfbGm;\ eef;wGif;ywÅjrm; aysmufqHk;rIü armifpH&Sm;pHkaxmufyHk 20/ udk,fhudk,fudk owfaoonfqdkonfhtrIü pHkaxmufjcif; 21/ aumfydka&;&Sif;Ouú| aysmufrIpHkaxmufyHk 22/ xl;qef;aom tdk;jcrf;yJh txdrf;trSwfrIü pHkaxmufyHk 1 ...4 . . .50 . . .94 . . .108 . . .121 . . .132 . . .147 . . .162 . . .175 . . .189 . . .204 . . .221 . . .236 pHkaxmuf armifpH&Sm; 23/ wl0&D;ESpfa,muf\ xl;qef;aom trIü pHkaxmufjcif; 24/ bk&ifcHuawmfykvJykwD;aysmufrIü pHkaxmufyHk 25/ £w¦d, odkuform;wa,muftrI 26/ ya&mfzufqm q&mMuD;OD;xGef;azESifh &ifqdkif&jcif; 27/ ya&mfzufqm q&mMuD; OD;xGef;azESifh armifpH&Sm; 28/ ukvm;"m;jytoif;MuD;ESifh pHkaxmufarmifpH&Sm; 29/ pHkaxmufarmifpH&Sm;onf vlqdk;wdkU pufuGif;odkU oufqif;&yHk 30/ pHkaxmufarmifpH&Sm;tm;...

Words: 44281 - Pages: 178