Explain about cseg segment, Computer Engineering

Assignment Help:

CSEG SEGMENT

 ASSUME CS:CSEG, DS:CSEG, SS:CSEG

 ORG 100h

START:MOV AX, CSEG; Initialise data segment

 MOV DS, AX; register using AX

 MOV AL, NUM1; Take the first number in AL

ADD AL, NUM2;                                          Add the 2nd number to it

 MOV RESULT, AL;                                                 Store the result in location RESULT 

 RCL AL, 01;                                                  rotate carry into LSB

 AND AL, 00000001B;                                  Mask out all but LSB

MOV CARRY, AL;                                       Store the carry result

MOV AX,4C00h 

INT 21h

NUM1 DB                  15h;                             First number stored here

NUM2 DB                  20h;                             Second number stored here

RESULT DB              ? ;                                Put sum here

CARRY DB               ? ;                                Put any carry here

CSEG ENDS

END START

These programs are stored on a disk with an extension .com. A COM program needs less space on disk instead of equivalent EXE program. At run-time COM program places stack automatically at the end of segment so they use at least one complete segment.


Related Discussions:- Explain about cseg segment

Device controllers, All components of computer communicate with processor b...

All components of computer communicate with processor by the system bus. Which means I/O devices required to be attached to system bus. But I/O devices aren't connected directly to

Split bus operation - universal serial bus , Split Bus Operation - universa...

Split Bus Operation - universal serial bus :   USB 2.0 devices utilize a special protocol in the reset time that is called "chirping", to negotiate the high speed mode

What is overflow and underflow case in single precision, What is overflow, ...

What is overflow, underflow case in single precision(sp)? Underflow-In SP it means that the normalized representation needs an exponent less than -126. Overflow-In SP it mea

What is a client in sap terminology, What is a client in SAP terminology? ...

What is a client in SAP terminology? A S/W component that uses the service (offered by a s/w component) is known as a Client.  At the similar time these clients may also be ser

What is meaning of term byte stuffing, The term byte stuffing refers to: ...

The term byte stuffing refers to: The term byte stuffing consider as to data stuffing used along with character -oriented hardware.

Character and string processing instructions, Character and String Processi...

Character and String Processing Instructions: String manipulation usually is done in memory. Possible instructions comprise COMPARE STRING, COMPARE CHARACTER, MOVE STRING and MOVE

Explain what is a macro and why is it important, Question 1: Spreadshee...

Question 1: Spreadsheet packages are widely used in Business. a) Explain why spreadsheets are so useful. b) Spreadsheet files are sometimes saved for use by other software p

How can we set the table spaces and extent sizes, How can we set the table ...

How can we set the table spaces and extent sizes? You can state the extent sizes and the table space (physical storage area in the database) in which a transparent table is to

Explain traffic handling capacity, Traffic Handling Capacity is given by ...

Traffic Handling Capacity is given by (A)  Switching capacity × Theoretical maximum load (B)  Switching capacity / Theoretical maximum load (C)  Theoretical maximu

What is redefines clause, Redefines clause is used to permit the similar st...

Redefines clause is used to permit the similar storage allocation to be referenced by dissimilar data names.

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