Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Write the following program using HC11 assembly language: 1) Allocate memory (3 bytes) for multiplicand M 2) Allocate memory (1 byte) for multiplier N 3)

Write the following program using HC11 assembly language:

1) Allocate memory (3 bytes) for multiplicand M

2) Allocate memory (1 byte) for multiplier N

3) Allocate memory (4 bytes) for product P

4) Allocate memory (2 bytes) for P1

5) Allocate memory (2 bytes) for P2

6) Allocate memory (2 bytes) for P3

7) Read Multiplicand LSB to accumulator A (ACCA)

8) Read Multiplier to accumulator B (ACCB)

9) Multiply ACCA and ACCB (the result is saved in register D)

10) Store ACCB to Product LSB

11) Store ACCA to P1 MSB

12) Read Multiplicand MID to ACCA

13) Read Multiplier to ACCB

14) Multiply ACCA and ACCB

15) Store D register to P2

16) Read Multiplicand MSB to ACCA

17) Read Multiplier to ACCB

18) Multiply ACCA and ACCB

19) Store D register to P3

20) Read P1 MSB to ACCA

21) Add P2 LSB

22) Store sum to Product MID-L

23) Read P2 MSB to ACCA

24) Add with carry P3 LSB

25) Store sum to Product MID-H

26) Read P3 MSB to ACCA

27) Add with carry, zero

28) Store sum to Product MSB

Variable memory allocation should start at memory location $00 and the code should be stored starting at memory location $0100.

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

The Manga Guide To Databases

Authors: Mana Takahashi, Shoko Azuma, Co Ltd Trend

1st Edition

1593271905, 978-1593271909

More Books

Students also viewed these Databases questions

Question

Explain the steps involved in training programmes.

Answered: 1 week ago

Question

What are the need and importance of training ?

Answered: 1 week ago

Question

What is job rotation ?

Answered: 1 week ago