1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
My name is Ann [436]
3 years ago
12

LC3 Programming ProblemUse .BLKW to set up an array of 10 values, starting at memory location x4000, as in lab 4.Now programmati

cally populate the array with the numbers 0 through 9 – i.e. hard-code just the firstvalue (0), then calculate the rest one at a time, storing them in the array as you go.After you've stored them all, grab the seventh value (which would be 6) and store it in R2.As always, step through your program and examine the values as they are stored in the array, andexamine the final value stored in R2, to make sure your program works as expected.
Engineering
1 answer:
irga5000 [103]3 years ago
7 0

Answer:

Check the explanation

Explanation:

Code

.ORIG x4000

;load index

LD R1, IND

;increment R1

ADD R1, R1, #1

;store it in ind

ST R1, IND

;Loop to fill the remaining array

TEST LD R1, IND

;load 10

LD R2, NUM

;find tw0\'s complement

NOT R2, R2

ADD R2, R2, #1

;(IND-NUM)

ADD R1, R1, R2

;check (IND-NUM)>=0

BRzp GETELEM

;Get array base

LEA R0, ARRAY

;load index

LD R1, IND

;increment index

ADD R0, R0, R1

;store value in array

STR R1, R0,#0

;increment part

INCR

;Increment index

ADD R1, R1, #1

;store it in index

ST R1, IND

;go to test

BR TEST

;get the 6 in R2

;load base address

GETELEM LEA R0, ARRAY

;Set R1=0

AND R1, R1,#0

;Add R1 with 6

ADD R1, R1, #6

;Get the address

ADD R0, R0, R1

;Load the 6th element into R2

LDR R2, R0,#0

;Display array contents

PRINT

;set R1 = 0

AND R1, R1, #0

;Loop

;Get index

TOP ST R1, IND

;Load num

LD R3,NUM

;Find 2\'s complement

NOT R3, R3

ADD R3, R3,#1

;Find (IND-NUM)

ADD R1, R1,R3

;repeat until (IND-NUM)>=0

BRzp DONE

;load array address

LEA R0, ARRAY

;load index

LD R1, IND

;find address

ADD R3, R0, R1

;load value

LDR R1, R3,#0

;load 0x0030

LD R3, HEX

;convert value to hexadecimal

ADD R0, R1, R3

;display number

OUT

;GEt index

LD R1, IND

;increment index

ADD R1, R1, #1

;go to top

BR TOP

;stop

DONE HALT

;declaring variables

;set limit

NUM .FILL 10

;create array

ARRAY .BLKW 10 #0

;variable for index

IND .FILL 0

;hexadecimal value

HEX .FILL x0030

;stop

.END

You might be interested in
Two technicians are discussing a vehicle that cranks slowly when the key is turned to the crank position. The positive battery t
Norma-Jean [14]

Answer:

Both are right

Explanation:

3 0
1 year ago
Identify the right components for gsm architecture that consists of the hardware or physical equipment such as digital signal pr
sergiy2304 [10]

The right components for gsm architecture that consists of the hardware or physical equipment such as digital signal processors, radio transceiver, display, battery, case and sim card is the Mobile station.

<h3>What are the 4 main components?</h3>

In GSM, a cell station includes 4 fundamental additives: Mobile termination (MT) - gives not unusualplace features consisting of: radio transmission and handover, speech encoding and decoding, blunders detection and correction, signaling and get right of entry to to the SIM. The IMEI code is connected to the MT.

Under the GSM framework, a cell tele cell smartphone is called a Mobile Station and is partitioned into  wonderful additives: the Subscriber Identity Module (SIM) and the Mobile Equipment (ME).

Read more about the mobile station:

brainly.com/question/917245

#SPJ4

6 0
2 years ago
The domain of discourse is the members of a chess club. The predicate B(x, y) means that person x has beaten person y at some po
satela [25.4K]

Answer:A. No one has ever beat Nancy.

Explanation:

The dormain of discourse in a simple language is the set of entities upon which our discussions are based when discussing about something.

The dormain of discourse is also known simply as universe, can also be said to be a set of entities o

upon which certain variables of interest in some formal treatment may range.

The dormain of discourse is generally attributed to Augustus De Morgan, it was also extensively used by George Boole in his Laws of Thought.

THE LOGICAL UNDERSTANDING OF THE THE QUESTION IS THAT NO ONE HAS EVER BEAT NANCY.

8 0
3 years ago
Consider this example of a recurrence relation. A police officer needs to patrol a gated community. He would like to enter the g
SashulF [63]

Answer:

the police officer cruise each streets precisely once and he enters and exit with the same gate.

Explanation:

NB: kindly check below for the attached picture.

The term ''Euler circuit'' can simply be defined as the graph that shows the edge of K once in a finite way by starting and putting a stop to it at the same vertex.

The term "Hamiltonian Circuit" is also known as the Hamiltonian cycle which is all about a one time visit to the vertex.

Here in this question, the door is the vertex and the road is the edge.

The information needed to detemine a Euler circuit and a Hamilton circuit is;

"the police officer cruise each streets precisely once and he enters and exit with the same gate."

Check attachment for each type of circuit and the differences.

7 0
3 years ago
Which of the following are true about the American Wire Gauge?
harina [27]

Answer:

A. smallest wire is No. 12

7 0
2 years ago
Other questions:
  • After a capacitor is fully chargerd, a small amount of current will flow though it. what is this current called?
    14·1 answer
  • What is the advantage of Sensabot over human inspectors?
    12·1 answer
  • You are considering purchasing a compact washing machine, and you have the following information: The Energy Guide claims an est
    8·1 answer
  • A process consists of two steps: (1) One mole of air at T = 800 K and P = 4 bar is cooled at constant volume to T = 350 K. (2) T
    7·1 answer
  • Q1. Basic calculation of the First law (2’) (a) Suppose that 150 kJ of work are used to compress a spring, and that 25 kJ of hea
    6·1 answer
  • The cylinder C is being lifted using the cable and pulley system shown.
    8·1 answer
  • Some_____
    10·1 answer
  • 12. Never spray brakes with a high-pressure stream of water or air because it could blow asbestos fibers into the air.
    8·1 answer
  • The ruler game, HELPPPP PLS
    11·2 answers
  • Which of the following might a cement mason or concrete finisher be responsible for? (Select all that apply).
    5·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!