For this you will need to add code where it says write your code here. None of the other files need to be changed just the one that needs you to write the code in it. In the image below will be instructions of what your code needs. You do not need to d all of the bulletin do what you can maybe the first 2 or 3 bulletins will be okay. Pls help me out with this and write your code in assembly language, you can use lc3 simulator to write your code and test it! Thank you! main file: .ORIG x3000 TRAP x40 ST R0, FIRST_ADDRESS TRAP x40 ST R0, LAST_ADDRESS LD R0, FIRST_ADDRESS LD R1, LAST_ADDRESS TRAP x41 HALT FIRST_ADDRESS .BLKW #1 LAST_ADDRESS .BLKW #1 .END trap_vector_output file: .ORIG x0041 .FILL x5000 .END trap_vector_input file: .ORIG x0040 .FILL x4000 .END trap_input file: .ORIG x4000 ;WRITE YOUR CODE HERE RET .END
For this you will need to add code where it says write your code here. None of the other files need to be changed just the one that needs you to write the code in it. In the image below will be instructions of what your code needs. You do not need to d all of the bulletin do what you can maybe the first 2 or 3 bulletins will be okay. Pls help me out with this and write your code in assembly language, you can use lc3 simulator to write your code and test it! Thank you!
main file:
.ORIG x3000
TRAP x40
ST R0, FIRST_ADDRESS
TRAP x40
ST R0, LAST_ADDRESS
LD R0, FIRST_ADDRESS
LD R1, LAST_ADDRESS
TRAP x41
HALT
FIRST_ADDRESS .BLKW #1
LAST_ADDRESS .BLKW #1
.END
trap_vector_output file:
.ORIG x0041
.FILL x5000
.END
trap_vector_input file:
.ORIG x0040
.FILL x4000
.END
trap_input file:
.ORIG x4000
;WRITE YOUR CODE HERE
RET
.END



Step by step
Solved in 4 steps with 1 images









