Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

assembly language programming

Status
Not open for further replies.

lamiajoyee

Newbie level 4
Joined
Jul 4, 2010
Messages
7
Helped
1
Reputation
2
Reaction score
1
Trophy points
1,283
Activity points
1,327
what is the difference between the following two codes? can anyone tell me?
Code:
ORIGIN 1000
DATAWORD 300
and
Code:
MOVE #300,1000
 

no difference.
1st one initialise 300 at address 1000 by assembler.

2nd one same initialisation by processor.
 

    lamiajoyee

    Points: 2
    Helpful Answer Positive Rating
i know there is no difference but the timing is what matters.could you please tell me when 300 is stored in location 1000 for the two separate occassions?
 

after assembling the codes shown ,

1st method starts the program with 300 at loc 1000.

whereas in second method , it is at that time when move is executed.
until then loc 1000 content is not known
 

    lamiajoyee

    Points: 2
    Helpful Answer Positive Rating
here is my problem:
register R5 is used to point the top of the stack.write sequence instruction to pop the top two items off the stack, add them and push the result onto the stack. also copy the fifth item from the top into register R3 and remove the top ten items from the stack.
here i only know two instrctions.how can i implement the above problem using these and more instructions?please help me.
Code:
 MOVE item,-(SP)
MOVE (SP)+,item
 

an incrementing or decrementing stack type ?

any pop /push instrctions available?
 

they have asked me to use index,auto increment and auto decrement mode
 

for increment type:

MOVE num1,-(SP)
MOVE num2 , -(SP)
add num1,num2
MOVE (SP)+ , num1

other parts . whether to get fifth item after adding and pushing to stack or get before .
not clear

Added after 2 minutes:

a 68000 book will give you the idea.
 

    lamiajoyee

    Points: 2
    Helpful Answer Positive Rating
The first is compile time (assemble time) initialization while the second is run time initialization.
--
Amr
 

    lamiajoyee

    Points: 2
    Helpful Answer Positive Rating
Which processor and assembler are you targeting?
--
Amr
 

im a total newbie.im studying 8085 computer architecture.so i actually dont the processor or assembler
 

you can see the following for beginning with 8085 assmbler.
http://gnusim8085.sourceforge.net/doc/asm-guide.html


if you visit:
**broken link removed**
there are 8085 related materials on this page.
download the pdfs and read.
you will get the grip of 8085.

hope it helps you
 
Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top