Declare a constant in assembly language, Assembly Language

Assignment Help:

Declare 1 constant. This can be done just below the prototype section. Put the following divider above the constant section.

;************************ Constants ***************************

Declare a constant LF to hold the ASCII value for a linefeed: 0Ah

A linefeed moves the cursor to the next line.

You can embed a LF in your declaration of the string variables below.

Example: name byte "Fred Kennedy",LF,0

If the above string were printed with WriteString as follows, Fred Kennedy would print then the cursor would move to the beginning of the next line.

movedx, offset name

callWriteString

You could also embed a LF at the beginning of a string which would move the cursor to the next line then the string would print:

name byte LF,"Fred Kennedy",0

See WriteStringLFconstants.asm on the class web site for examples of declaring strings with embedded LF and how to declare constants.

 


Related Discussions:- Declare a constant in assembly language

.., Sum of series of 10 numbers and store result in memory location total

Sum of series of 10 numbers and store result in memory location total

Architecture of file transfer, Explain the architecture of the file transfe...

Explain the architecture of the file transfer protocol ftp in terms of clients, servers, sockets

8086 alp, to find the matrix addition

to find the matrix addition

Program, Write a program to separate out positive and negative numbers from...

Write a program to separate out positive and negative numbers from a given series of 16-bit hexadecimal numbers.

Relocate program and data, ) What is the difference between re-locatable pr...

) What is the difference between re-locatable program and re-locatable data?

Arithmrtic operation exercise assempley HELP!, Open notepad and enter the c...

Open notepad and enter the code for a program that calculates the following arithmetic expression: x = a + b + c - d - e + f The operands a, b, c, d, e, f, and x should be declared

Flowchart, ALP to preform of two 16-bit numbers in register addressing mode...

ALP to preform of two 16-bit numbers in register addressing mode

Assignment, Write an assembly program that adds the elements in the odd ind...

Write an assembly program that adds the elements in the odd indices of the following array. Use LOOP. What is the final value in the register?

Addsub, Using the AddSub program from Ch3 under c:\Masm615\examples as a re...

Using the AddSub program from Ch3 under c:\Masm615\examples as a reference, write a program that subtracts three 16-bit integers using only registers. Insert a call DumpRegs statem

Login system, a pseudo-code to add username and password combination up to ...

a pseudo-code to add username and password combination up to a limit of 10

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd