Question: Lab 1 . O DESCRIPTION Rewrite the copy program ( Lab 1 . C ) so that it will create name: Kiran Kadariya beginning at

Lab 1.O
DESCRIPTION
Rewrite the copy program (Lab 1.C) so that it will create name: Kiran Kadariya beginning at memory location $02100 and social security number: 483937216 beginning at location $02160. You are to do this using the following addressing modes in your program:
Address register direct An
Address register indirect (An)
postincrement (An)+
predecrement -(An)
displacement d(An)
You can use these anywhere in your program. You need to submit the following for your grade:
1. a copy of your code; *-----------------------------------------------------------
* Title : Lab 1.c
* Written by : Kiran Kadariya
* Date : 01/15/2024
* Description: Welcome to CSCI 320-54
*-----------------------------------------------------------
ORG $2000 ; Assign the string 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' to memory location 2000
DC.L 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'
ORG $2020 ; Move to memory location 2020
DC.L 'abcdefghijklmnopwrstuvwxyz' ; Assign the string 'abcdefghijklmnopwrstuvwxyz' to memory location 2020
ORG $2040 ; Move to memory location 2040
DC.W '0123456789' ; Assign the string '0123456789' to memory location 2040
START: ; first instruction of program
LEA.L $002000,A2
LEA.L $002020,A3
LEA.L $002040,A4
LEA.L $002200,A1
MOVE.B $002016,(A1)+
MOVE.B $002024,(A1)+
MOVE.B $00202B,(A1)+
MOVE.B $002022,(A1)+
MOVE.B $00202E,(A1)+
MOVE.B $00202C,(A1)+
MOVE.B $002024,(A1)+
MOVE.B #32,(A1)+
MOVE.B 19(A3),(A1)+
MOVE.B 14(A3),(A1)+
MOVE.B #32,(A1)+
MOVE.B 2(A2),(A1)+
MOVE.B 18(A2),(A1)+
MOVE.B 2(A2),(A1)+
MOVE.B 8(A2),(A1)+
MOVE.B #32,(A1)+
MOVE.B 3(A4),(A1)+
MOVE.B 2(A4),(A1)+
MOVE.B (A4),(A1)+
MOVE.B #33,(A1)+
MOVE.B #33,(A1)+
MOVE.B #33,(A1)+
MOVE.B #32,(A1)+
SIMHALT ; halt simulator
END START ; last line of source
2. a copy of memory locations $2100 through $2180 after execution;

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!